gnome-games r7820 - trunk/glchess/src/lib



Author: rancell
Date: Thu Aug 14 14:11:10 2008
New Revision: 7820
URL: http://svn.gnome.org/viewvc/gnome-games?rev=7820&view=rev

Log:
Catch gobject.GError correctly when writing to GConf (Bug #546694)


Modified:
   trunk/glchess/src/lib/config.py

Modified: trunk/glchess/src/lib/config.py
==============================================================================
--- trunk/glchess/src/lib/config.py	(original)
+++ trunk/glchess/src/lib/config.py	Thu Aug 14 14:11:10 2008
@@ -139,10 +139,11 @@
             function = _gconfSetFunction[type(value)]
         except KeyError:
             raise TypeError('Only config values of type: int, str, float, bool supported')
-        except gobject.GError:
-            pass
         else:
-            function(_GCONF_DIR + name, value)
+            try:
+                function(_GCONF_DIR + name, value)
+            except gobject.GError:
+                pass
 
     else:
         # Debounce



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