Exemplo n.º 1
0
 private void autoDelete_Toggled(object sender, RoutedEventArgs e)
 {
     if (checkInit)
     {
         ToggleSwitch toggleSwitch = sender as ToggleSwitch;
         if (toggleSwitch != null)
         {
             if (toggleSwitch.IsOn == true)
             {
                 AutoDelete.AutoDeleteStatus = true;
                 AutoDelete.DeleteOutDatedAllEvents();
                 AutoDelete.WriteAutoDeleteData();
                 if (Tile.tileStatus)
                 {
                     Tile.UpdateTile();
                 }
             }
             else
             {
                 AutoDelete.AutoDeleteStatus = false;
                 AutoDelete.WriteAutoDeleteData();
             }
         }
     }
 }
Exemplo n.º 2
0
        private void ReadAllEventsInfo()
        {
            ReadBasicEventsData();
            ReadLifeEventsData();
            ReadBirthdayEventsData();
            ReadLoveEventsData();
            ReadFestivalEventsData();
            ReadEntertainmentEventsData();
            ReadStudyEventsData();
            ReadWorkEventsData();
            ReadOtherEventsData();

            if (AutoDelete.AutoDeleteStatus)
            {
                AutoDelete.DeleteOutDatedAllEvents();
                AutoDelete.DeleteOutDatedCoverEvents();
            }
        }