Exemple #1
0
        // null in caption prints "Warning"

        static public DialogResult Show(IWin32Window window, string text, string caption = null, MessageBoxButtons buttons = MessageBoxButtons.OK, MessageBoxIcon icon = MessageBoxIcon.None, Icon windowicon = null)
        {
            using (MessageBoxTheme msg = new MessageBoxTheme(text, caption, buttons, icon, windowicon))
            {
                return(msg.ShowDialog(window));
            }
        }
Exemple #2
0
 static public DialogResult Show(string text, string caption = "Warning", MessageBoxButtons buttons = MessageBoxButtons.OK, MessageBoxIcon icon = MessageBoxIcon.None, Icon windowicon = null)
 {
     using (MessageBoxTheme msg = new MessageBoxTheme(text, caption, buttons, icon, windowicon))
     {
         return(msg.ShowDialog(Application.OpenForms[0]));
     }
 }
        static public DialogResult Show(IWin32Window window, string text, string caption = "EDDiscovery Message", MessageBoxButtons buttons = MessageBoxButtons.OK, MessageBoxIcon icon = MessageBoxIcon.None)
        {
            MessageBoxTheme msg = new MessageBoxTheme();

            msg.StartPosition = FormStartPosition.CenterParent;
            msg.Init(text, caption, buttons, icon, ThemeableFormsInstance.Instance?.MessageBoxWindowIcon);
            return(msg.ShowDialog(window));
        }
Exemple #4
0
        static public DialogResult Show(IWin32Window window, string text, string caption = "Warning", MessageBoxButtons buttons = MessageBoxButtons.OK, MessageBoxIcon icon = MessageBoxIcon.None, Icon windowicon = null)
        {
            MessageBoxTheme msg = new MessageBoxTheme();

            msg.StartPosition = FormStartPosition.CenterParent;
            msg.Init(text, caption, buttons, icon, windowicon);
            return(msg.ShowDialog(window));
        }
Exemple #5
0
        static public DialogResult Show(string text, string caption = "EDDiscovery Message", MessageBoxButtons buttons = MessageBoxButtons.OK, MessageBoxIcon icon = MessageBoxIcon.None)
        {
            MessageBoxTheme msg = new MessageBoxTheme();

            msg.StartPosition = FormStartPosition.CenterScreen;
            msg.Init(text, caption, buttons, icon);
            return(msg.ShowDialog());
        }
        static public DialogResult Show(string text, string caption = "EDDiscovery Message", MessageBoxButtons buttons = MessageBoxButtons.OK, MessageBoxIcon icon = MessageBoxIcon.None)
        {
            MessageBoxTheme msg = new MessageBoxTheme();

            msg.StartPosition = FormStartPosition.CenterScreen;
            msg.Init(text, caption, buttons, icon, ThemeableFormsInstance.Instance?.MessageBoxWindowIcon);
            Form f = Application.OpenForms[0];

            return(msg.ShowDialog(f));
        }
Exemple #7
0
        static public DialogResult Show(string text, string caption = "Warning", MessageBoxButtons buttons = MessageBoxButtons.OK, MessageBoxIcon icon = MessageBoxIcon.None, Icon windowicon = null)
        {
            MessageBoxTheme msg = new MessageBoxTheme();

            msg.StartPosition = FormStartPosition.CenterScreen;
            msg.Init(text, caption, buttons, icon, windowicon);
            Form f = Application.OpenForms[0];

            return(msg.ShowDialog(f));
        }