[evolution] [ECalOps] ECalModel not always provided when creating a new component editor
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution] [ECalOps] ECalModel not always provided when creating a new component editor
- Date: Fri, 31 Oct 2014 17:12:15 +0000 (UTC)
commit 5e1a4b21ee47a5dbf96a1807f2d45a1dd9f282f1
Author: Milan Crha <mcrha redhat com>
Date: Fri Oct 31 18:11:05 2014 +0100
[ECalOps] ECalModel not always provided when creating a new component editor
Produced runtime warnings.
calendar/gui/e-cal-ops.c | 8 +++++---
1 files changed, 5 insertions(+), 3 deletions(-)
---
diff --git a/calendar/gui/e-cal-ops.c b/calendar/gui/e-cal-ops.c
index 610b1c7..cd8224e 100644
--- a/calendar/gui/e-cal-ops.c
+++ b/calendar/gui/e-cal-ops.c
@@ -1493,10 +1493,12 @@ new_component_data_free (gpointer ptr)
}
if (editor) {
- g_signal_connect (editor, "object-created",
- G_CALLBACK (cal_ops_emit_model_object_created), ncd->model);
+ if (ncd->model) {
+ g_signal_connect (editor, "object-created",
+ G_CALLBACK (cal_ops_emit_model_object_created), ncd->model);
- g_object_set_data_full (G_OBJECT (editor), "e-cal-ops-model", g_object_ref
(ncd->model), g_object_unref);
+ g_object_set_data_full (G_OBJECT (editor), "e-cal-ops-model",
g_object_ref (ncd->model), g_object_unref);
+ }
comp_editor_edit_comp (editor, ncd->comp);
gtk_window_present (GTK_WINDOW (editor));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]