aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/dialogs
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2009-04-24 22:58:15 +0800
committerMilan Crha <mcrha@redhat.com>2009-04-24 22:58:15 +0800
commit501da8aa29d496ef765a3afb5ac1b3fc1361c7e2 (patch)
treef5bedbacaf400f26505612f5111ec2bf89c5f37c /calendar/gui/dialogs
parentcd26e8a609574335e684df2f1eef55f2a11c2bdf (diff)
downloadgsoc2013-evolution-501da8aa29d496ef765a3afb5ac1b3fc1361c7e2.tar.gz
gsoc2013-evolution-501da8aa29d496ef765a3afb5ac1b3fc1361c7e2.tar.zst
gsoc2013-evolution-501da8aa29d496ef765a3afb5ac1b3fc1361c7e2.zip
Get rid of "Adjust for daylight saving time" option
** Fix for bug #577615 * gui/dialogs/cal-prefs-dialog.h: (struct _CalendarPrefsDialog): * gui/dialogs/cal-prefs-dialog.c: (timezone_changed), (daylight_saving_changed), (setup_changes), (show_config), (calendar_prefs_dialog_construct): * gui/dialogs/cal-prefs-dialog.glade: * gui/apps_evolution_calendar.schemas.in: * gui/calendar-config-keys.h: * gui/calendar-config.h: * gui/calendar-config.c: (set_standard_offsets), (calendar_config_get_icaltimezone), (calendar_config_get_daylight_saving), (calendar_config_set_daylight_saving), (calendar_config_add_notification_daylight_saving): Get rid of "Adjust for daylight saving time" option.
Diffstat (limited to 'calendar/gui/dialogs')
-rw-r--r--calendar/gui/dialogs/cal-prefs-dialog.c27
-rw-r--r--calendar/gui/dialogs/cal-prefs-dialog.glade22
-rw-r--r--calendar/gui/dialogs/cal-prefs-dialog.h1
3 files changed, 0 insertions, 50 deletions
diff --git a/calendar/gui/dialogs/cal-prefs-dialog.c b/calendar/gui/dialogs/cal-prefs-dialog.c
index 81e182ac54..edb802fd10 100644
--- a/calendar/gui/dialogs/cal-prefs-dialog.c
+++ b/calendar/gui/dialogs/cal-prefs-dialog.c
@@ -119,15 +119,8 @@ static void
timezone_changed (GtkWidget *widget, CalendarPrefsDialog *prefs)
{
icaltimezone *zone;
- icalcomponent *icalcomp, *dl_comp;
zone = e_timezone_entry_get_timezone (E_TIMEZONE_ENTRY (prefs->timezone));
- icalcomp = icaltimezone_get_component (zone);
-
- if (!icalcomp || !(dl_comp = icalcomponent_get_first_component (icalcomp, ICAL_XDAYLIGHT_COMPONENT)))
- gtk_widget_set_sensitive ((GtkWidget *) prefs->daylight_saving, FALSE);
- else
- gtk_widget_set_sensitive ((GtkWidget *) prefs->daylight_saving, TRUE);
calendar_config_set_timezone (icaltimezone_get_location (zone));
}
@@ -228,14 +221,6 @@ day_second_zone_clicked (GtkWidget *widget, CalendarPrefsDialog *prefs)
}
static void
-daylight_saving_changed (GtkWidget *widget, CalendarPrefsDialog *prefs)
-{
- gboolean set = gtk_toggle_button_get_active ((GtkToggleButton *) prefs->daylight_saving);
- calendar_config_set_daylight_saving (set);
- timezone_changed (widget, prefs);
-}
-
-static void
start_of_day_changed (GtkWidget *widget, CalendarPrefsDialog *prefs)
{
int start_hour, start_minute, end_hour, end_minute;
@@ -504,7 +489,6 @@ setup_changes (CalendarPrefsDialog *prefs)
g_signal_connect (G_OBJECT (prefs->timezone), "changed", G_CALLBACK (timezone_changed), prefs);
g_signal_connect (G_OBJECT (prefs->day_second_zone), "clicked", G_CALLBACK (day_second_zone_clicked), prefs);
- g_signal_connect (G_OBJECT (prefs->daylight_saving), "toggled", G_CALLBACK (daylight_saving_changed), prefs);
g_signal_connect (G_OBJECT (prefs->start_of_day), "changed", G_CALLBACK (start_of_day_changed), prefs);
g_signal_connect (G_OBJECT (prefs->end_of_day), "changed", G_CALLBACK (end_of_day_changed), prefs);
@@ -632,7 +616,6 @@ show_config (CalendarPrefsDialog *prefs)
gint mask, day, week_start_day, time_divisions;
icaltimezone *zone;
gboolean sensitive, set = FALSE;
- icalcomponent *icalcomp, *dl_comp;
char *location;
CalUnits units;
int interval;
@@ -643,15 +626,6 @@ show_config (CalendarPrefsDialog *prefs)
e_timezone_entry_set_timezone (E_TIMEZONE_ENTRY (prefs->timezone), zone);
g_free (location);
- icalcomp = icaltimezone_get_component (zone);
- if (!icalcomp || !(dl_comp = icalcomponent_get_first_component (icalcomp, ICAL_XDAYLIGHT_COMPONENT)))
- gtk_widget_set_sensitive ((GtkWidget *) prefs->daylight_saving, FALSE);
- else
- gtk_widget_set_sensitive ((GtkWidget *) prefs->daylight_saving, TRUE);
-
- set = calendar_config_get_daylight_saving ();
- gtk_toggle_button_set_active ((GtkToggleButton *) prefs->daylight_saving, set);
-
/* Day's second zone */
update_day_second_zone_caption (prefs);
@@ -790,7 +764,6 @@ calendar_prefs_dialog_construct (CalendarPrefsDialog *prefs)
/* General tab */
prefs->timezone = glade_xml_get_widget (gui, "timezone");
prefs->day_second_zone = glade_xml_get_widget (gui, "day_second_zone");
- prefs->daylight_saving = glade_xml_get_widget (gui, "daylight_cb");
for (i = 0; i < 7; i++)
prefs->working_days[i] = glade_xml_get_widget (gui, working_day_names[i]);
prefs->week_start_day = glade_xml_get_widget (gui, "week_start_day");
diff --git a/calendar/gui/dialogs/cal-prefs-dialog.glade b/calendar/gui/dialogs/cal-prefs-dialog.glade
index f3509e4f8f..23406d5963 100644
--- a/calendar/gui/dialogs/cal-prefs-dialog.glade
+++ b/calendar/gui/dialogs/cal-prefs-dialog.glade
@@ -152,28 +152,6 @@
</child>
<child>
- <widget class="GtkCheckButton" id="daylight_cb">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">Adjust for daylight sa_ving time</property>
- <property name="use_underline">True</property>
- <property name="relief">GTK_RELIEF_NORMAL</property>
- <property name="focus_on_click">True</property>
- <property name="active">False</property>
- <property name="inconsistent">False</property>
- <property name="draw_indicator">True</property>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
- <property name="x_options">fill</property>
- <property name="y_options"></property>
- </packing>
- </child>
-
- <child>
<widget class="GtkHBox" id="hbox4">
<property name="visible">True</property>
<property name="homogeneous">False</property>
diff --git a/calendar/gui/dialogs/cal-prefs-dialog.h b/calendar/gui/dialogs/cal-prefs-dialog.h
index 3c006b8711..945c1d6e16 100644
--- a/calendar/gui/dialogs/cal-prefs-dialog.h
+++ b/calendar/gui/dialogs/cal-prefs-dialog.h
@@ -45,7 +45,6 @@ struct _CalendarPrefsDialog {
/* General tab */
GtkWidget *timezone;
GtkWidget *day_second_zone;
- GtkWidget *daylight_saving;
GtkWidget *working_days[7];
GtkWidget *week_start_day;
GtkWidget *start_of_day;