billreminder r691 - in trunk: . src/gui
- From: ogmaciel svn gnome org
- To: svn-commits-list gnome org
- Subject: billreminder r691 - in trunk: . src/gui
- Date: Fri, 30 Jan 2009 16:38:46 +0000 (UTC)
Author: ogmaciel
Date: Fri Jan 30 16:38:46 2009
New Revision: 691
URL: http://svn.gnome.org/viewvc/billreminder?rev=691&view=rev
Log:
Fixes preferences dialog crashing when running without gconf schema installed.
Modified:
trunk/ChangeLog
trunk/src/gui/prefdialog.py
Modified: trunk/src/gui/prefdialog.py
==============================================================================
--- trunk/src/gui/prefdialog.py (original)
+++ trunk/src/gui/prefdialog.py Fri Jan 30 16:38:46 2009
@@ -189,11 +189,15 @@
else:
self.alertDialog.set_active(True)
- self.notifySpinButton.set_value(self.gconf_client.get_int(GCONF_ALARM_PATH + 'notification_days_limit'))
+ # Number of days before showing alarm
+ adays = self.gconf_client.get_int(GCONF_ALARM_PATH + 'notification_days_limit')
+ self.notifySpinButton.set_value(adays and adays or 3)
self.alertSpinButton.set_value(self.gconf_client.get_int(GCONF_ALARM_PATH + 'show_alarm_before_days'))
atime = self.gconf_client.get_string(GCONF_ALARM_PATH + 'show_alarm_at_time')
- atime = atime.split(":")
+ # Don't crash if running uninstalled and no gconf data
+ atime = atime and atime.split(":") or ['13', '00']
+
self.notificationTime.setHourMinute(atime[0], atime[1])
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]