src/Builder4/WindowRooView.bjs
authorAlan Knowles <alan@roojs.com>
Wed, 20 May 2015 10:20:16 +0000 (18:20 +0800)
committerAlan Knowles <alan@roojs.com>
Wed, 20 May 2015 10:20:16 +0000 (18:20 +0800)
src/Builder4/WindowRooView.vala

src/Builder4/WindowRooView.bjs
src/Builder4/WindowRooView.vala

index 36a0955..7a76cba 100644 (file)
@@ -10,7 +10,7 @@
   {
    "id" : "WindowRooView",
    "| void loadFile" : "(JsRender.JsRender file)\n{\n    this.file = file;\n    this.view.renderJS(true);\n}",
-   "| void createThumb" : "() {\n    \n    \n    if (this.file == null) {\n        return;\n    }\n    var filename = this.file.getIconFileName(false);\n    \n    var  win = this.el.get_parent_window();\n    var width = win.get_width();\n  //  var height = win.get_height();\n    try { \n        Gdk.Pixbuf screenshot = Gdk.pixbuf_get_from_window(win, 0, 0, width, this.el.position);\n        screenshot.save(filename,\"png\");\n    } catch(e) {\n        //noop\n    }\n\n    \n    \n    \n\n\n    \n     \n}\n",
+   "| void createThumb" : "() {\n    \n    \n    if (this.file == null) {\n        return;\n    }\n    var filename = this.file.getIconFileName(false);\n    \n    var  win = this.el.get_parent_window();\n    var width = win.get_width();\n  //  var height = win.get_height();\n    try { \n        Gdk.Pixbuf screenshot = Gdk.pixbuf_get_from_window(win, 0, 0, width, this.el.position);\n        screenshot.save(filename,\"png\");\n    } catch(Error e) {\n        //noop\n    }\n\n    \n    \n    \n\n\n    \n     \n}\n",
    "* pack" : "add",
    "xtype" : "Paned",
    "# JsRender.JsRender file" : "",
index 37fca66..e741452 100644 (file)
@@ -58,7 +58,7 @@ public class Xcls_WindowRooView : Object
         try { 
             Gdk.Pixbuf screenshot = Gdk.pixbuf_get_from_window(win, 0, 0, width, this.el.position);
             screenshot.save(filename,"png");
-        } catch(e) {
+        } catch(Error e) {
             //noop
         }