Exemple #1
0
 void menuIntense_Click(object sender, EventArgs e)
 {
     if (staticObjects.Address != null)
     {
         BackAgent.StartIntenseMode();
         MessageBox.Show(AppResources.IntenseModeON, AppResources.ApplicationTitle, MessageBoxButton.OK);
     }
     else
     {
         MessageBox.Show(AppResources.LocationService_NoService, AppResources.LocationService_Title, MessageBoxButton.OK);
     }
 }
 void tglIntenseMode_Checked(object sender, RoutedEventArgs e)
 {
     App.IntenseModeEnabled = true;
     tglIntenseMode.Content = AppResources.General_Started;
     if (staticObjects.Address != null)
     {
         BackAgent.StartIntenseMode();
     }
     else
     {
         MessageBox.Show(AppResources.IntenseModeCantStart, AppResources.SettingsView_IntenseMode, MessageBoxButton.OK);
         tglIntenseMode.IsChecked = false;
     }
 }
Exemple #3
0
 private void StartIntenseMode()
 {
     if (App.IntenseModeEnabled)
     {
         App.IntenseModeEnabled = false;
         BackAgent.RemoveAgent("SmartGuardPeriodicAgent");
         MessageBox.Show(AppResources.IntenseModeOFF, AppResources.ApplicationTitle, MessageBoxButton.OK);
     }
     else
     {
         if (staticObjects.Address != null)
         {
             BackAgent.StartIntenseMode();
         }
         else
         {
             MessageBox.Show(AppResources.IntenseModeCantStart, AppResources.SettingsView_IntenseMode, MessageBoxButton.OK);
         }
     }
 }
 void tglIntenseMode_Unchecked(object sender, RoutedEventArgs e)
 {
     App.IntenseModeEnabled = false;
     tglIntenseMode.Content = AppResources.General_Stopped;
     BackAgent.RemoveAgent("SmartGuardPeriodicAgent");
 }