From cf6b91ffe977edd9f3d24435d59cb1eb8329123f Mon Sep 17 00:00:00 2001 From: John Ralls Date: Thu, 19 Jul 2012 23:55:35 +0000 Subject: [PATCH] Fix up mac integration for introspection Requires not-yet-released gtk-mac-integration 1.1.0 svn: r20033 --- src/gen/constfunc.py | 2 +- src/gui/viewmanager.py | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/gen/constfunc.py b/src/gen/constfunc.py index cfdc5ff27..303f7fdc0 100644 --- a/src/gen/constfunc.py +++ b/src/gen/constfunc.py @@ -94,7 +94,7 @@ def is_quartz(): from gi.repository import Gdk except: return False - return Gdk.Display.get_default().__class__.__name__.endswith("quartzDisplay") + return Gdk.Display.get_default().__class__.__name__.endswith("QuartzDisplay") return False def has_display(): diff --git a/src/gui/viewmanager.py b/src/gui/viewmanager.py index f0438a9ef..073fbe171 100644 --- a/src/gui/viewmanager.py +++ b/src/gui/viewmanager.py @@ -108,9 +108,10 @@ from gen.utils.configmanager import safe_eval #------------------------------------------------------------------------- if is_quartz(): try: - import gtk_osxapplication as QuartzApp + from gi.repository import GtkosxApplication as QuartzApp _GTKOSXAPPLICATION = True except: + print ("Failed to import gtk_osxapplication") _GTKOSXAPPLICATION = False else: _GTKOSXAPPLICATION = False @@ -305,7 +306,7 @@ class ViewManager(CLIManager): """ CLIManager.__init__(self, dbstate, False) if _GTKOSXAPPLICATION: - self.macapp = QuartzApp.OSXApplication() + self.macapp = QuartzApp.Application() self.view_category_order = view_category_order