public static DialogResult MessageBox(string title, string mainInstruction, string content, ETaskDialogButtons buttons, ESysIcons mainIcon) { return(MessageBox(null, title, mainInstruction, content, "", "", "", buttons, mainIcon, ESysIcons.Information)); }
//-------------------------------------------------------------------------------- // Overloaded versions... //-------------------------------------------------------------------------------- public static DialogResult MessageBox(string title, string mainInstruction, string content, string expandedInfo, string footer, string verificationText, ETaskDialogButtons buttons, ESysIcons mainIcon, ESysIcons footerIcon) { return ShowTaskDialogBox(null, title, mainInstruction, content, expandedInfo, footer, verificationText, "", "", buttons, mainIcon, footerIcon); }
//-------------------------------------------------------------------------------- // Overloaded versions... //-------------------------------------------------------------------------------- public static DialogResult MessageBox(string title, string mainInstruction, string content, string expandedInfo, string footer, string verificationText, ETaskDialogButtons buttons, ESysIcons mainIcon, ESysIcons footerIcon) { return(ShowTaskDialogBox(null, title, mainInstruction, content, expandedInfo, footer, verificationText, "", "", buttons, mainIcon, footerIcon)); }
//-------------------------------------------------------------------------------- // Overloaded versions... //-------------------------------------------------------------------------------- public static DialogResult ShowTaskDialogBox(IWin32Window owner, string title, string mainInstruction, string content, string expandedInfo, string footer, string verificationText, string radioButtons, string commandButtons, ETaskDialogButtons buttons, ESysIcons mainIcon, ESysIcons footerIcon) { return(ShowTaskDialogBox(owner, title, mainInstruction, content, expandedInfo, footer, verificationText, radioButtons, commandButtons, buttons, mainIcon, footerIcon, 0)); }
//-------------------------------------------------------------------------------- //-------------------------------------------------------------------------------- #region ShowTaskDialogBox //-------------------------------------------------------------------------------- public static DialogResult ShowTaskDialogBox(IWin32Window owner, string title, string mainInstruction, string content, string expandedInfo, string footer, string verificationText, string radioButtons, string commandButtons, ETaskDialogButtons buttons, ESysIcons mainIcon, ESysIcons footerIcon, int defaultIndex) { DialogResult result; OnTaskDialogShown?.Invoke(null, EventArgs.Empty); using (var td = new frmTaskDialog()) { var display = new DisplayProperties(); td.Title = title; td.MainInstruction = mainInstruction; td.Content = content; td.ExpandedInfo = expandedInfo; td.Footer = footer; td.RadioButtons = radioButtons; td.CommandButtons = commandButtons; td.Buttons = buttons; td.MainIcon = mainIcon; td.FooterIcon = footerIcon; td.VerificationText = verificationText; td.Width = display.ScaleWidth(EmulatedFormWidth); td.DefaultButtonIndex = defaultIndex; td.BuildForm(); result = td.ShowDialog(owner); RadioButtonResult = td.RadioButtonIndex; CommandButtonResult = td.CommandButtonClickedIndex; VerificationChecked = td.VerificationCheckBoxChecked; } OnTaskDialogClosed?.Invoke(null, EventArgs.Empty); return(result); }
public static DialogResult MessageBox(string title, string mainInstruction, string content, ETaskDialogButtons buttons, ESysIcons mainIcon) { return MessageBox(null, title, mainInstruction, content, "", "", "", buttons, mainIcon, ESysIcons.Information); }
//-------------------------------------------------------------------------------- // Overloaded versions... //-------------------------------------------------------------------------------- public static DialogResult ShowTaskDialogBox(IWin32Window owner, string title, string mainInstruction, string content, string expandedInfo, string footer, string verificationText, string radioButtons, string commandButtons, ETaskDialogButtons buttons, ESysIcons mainIcon, ESysIcons footerIcon) { return ShowTaskDialogBox(owner, title, mainInstruction, content, expandedInfo, footer, verificationText, radioButtons, commandButtons, buttons, mainIcon, footerIcon, 0); }
//-------------------------------------------------------------------------------- public static DialogResult ShowTaskDialogBox(IWin32Window owner, string title, string mainInstruction, string content, string expandedInfo, string footer, string verificationText, string radioButtons, string commandButtons, ETaskDialogButtons buttons, ESysIcons mainIcon, ESysIcons footerIcon, int defaultIndex) { DialogResult result; OnTaskDialogShown?.Invoke(null, EventArgs.Empty); using (var td = new frmTaskDialog()) { td.Title = title; td.MainInstruction = mainInstruction; td.Content = content; td.ExpandedInfo = expandedInfo; td.Footer = footer; td.RadioButtons = radioButtons; td.CommandButtons = commandButtons; td.Buttons = buttons; td.MainIcon = mainIcon; td.FooterIcon = footerIcon; td.VerificationText = verificationText; td.Width = EmulatedFormWidth; td.DefaultButtonIndex = defaultIndex; td.BuildForm(); result = td.ShowDialog(owner); RadioButtonResult = td.RadioButtonIndex; CommandButtonResult = td.CommandButtonClickedIndex; VerificationChecked = td.VerificationCheckBoxChecked; } OnTaskDialogClosed?.Invoke(null, EventArgs.Empty); return result; }