// ------------------------------------------------------------------------------ // // This code was generated by a tool. // Mono Runtime Version: 1.1.4322.2032 // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // // ------------------------------------------------------------------------------ namespace Stetic { class Gui { public static void Build(object obj, System.Type type) { Stetic.Gui.Build(obj, type.FullName); } public static void Build(object obj, string id) { System.Collections.Hashtable widgets = new System.Collections.Hashtable(); if ((id == "MainWindow")) { Gtk.Window cobj = ((Gtk.Window)(obj)); // Widget MainWindow cobj.Title = "Controller"; cobj.WindowPosition = ((Gtk.WindowPosition)(4)); cobj.Events = ((Gdk.EventMask)(0)); cobj.Name = "MainWindow"; // Container child MainWindow.Gtk.Container+ContainerChild Gtk.VBox w1 = new Gtk.VBox(); w1.Events = ((Gdk.EventMask)(0)); w1.Name = "vbox1"; // Container child vbox1.Gtk.Box+BoxChild Gtk.Frame w2 = new Gtk.Frame(); w2.ShadowType = ((Gtk.ShadowType)(0)); w2.LabelXalign = 0F; w2.Events = ((Gdk.EventMask)(0)); w2.Name = "frameHost"; // Container child frameHost.Gtk.Container+ContainerChild Gtk.Alignment w3 = new Gtk.Alignment(0F, 0F, 1F, 1F); w3.LeftPadding = ((System.UInt32)(12)); w3.Events = ((Gdk.EventMask)(0)); w3.Name = "GtkAlignment"; // Container child GtkAlignment.Gtk.Container+ContainerChild Gtk.HBox w4 = new Gtk.HBox(); w4.Events = ((Gdk.EventMask)(0)); w4.Name = "hbox1"; // Container child hbox1.Gtk.Box+BoxChild Gtk.Label w5 = new Gtk.Label(); w5.LabelProp = "Host: "; w5.Xalign = 0F; w5.Events = ((Gdk.EventMask)(0)); w5.Name = "labelHost"; widgets["labelHost"] = w5; w4.Add(w5); Gtk.Box.BoxChild w6 = ((Gtk.Box.BoxChild)(w4[w5])); w6.Position = 0; w6.Expand = false; w6.Fill = false; w6.Padding = ((System.UInt32)(5)); // Container child hbox1.Gtk.Box+BoxChild Gtk.Entry w7 = new Gtk.Entry(); w7.Editable = true; w7.InvisibleChar = '•'; w7.CanFocus = true; w7.Events = ((Gdk.EventMask)(0)); w7.Name = "entryHost"; widgets["entryHost"] = w7; w4.Add(w7); Gtk.Box.BoxChild w8 = ((Gtk.Box.BoxChild)(w4[w7])); w8.Position = 1; // Container child hbox1.Gtk.Box+BoxChild Gtk.Button w9 = new Gtk.Button(); w9.CanFocus = true; w9.Events = ((Gdk.EventMask)(0)); w9.Name = "buttonConnect"; w9.Label = "Connect"; widgets["buttonConnect"] = w9; w4.Add(w9); Gtk.Box.BoxChild w10 = ((Gtk.Box.BoxChild)(w4[w9])); w10.Position = 2; w10.Expand = false; w10.Fill = false; w10.Padding = ((System.UInt32)(3)); widgets["hbox1"] = w4; w3.Add(w4); widgets["GtkAlignment"] = w3; w2.Add(w3); Gtk.Label w13 = new Gtk.Label(); w13.LabelProp = "Connection"; w13.UseMarkup = true; w13.Events = ((Gdk.EventMask)(256)); w13.Name = "GtkLabel1"; widgets["GtkLabel1"] = w13; w2.LabelWidget = w13; widgets["frameHost"] = w2; w1.Add(w2); Gtk.Box.BoxChild w14 = ((Gtk.Box.BoxChild)(w1[w2])); w14.Position = 0; w14.Expand = false; w14.Fill = false; // Container child vbox1.Gtk.Box+BoxChild Gtk.Frame w15 = new Gtk.Frame(); w15.ShadowType = ((Gtk.ShadowType)(0)); w15.LabelXalign = 0F; w15.Events = ((Gdk.EventMask)(0)); w15.Name = "frameSelect"; // Container child frameSelect.Gtk.Container+ContainerChild Gtk.Alignment w16 = new Gtk.Alignment(0F, 0F, 1F, 1F); w16.LeftPadding = ((System.UInt32)(12)); w16.Events = ((Gdk.EventMask)(0)); w16.Name = "GtkAlignment1"; // Container child GtkAlignment1.Gtk.Container+ContainerChild Gtk.HBox w17 = new Gtk.HBox(); w17.Events = ((Gdk.EventMask)(0)); w17.Name = "hbox2"; // Container child hbox2.Gtk.Box+BoxChild Gtk.Label w18 = new Gtk.Label(); w18.LabelProp = "Mode:"; w18.Xalign = 0F; w18.Events = ((Gdk.EventMask)(0)); w18.Name = "labelMode"; widgets["labelMode"] = w18; w17.Add(w18); Gtk.Box.BoxChild w19 = ((Gtk.Box.BoxChild)(w17[w18])); w19.Position = 0; w19.Expand = false; w19.Fill = false; w19.Padding = ((System.UInt32)(5)); // Container child hbox2.Gtk.Box+BoxChild Gtk.ComboBox w20 = Gtk.ComboBox.NewText(); w20.AppendText("Move"); w20.AppendText("Blink"); w20.AppendText("Flash"); w20.Events = ((Gdk.EventMask)(0)); w20.Name = "comboboxMode"; widgets["comboboxMode"] = w20; w17.Add(w20); Gtk.Box.BoxChild w21 = ((Gtk.Box.BoxChild)(w17[w20])); w21.Position = 1; w21.Padding = ((System.UInt32)(2)); // Container child hbox2.Gtk.Box+BoxChild Gtk.Button w22 = new Gtk.Button(); w22.CanFocus = true; w22.Events = ((Gdk.EventMask)(0)); w22.Name = "buttonSubmit"; w22.Label = "Submit "; widgets["buttonSubmit"] = w22; w17.Add(w22); Gtk.Box.BoxChild w23 = ((Gtk.Box.BoxChild)(w17[w22])); w23.Position = 2; w23.Expand = false; w23.Fill = false; w23.Padding = ((System.UInt32)(3)); widgets["hbox2"] = w17; w16.Add(w17); widgets["GtkAlignment1"] = w16; w15.Add(w16); Gtk.Label w26 = new Gtk.Label(); w26.LabelProp = "Select"; w26.UseMarkup = true; w26.Events = ((Gdk.EventMask)(256)); w26.Name = "GtkLabelSelect"; widgets["GtkLabelSelect"] = w26; w15.LabelWidget = w26; widgets["frameSelect"] = w15; w1.Add(w15); Gtk.Box.BoxChild w27 = ((Gtk.Box.BoxChild)(w1[w15])); w27.Position = 1; w27.Expand = false; w27.Fill = false; // Container child vbox1.Gtk.Box+BoxChild Gtk.Frame w28 = new Gtk.Frame(); w28.ShadowType = ((Gtk.ShadowType)(0)); w28.LabelXalign = 0F; w28.Events = ((Gdk.EventMask)(0)); w28.Name = "frameCurrent"; // Container child frameCurrent.Gtk.Container+ContainerChild Gtk.Alignment w29 = new Gtk.Alignment(0F, 0F, 1F, 1F); w29.LeftPadding = ((System.UInt32)(12)); w29.Events = ((Gdk.EventMask)(0)); w29.Name = "GtkAlignment2"; // Container child GtkAlignment2.Gtk.Container+ContainerChild Gtk.HBox w30 = new Gtk.HBox(); w30.Events = ((Gdk.EventMask)(0)); w30.Name = "hbox3"; // Container child hbox3.Gtk.Box+BoxChild Gtk.Label w31 = new Gtk.Label(); w31.LabelProp = "disconnected"; w31.Events = ((Gdk.EventMask)(0)); w31.Name = "labelCurrent"; widgets["labelCurrent"] = w31; w30.Add(w31); Gtk.Box.BoxChild w32 = ((Gtk.Box.BoxChild)(w30[w31])); w32.Position = 0; w32.Expand = false; w32.Fill = false; widgets["hbox3"] = w30; w29.Add(w30); widgets["GtkAlignment2"] = w29; w28.Add(w29); Gtk.Label w35 = new Gtk.Label(); w35.LabelProp = "Status"; w35.UseMarkup = true; w35.Events = ((Gdk.EventMask)(256)); w35.Name = "GtkLabelStatus"; widgets["GtkLabelStatus"] = w35; w28.LabelWidget = w35; widgets["frameCurrent"] = w28; w1.Add(w28); Gtk.Box.BoxChild w36 = ((Gtk.Box.BoxChild)(w1[w28])); w36.Position = 2; w36.Expand = false; w36.Fill = false; widgets["vbox1"] = w1; cobj.Add(w1); cobj.DefaultWidth = 409; cobj.DefaultHeight = 169; widgets["MainWindow"] = cobj; w5.Show(); w7.Show(); w9.Show(); w4.Show(); w3.Show(); w13.Show(); w2.Show(); w18.Show(); w20.Show(); w22.Show(); w17.Show(); w16.Show(); w26.Show(); w15.Show(); w31.Show(); w30.Show(); w29.Show(); w35.Show(); w28.Show(); w1.Show(); cobj.Show(); cobj.DeleteEvent += ((Gtk.DeleteEventHandler)(System.Delegate.CreateDelegate(typeof(Gtk.DeleteEventHandler), cobj, "OnDeleteEvent"))); w7.Changed += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnEntryHostChanged"))); w9.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnButtonConnectClicked"))); w20.Changed += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnComboboxModeChanged"))); w22.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnButtonSubmitClicked"))); } System.Reflection.FieldInfo[] fields = obj.GetType().GetFields(((System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.NonPublic) | System.Reflection.BindingFlags.Instance)); for (int n = 0; (n < fields.Length); n = (n + 1)) { System.Reflection.FieldInfo field = fields[n]; object widget = widgets[field.Name]; if (((widget != null) && field.FieldType.IsInstanceOfType(widget))) { field.SetValue(obj, widget); } } } } }