Inheritance: Caliburn.Micro.Screen
示例#1
0
        /// <summary>
        ///     Open the key calculation dialog.
        /// </summary>
        public void CalculateKey()
        {
            var win = new KeyCalculationViewModel {
                DisplayName = "Calculate a new key"
            };
            dynamic settings = new ExpandoObject();

            settings.WindowStartupLocation = WindowStartupLocation.CenterOwner;
            settings.Owner = GetView();
            var inputOk = _windowManager.ShowDialog(win, null, settings);

            if (inputOk == true)
            {
                if (win.CalculatedKey != null)
                {
                    AddKey(win.CalculatedKey);
                }
            }
        }
示例#2
0
 /// <summary>
 ///     Open the key calculation dialog.
 /// </summary>
 public void CalculateKey()
 {
     var win = new KeyCalculationViewModel {DisplayName = "Calculate a new key"};
     dynamic settings = new ExpandoObject();
     settings.WindowStartupLocation = WindowStartupLocation.CenterOwner;
     settings.Owner = GetView();
     var inputOk = _windowManager.ShowDialog(win, null, settings);
     if (inputOk == true)
     {
         if (win.CalculatedKey != null)
         {
             AddKey(win.CalculatedKey);
         }
     }
 }