aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/e-cal-model.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2009-07-29 09:01:08 +0800
committerMatthew Barnes <mbarnes@redhat.com>2009-07-29 09:33:01 +0800
commit41569bb778e228d4f5a04cb1e15bfa5b49bb044b (patch)
tree3cd61379dbfcca4a9998800bbe9680b87fcb9692 /calendar/gui/e-cal-model.c
parent7bebc31932e74db65e3720f32ab2f6664fd9e58b (diff)
downloadgsoc2013-evolution-41569bb778e228d4f5a04cb1e15bfa5b49bb044b.tar.gz
gsoc2013-evolution-41569bb778e228d4f5a04cb1e15bfa5b49bb044b.tar.zst
gsoc2013-evolution-41569bb778e228d4f5a04cb1e15bfa5b49bb044b.zip
Trimming redundancy.
Diffstat (limited to 'calendar/gui/e-cal-model.c')
-rw-r--r--calendar/gui/e-cal-model.c19
1 files changed, 12 insertions, 7 deletions
diff --git a/calendar/gui/e-cal-model.c b/calendar/gui/e-cal-model.c
index 0ddcc20d07..747635998e 100644
--- a/calendar/gui/e-cal-model.c
+++ b/calendar/gui/e-cal-model.c
@@ -1245,16 +1245,21 @@ e_cal_model_get_use_24_hour_format (ECalModel *model)
* e_cal_model_set_use_24_hour_format
*/
void
-e_cal_model_set_use_24_hour_format (ECalModel *model, gboolean use24)
+e_cal_model_set_use_24_hour_format (ECalModel *model,
+ gboolean use_24_hour_format)
{
g_return_if_fail (E_IS_CAL_MODEL (model));
- if (model->priv->use_24_hour_format != use24) {
- e_table_model_pre_change (E_TABLE_MODEL (model));
- model->priv->use_24_hour_format = use24;
- /* Get the views to redraw themselves. */
- e_table_model_changed (E_TABLE_MODEL (model));
- }
+ if (model->priv->use_24_hour_format == use_24_hour_format)
+ return;
+
+ e_table_model_pre_change (E_TABLE_MODEL (model));
+ model->priv->use_24_hour_format = use_24_hour_format;
+
+ /* Get the views to redraw themselves. */
+ e_table_model_changed (E_TABLE_MODEL (model));
+
+ g_object_notify (G_OBJECT (model), "use-24-hour-format");
}
/**