예제 #1
0
 public void ToolsOptions()
 {
     using (var dlg = dlgFactory.CreateUserPreferencesDialog())
     {
         uiSvc.ShowModalDialog(dlg);
     }
 }
예제 #2
0
 public void ToolsOptions()
 {
     using (var dlg = dlgFactory.CreateUserPreferencesDialog())
     {
         if (uiSvc.ShowModalDialog(dlg) == DialogResult.OK)
         {
             var uiPrefsSvc = Services.RequireService <IUiPreferencesService>();
             uiPrefsSvc.WindowSize  = form.Size;
             uiPrefsSvc.WindowState = form.WindowState;
             uiPrefsSvc.Save();
         }
     }
 }