[sushi/wip/cosimoc/no-clutter: 33/66] Adjust versioned imports



commit 905e7a1dee14dabfd4371d0c3fc91236fb0b79b5
Author: Cosimo Cecchi <cosimoc gnome org>
Date:   Mon Apr 3 12:54:13 2017 -0700

    Adjust versioned imports
    
    It's unfortunate that we have to specify these in two places, but we'll
    have to live with the hack until we refactor how viewers are registered.

 src/js/ui/main.js       | 2 ++
 src/js/ui/mainWindow.js | 2 --
 src/js/viewers/image.js | 2 ++
 3 files changed, 4 insertions(+), 2 deletions(-)
---
diff --git a/src/js/ui/main.js b/src/js/ui/main.js
index 64717bf..1a974f8 100644
--- a/src/js/ui/main.js
+++ b/src/js/ui/main.js
@@ -22,6 +22,8 @@
  * Authors: Cosimo Cecchi <cosimoc redhat com>
  *
  */
+imports.gi.versions.GdkX11 = '3.0';
+imports.gi.versions.Gtk = '3.0';
 
 const Format = imports.format;
 const Gettext = imports.gettext;
diff --git a/src/js/ui/mainWindow.js b/src/js/ui/mainWindow.js
index 1497637..5e3eb3c 100644
--- a/src/js/ui/mainWindow.js
+++ b/src/js/ui/mainWindow.js
@@ -23,8 +23,6 @@
  *
  */
 
-imports.gi.versions.GdkX11 = '3.0';
-
 const Gdk = imports.gi.Gdk;
 const GdkX11 = imports.gi.GdkX11;
 const Gio = imports.gi.Gio;
diff --git a/src/js/viewers/image.js b/src/js/viewers/image.js
index 84dcb4e..8cdbbd5 100644
--- a/src/js/viewers/image.js
+++ b/src/js/viewers/image.js
@@ -22,6 +22,8 @@
  * Authors: Cosimo Cecchi <cosimoc redhat com>
  *
  */
+imports.gi.versions.Gdk = '3.0';
+imports.gi.versions.Gtk = '3.0';
 
 const Gdk = imports.gi.Gdk;
 const GdkPixbuf = imports.gi.GdkPixbuf;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]