Esempio n. 1
0
        private void Window_Loaded(object sender, RoutedEventArgs e)
        {
            MainDataGrid.Focus();

            if (!string.IsNullOrEmpty(kPw.Settings.PreviouslyLoadedFile) && File.Exists(kPw.Settings.PreviouslyLoadedFile))
            {
                ShowPasswordPanel(kPw.CurrentOperation = EncryptDecryptOperation.Decrypt, kPwFile.TmpPath = kPw.Settings.PreviouslyLoadedFile);
            }
        }
Esempio n. 2
0
        private void Dialog_Loaded(object sender, RoutedEventArgs e)
        {
            var remove = AlbumList?.FirstOrDefault(f => string.IsNullOrWhiteSpace(f.Id) || f.Id == "♥♦♣♠");

            if (remove != null)
            {
                AlbumList.Remove(remove);
            }

            MainDataGrid.ItemsSource = AlbumList;

            MainDataGrid.Focus();

            if (MainDataGrid.Items.Count > 0)
            {
                MainDataGrid.SelectedIndex = 0;
                MainDataGrid.FocusOnFirstCell();
            }
        }