BrowserWindow.bjs
authorAlan Knowles <alan@roojs.com>
Tue, 24 Nov 2015 07:55:08 +0000 (15:55 +0800)
committerAlan Knowles <alan@roojs.com>
Tue, 24 Nov 2015 07:55:08 +0000 (15:55 +0800)
BrowserWindow.vala

BrowserWindow.bjs
BrowserWindow.vala

index 7d9f7a8..689a835 100644 (file)
@@ -12,7 +12,7 @@
     "destroy" : "() => {\n    Gtk.main_quit();\n}",
     "show" : "() => {\n\tthis.el.resize(1200,500);\n\tthis.view.el.load_uri(webkitpdf.opt_url);\n\n}"
    },
-   "xtype" : "Window",
+   "xtype" : "OffscreenWindow",
    "$ xns" : "Gtk",
    "Gtk.WindowType type" : "Gtk.WindowType.TOPLEVEL",
    "items" : [
index ba46bd5..afa2a5f 100644 (file)
@@ -2,7 +2,7 @@ static BrowserWindow  _BrowserWindow;
 
 public class BrowserWindow : Object
 {
-    public Gtk.Window el;
+    public Gtk.OffscreenWindow el;
     private BrowserWindow  _this;
 
     public static BrowserWindow singleton()
@@ -20,11 +20,12 @@ public class BrowserWindow : Object
     public BrowserWindow()
     {
         _this = this;
-        this.el = new Gtk.Window( Gtk.WindowType.TOPLEVEL );
+        this.el = new Gtk.OffscreenWindow();
 
         // my vars (dec)
 
         // set gobject values
+        this.el.type = Gtk.WindowType.TOPLEVEL;
         var child_0 = new Xcls_ScrolledWindow2( _this );
         child_0.ref();
         this.el.add (  child_0.el  );