Clones.bjs
[gitlive] / Clones.bjs
index f2543cf..e4d28b6 100644 (file)
@@ -8,12 +8,8 @@
  "build_module" : "",
  "items" : [
   {
-   "listeners" : {
-    "delete_event" : "(self, event) => {\n    this.el.hide();\n    return true; \n    //test  \n}\n ",
-    "response" : "(self, response_id) =>  { \n \n        this.el.hide();\n  \n}"
-   },
    "default_width" : 600,
-   "| void show" : "(Gtk.Widget button)    {\n\n    this.el.set_deletable(false);\n    this.el.show_all();\n    \t//console.log('show all');\n\tthis.el.set_modal(true);\n\tthis.el.set_relative_to(btn);\n\n\tthis.el.set_position(Gtk.PositionType.RIGHT);\n\n\t// window + header?\n\tthis.el.show_all();\n\tthis.el.set_size_request(800,500);\n\tthis.view.el.grab_focus();\n}\n",
+   "| void show" : "(Gtk.StatusIcon icon)    {\n\n    Gdk.Rectangle area;\n    Gdk.Screen screen;\n    Gtk.Orientation ori;\n    \n    icon.get_geometry(out screen, out area, out ori);\n    \n\tthis.el.set_pointing_to(area);\n    \n    \t//console.log('show all');\n\tthis.el.set_modal(true);\n\n\n\tthis.el.set_position(Gtk.PositionType.TOP);\n//\tthis.el.popup();\n\t// window + header?\n\tthis.el.show_all();\n\tthis.el.set_size_request(800,500);\n\n\t//this.view.el.grab_focus();\n}\n",
    "$ deletable" : true,
    "title" : "Manage Clones",
    "xtype" : "Popover",
@@ -24,7 +20,7 @@
    "items" : [
     {
      "xtype" : "Box",
-     "$ pack" : "get_content_area().add ",
+     "$ pack" : "add",
      "$ xns" : "Gtk",
      "Gtk.Orientation orientation" : "Gtk.Orientation.VERTICAL",
      "items" : [
          ]
         }
        ]
+      },
+      {
+       "label" : "Close",
+       "id" : "ok_button",
+       "* pack" : "add",
+       "xtype" : "Button",
+       "$ xns" : "Gtk"
       }
      ]
-    },
-    {
-     "label" : "Close",
-     "id" : "ok_button",
-     "* pack" : "add_action_widget,1 ",
-     "xtype" : "Button",
-     "$ xns" : "Gtk"
     }
    ]
   }