Blame SOURCES/0004-Fall-back-to-auto_select-False-if-neither-dconf-nor-.patch

b385cc
From 3d03bd8f8c558392db42897370cef65bdbad57bd Mon Sep 17 00:00:00 2001
b385cc
From: Mike FABIAN <mfabian@redhat.com>
b385cc
Date: Tue, 5 Feb 2013 09:11:17 +0100
b385cc
Subject: [PATCH 4/5] Fall back to auto_select = False if neither dconf nor
b385cc
 the table have a value for auto_select
b385cc
b385cc
---
b385cc
 engine/table.py | 11 ++++++++---
b385cc
 1 file changed, 8 insertions(+), 3 deletions(-)
b385cc
b385cc
diff --git a/engine/table.py b/engine/table.py
b385cc
index f0a8a61..3999c35 100644
b385cc
--- a/engine/table.py
b385cc
+++ b/engine/table.py
b385cc
@@ -233,8 +233,10 @@ class editor(object):
b385cc
                 self._config_section,
b385cc
                 "AutoSelect"))
b385cc
         if self._auto_select == None:
b385cc
-            self._auto_select = self.db.get_ime_property('auto_select').lower() == u'true'
b385cc
-        
b385cc
+            if self.db.get_ime_property('auto_select') != None:
b385cc
+                self._auto_select = self.db.get_ime_property('auto_select').lower() == u'true'
b385cc
+            else:
b385cc
+                self._auto_select = False
b385cc
 
b385cc
     def init_select_keys(self):
b385cc
         # __select_keys: lookup table select keys/labels
b385cc
@@ -1162,7 +1164,10 @@ class tabengine (IBus.Engine):
b385cc
                 self._config_section,
b385cc
                 "AutoSelect"))
b385cc
         if self._auto_select == None:
b385cc
-            self._auto_select = self.db.get_ime_property('auto_select').lower() == u'true'
b385cc
+            if self.db.get_ime_property('auto_select') != None:
b385cc
+                self._auto_select = self.db.get_ime_property('auto_select').lower() == u'true'
b385cc
+            else:
b385cc
+                self._auto_select = False
b385cc
         
b385cc
         # the commit phrases length
b385cc
         self._len_list = [0]
b385cc
-- 
b385cc
1.7.11.7
b385cc