/// <summary> /// 显示确定取消菜单 /// </summary> /// <param name="str">提示字段</param> private void ShowMessagePopupWindow(string str) { var msgPopup = new Resources.MessagePopupWindow(str); msgPopup.LeftClick += (s, e) => { StrongTypeViewModel.CommandDeleteFriend.Execute(null); }; msgPopup.RightClick += (s, e) => { }; msgPopup.ShowWIndow(); }
/// <summary> /// 显示确定取消菜单 /// </summary> /// <param name="str">提示字段</param> /// <param name="mode">确定后运行的模式</param> private void ShowMessagePopupWindow(string str, CommandKind mode) { var msgPopup = new Resources.MessagePopupWindow(str); switch (mode) { case CommandKind.Insert: msgPopup.LeftClick += (s, e) => { StrongTypeViewModel.CommandInsertDialog.Execute(null); }; break; } msgPopup.RightClick += (s, e) => { }; msgPopup.ShowWIndow(); }