Sample/RooProjectProperties.js
[app.Builder.js] / Sample / RooProjectProperties.js
1 Gtk = imports.gi.Gtk;
2 Gdk = imports.gi.Gdk;
3 Pango = imports.gi.Pango;
4 GLib = imports.gi.GLib;
5 Gio = imports.gi.Gio;
6 GObject = imports.gi.GObject;
7 GtkSource = imports.gi.GtkSource;
8 WebKit = imports.gi.WebKit;
9 Vte = imports.gi.Vte;
10 console = imports.console;
11 XObject = imports.XObject.XObject;
12 RooProjectProperties=new XObject({
13     xtype: Gtk.Dialog,
14     modal : true,
15     show : function() {
16         this.el.show_all();
17     },
18     listeners : {
19         "delete_event":function (self, event) {
20             this.el.hide()
21             return false;
22         }
23     },
24     items : [
25         {
26             xtype: Gtk.VBox,
27             pack : function(p,e) {
28                         p.el.get_content_area().add(e.el)
29                     },
30             items : [
31                 {
32                     xtype: Gtk.Table,
33                     pack : "add",
34                     n_columns : 2,
35                     n_rows : 2,
36                     homogeneous : true,
37                     items : [
38                         {
39                             xtype: Gtk.Label,
40                             pack : "add",
41                             label : "baseURL",
42                             'eft-attac' : 0,
43                             'op-attac' : 0,
44                             'ight-attac' : 1
45                         },
46                         {
47                             xtype: Gtk.Entry,
48                             pack : "add",
49                             'eft-attac' : 1,
50                             'op-attac' : 0,
51                             'ight-attac' : 2
52                         },
53                         {
54                             xtype: Gtk.Label,
55                             pack : "add",
56                             label : "baseURL",
57                             left_attach : 0,
58                             'op-attac' : 1
59                         },
60                         {
61                             xtype: Gtk.Entry,
62                             pack : "add",
63                             left_attach : 1,
64                             'op-attac' : 1
65                         }
66                     ]
67                 }
68             ]
69         }
70     ]
71 });
72 RooProjectProperties.init();
73 XObject.cache['/RooProjectProperties'] = RooProjectProperties;