aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/gi/gi-test.py
diff options
context:
space:
mode:
authorThomas Martitz <kugel@rockbox.org>2015-12-13 23:01:55 +0100
committerThomas Martitz <kugel@rockbox.org>2015-12-13 23:01:55 +0100
commitcc984ff6b1eaa5a653a85b3dfbb712363170bfec (patch)
tree377e417191115b55288dbdf93a299a38bc7fd2d2 /test/gi/gi-test.py
parent8de54ce5954362d9b5eecb0629aeb9daa69cd688 (diff)
downloadscintilla-mirror-cc984ff6b1eaa5a653a85b3dfbb712363170bfec.tar.gz
Fix issues raised by review and some more
- remove any notion of deprecation of legacy symbol names - make sure typelib search path is set for test program - add separate test target to test/gi/makefile - improve g-ir-scanner call command line - fixed gtk2 support of test test/gi/gi-test.py
Diffstat (limited to 'test/gi/gi-test.py')
-rw-r--r--test/gi/gi-test.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/test/gi/gi-test.py b/test/gi/gi-test.py
index 10cee8bc6..6c775ea0c 100644
--- a/test/gi/gi-test.py
+++ b/test/gi/gi-test.py
@@ -1,6 +1,12 @@
#!/usr/bin/python
-from gi.repository import Gtk
+import gi
+gi.require_version('Scintilla', '0.1')
+
+# Scintilla is imported before because it loads Gtk with a specified version
+# this avoids a warning when Gtk is imported without version such as below (where
+# it is imported without because this script works with gtk2 and gtk3)
from gi.repository import Scintilla
+from gi.repository import Gtk
win = Gtk.Window()
win.connect("delete-event", Gtk.main_quit)