def on_day_start_changed(self, widget): day_start = self.day_start.time if day_start is None: return day_start = day_start.hour * 60 + day_start.minute conf.set("day-start-minutes", day_start)
def on_day_start_changed(self, widget): day_start = self.day_start.get_time() if day_start is None: return day_start = day_start.hour * 60 + day_start.minute conf.set("day_start_minutes", day_start)
def on_save_button_clicked(self): path, format = None, None format = "html" if self.dialog.get_filter() in self.filters: format = self.filters[self.dialog.get_filter()] path = self.dialog.get_filename() # append correct extension if it is missing # TODO - proper way would be to change extension on filter change # only pointer in web is http://www.mail-archive.com/[email protected]/msg08740.html if path.endswith(".%s" % format) == False: path = "%s.%s" % (path.rstrip("."), format) categories = [] conf.set("last_report_folder", os.path.dirname(path)) # format, path, start_date, end_date self.emit("report-chosen", format, path) self.dialog.destroy() self.dialog = None
def on_notify_interval_value_changed(self, scale): value = int(scale.get_value()) conf.set("notify_interval", value) self.get_widget("notify_on_idle").set_sensitive(value <= 120)
def on_notify_on_idle_toggled(self, checkbox): conf.set("notify_on_idle", checkbox.get_active())
def on_idle_track_toggled(self, checkbox): conf.set("enable_timeout", checkbox.get_active())
def on_shutdown_track_toggled(self, checkbox): conf.set("stop_on_shutdown", checkbox.get_active())
def on_todo_combo_changed(self, combo): conf.set("activities_source", self.activities_sources[combo.get_active()][0])
def on_lock_on_idle_toggled(self, checkbox): conf.set("lock_on_idle", checkbox.get_active())