// 这个方法没有放在InputWindow类型中是为了去除编译时对MahaApps.Metro的依赖供AppModels使用 public static void ShowInputDialog( string title, string text, Func <string, string> check, Action <string> onOk) { Window window = new InputWindow(title, text, check, onOk); window.MousePosition(); window.ShowSoftDialog(); }
// 这个方法没有放在InputWindow类型中是为了去除编译时对MahaApps.Metro的依赖供AppModels使用 public static void ShowInputDialog( string title, string text, string tail, Func <string, string> check, Action <string> onOk, bool isPassword = false) { Window window = new InputWindow(title, text, tail, check, onOk, isPassword); window.MousePosition(); window.ShowSoftDialog(); }
// 这个方法没有放在InputWindow类型中是为了去除编译时对MahaApps.Metro的依赖供AppModels使用 public static void ShowInputDialog( string title, string text, Func <string, string> check, Action <string> onOk) { Window window = new InputWindow(title, text, check, onOk); if (window.Owner != null) { window.MousePosition(); double ownerOpacity = window.Owner.Opacity; window.Owner.Opacity = 0.6; window.ShowDialog(); window.Owner.Opacity = ownerOpacity; } else { window.ShowDialog(); } }