diff options
author | Federico Mena Quintero <federico@ximian.com> | 2001-10-30 17:25:24 +0800 |
---|---|---|
committer | Federico Mena Quintero <federico@src.gnome.org> | 2001-10-30 17:25:24 +0800 |
commit | f3c4424cca6a4072d59c6de24524b0ca7f2a6ec5 (patch) | |
tree | 7ab4397aab4f3e85da00c269112ddc3b1a75b49c /calendar/gui/dialogs | |
parent | 6bf38a0ba9bc70423c228445de61d6cbf4f7bd60 (diff) | |
download | gsoc2013-evolution-f3c4424cca6a4072d59c6de24524b0ca7f2a6ec5.tar gsoc2013-evolution-f3c4424cca6a4072d59c6de24524b0ca7f2a6ec5.tar.gz gsoc2013-evolution-f3c4424cca6a4072d59c6de24524b0ca7f2a6ec5.tar.bz2 gsoc2013-evolution-f3c4424cca6a4072d59c6de24524b0ca7f2a6ec5.tar.lz gsoc2013-evolution-f3c4424cca6a4072d59c6de24524b0ca7f2a6ec5.tar.xz gsoc2013-evolution-f3c4424cca6a4072d59c6de24524b0ca7f2a6ec5.tar.zst gsoc2013-evolution-f3c4424cca6a4072d59c6de24524b0ca7f2a6ec5.zip |
Use an EMessageBox instead of a gnome_dialog_question so that the label
2001-10-30 Federico Mena Quintero <federico@ximian.com>
* gui/dialogs/delete-comp.c (delete_component_dialog): Use an
EMessageBox instead of a gnome_dialog_question so that the label
gets line breaking. Fixes bug #11260.
2001-10-29 Federico Mena Quintero <federico@ximian.com>
Fix bug #13649.
* gui/calendar-config.c
(calendar_config_get_use_default_reminder): New function.
(calendar_config_set_use_default_reminder): New function.
(calendar_config_get_default_reminder_interval): New function.
(calendar_config_set_default_reminder_interval): New function.
(calendar_config_get_default_reminder_units): New function.
(calendar_config_set_default_reminder_units): New function.
(config_read): Get the options for default reminders.
(calendar_config_write): Set the options for default reminders.
* gui/dialogs/cal-prefs-dialog.c (cal_prefs_dialog_show_config):
Set the default reminder widgets from the config values.
(cal_prefs_dialog_update_config): Set the config values from the
widgets.
* gui/comp-util.c (cal_comp_event_new_with_defaults): New
function; creates a VEVENT component with the default alarm.
* gui/e-day-view.c (e_day_view_key_press): Use
cal_comp_event_new_with_defaults ();
* gui/e-week-view.c (e_week_view_key_press): Likewise.
* gui/calendar-model.c (calendar_model_append_row): Likewise.
* gui/comp-editor-factory.c (get_default_component): Likewise.
* gui/gnome-cal.c (gnome_calendar_new_appointment_for): Likewise.
* cal-util/cal-component.c (ensure_alarm_properties_cb): Ensure we
have a DESCRIPTION property.
(cal_component_commit_sequence): Ensure we have the mandatory
alarm properties.
svn path=/trunk/; revision=14446
Diffstat (limited to 'calendar/gui/dialogs')
-rw-r--r-- | calendar/gui/dialogs/cal-prefs-dialog.c | 21 | ||||
-rw-r--r-- | calendar/gui/dialogs/delete-comp.c | 14 |
2 files changed, 30 insertions, 5 deletions
diff --git a/calendar/gui/dialogs/cal-prefs-dialog.c b/calendar/gui/dialogs/cal-prefs-dialog.c index 9372236d56..fc8d7b0c91 100644 --- a/calendar/gui/dialogs/cal-prefs-dialog.c +++ b/calendar/gui/dialogs/cal-prefs-dialog.c @@ -83,10 +83,15 @@ static const int time_division_map[] = { 60, 30, 15, 10, 5, -1 }; +/* The following two are kept separate in case we need to re-order each menu individually */ static const int hide_completed_units_map[] = { CAL_MINUTES, CAL_HOURS, CAL_DAYS, -1 }; +static const int default_reminder_units_map[] = { + CAL_MINUTES, CAL_HOURS, CAL_DAYS, -1 +}; + static void cal_prefs_dialog_class_init (CalPrefsDialogClass *class); static void cal_prefs_dialog_init (CalPrefsDialog *prefs); @@ -562,6 +567,14 @@ cal_prefs_dialog_show_config (CalPrefsDialog *prefs) /* Other page */ e_dialog_toggle_set (priv->confirm_delete, calendar_config_get_confirm_delete ()); + + e_dialog_toggle_set (priv->default_reminder, + calendar_config_get_use_default_reminder ()); + e_dialog_spin_set (priv->default_reminder_interval, + calendar_config_get_default_reminder_interval ()); + e_dialog_option_menu_set (priv->default_reminder_units, + calendar_config_get_default_reminder_units (), + default_reminder_units_map); } /* Returns a pointer to a static string with an X color spec for the current @@ -657,6 +670,14 @@ cal_prefs_dialog_update_config (CalPrefsDialog *prefs) calendar_config_set_confirm_delete (e_dialog_toggle_get (priv->confirm_delete)); + calendar_config_set_use_default_reminder (e_dialog_toggle_get (priv->default_reminder)); + + calendar_config_set_default_reminder_interval ( + e_dialog_spin_get_int (priv->default_reminder_interval)); + + calendar_config_set_default_reminder_units ( + e_dialog_option_menu_get (priv->default_reminder_units, default_reminder_units_map)); + /* Done */ calendar_config_write (); diff --git a/calendar/gui/dialogs/delete-comp.c b/calendar/gui/dialogs/delete-comp.c index 1fc757c38c..405a9445b4 100644 --- a/calendar/gui/dialogs/delete-comp.c +++ b/calendar/gui/dialogs/delete-comp.c @@ -25,10 +25,9 @@ #include <glib.h> #include <libgnome/gnome-defs.h> #include <libgnome/gnome-i18n.h> -#include <libgnomeui/gnome-dialog.h> -#include <libgnomeui/gnome-dialog-util.h> -#include <libgnomeui/gnome-uidefs.h> +#include <libgnomeui/gnome-stock.h> #include <gal/widgets/e-unicode.h> +#include "widgets/misc/e-messagebox.h" #include "../calendar-config.h" #include "delete-comp.h" @@ -151,10 +150,15 @@ delete_component_dialog (CalComponent *comp, } } - dialog = gnome_question_dialog_modal (str, NULL, NULL); + dialog = e_message_box_new (str, E_MESSAGE_BOX_QUESTION, + GNOME_STOCK_BUTTON_YES, + GNOME_STOCK_BUTTON_NO, + NULL); g_free (str); - if (gnome_dialog_run (GNOME_DIALOG (dialog)) == GNOME_YES) + gtk_widget_hide (e_message_box_get_checkbox (E_MESSAGE_BOX (dialog))); + + if (gnome_dialog_run_and_close (GNOME_DIALOG (dialog)) == 0) return TRUE; else return FALSE; |