async void Init() { Data.But_Enable = await DataLight.Init(); if (DataLight.isExist) { if (Settings.EnableOnStart) { DataLight.Enable(); } Data.Enable = DataLight.isEnable; } }
private void Application_Deactivated(object sender, DeactivatedEventArgs e) { DataLight.Sleep(); }
private void Application_Activated(object sender, ActivatedEventArgs e) { DataLight.Wakeup(); }
private void but_flash_Click(object sender, RoutedEventArgs e) { Data.Enable = DataLight.Change(); }