Пример #1
0
        private void MBox_msgShow(object sender, EventArgs e)
        {
            //IL_0009: Unknown result type (might be due to invalid IL or missing references)
            //IL_000e: Unknown result type (might be due to invalid IL or missing references)
            //IL_001b: Expected O, but got Unknown
            //IL_003c: Unknown result type (might be due to invalid IL or missing references)
            //IL_0046: Expected O, but got Unknown
            msgBoxEventArg msgBoxEventArg = (msgBoxEventArg)e;
            Dialog         val            = null;

            try
            {
                Dialog val2 = new Dialog();
                ((Window)val2).set_Title(msgBoxEventArg.Title);
                val = (Dialog)(object)val2;
                val.AddButton("ok", (ResponseType)(-5));
                ((Window)val).SetPosition((WindowPosition)3);
                ((Container)val.get_VBox()).Add((Widget)(object)new Label(msgBoxEventArg.Message));
                ((Widget)val).ShowAll();
                val.Run();
            }
            finally
            {
                if (val != null)
                {
                    ((Object)val).Destroy();
                }
            }
        }
Пример #2
0
        private void MBox_msgShow(object sender, EventArgs e)
        {
            msgBoxEventArg msgBoxEventArg = (msgBoxEventArg)e;
            Dialog         val            = null;

            try
            {
                val = new Dialog()
                {
                    Title = msgBoxEventArg.Title
                };

                val.AddButton("ok", (ResponseType)(-5));
                val.SetPosition((WindowPosition)3);
                val.VBox.Add(new Label(msgBoxEventArg.Message));
                ((Widget)val).ShowAll();
                val.Run();
            }
            finally
            {
                if (val != null)
                {
                    val.Dispose();
                }
            }
        }