Exemple #1
0
 private void LoadShortcuts()
 {
     Shortcuts.Clear();
     foreach (var item in ShortcutServices.LoadExistingShortcuts())
     {
         Shortcuts.Add(new ShortcutViewModel(item));
     }
 }
Exemple #2
0
 protected override void OnStartup(StartupEventArgs e)
 {
     base.OnStartup(e);
     ShortcutServices.InitializeEnvironmentVariable();
     DispatcherUnhandledException += (o, ev) => MessageBox.Show(ev.Exception.ToString(), "Unhandled exception", MessageBoxButton.OK, MessageBoxImage.Error);
 }