[pitivi] Make schema backwards compatible with Gtk3.10
- From: Thibault Saunier <tsaunier src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] Make schema backwards compatible with Gtk3.10
- Date: Wed, 24 Sep 2014 17:04:10 +0000 (UTC)
commit 85560d03cfe2916f3024b9d894a6eca4464b2c10
Author: Lubosz Sarnecki <lubosz gmail com>
Date: Wed Sep 24 14:20:34 2014 +0200
Make schema backwards compatible with Gtk3.10
pitivi/utils/ui.py | 6 +++++-
1 files changed, 5 insertions(+), 1 deletions(-)
---
diff --git a/pitivi/utils/ui.py b/pitivi/utils/ui.py
index 70c45f2..62499ec 100644
--- a/pitivi/utils/ui.py
+++ b/pitivi/utils/ui.py
@@ -95,7 +95,11 @@ LAYER_CONTROL_TARGET_ENTRY = Gtk.TargetEntry.new("pitivi/layer-control", 0, TYPE
def _get_settings(schema):
if schema not in Gio.Settings.list_schemas():
return None
- return Gio.Settings(schema_id=schema)
+ try:
+ return Gio.Settings(schema_id=schema)
+ except TypeError:
+ # Gtk 3.10
+ return Gio.Settings(schema=schema)
def _get_font(font_spec, default):
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]