aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/dialogs
diff options
context:
space:
mode:
authorDan Vrátil <dvratil@redhat.com>2011-06-23 15:35:26 +0800
committerRodrigo Moya <rodrigo@gnome-db.org>2011-06-30 00:42:32 +0800
commitf811cdac0eb1f73edc33a3491b1f4ce5f9164de0 (patch)
treea3851dbf50777f715b5839cd5f3f282710db9c34 /calendar/gui/dialogs
parentd0b73e358e251aead60cf2ee435599be896f0506 (diff)
downloadgsoc2013-evolution-f811cdac0eb1f73edc33a3491b1f4ce5f9164de0.tar
gsoc2013-evolution-f811cdac0eb1f73edc33a3491b1f4ce5f9164de0.tar.gz
gsoc2013-evolution-f811cdac0eb1f73edc33a3491b1f4ce5f9164de0.tar.bz2
gsoc2013-evolution-f811cdac0eb1f73edc33a3491b1f4ce5f9164de0.tar.lz
gsoc2013-evolution-f811cdac0eb1f73edc33a3491b1f4ce5f9164de0.tar.xz
gsoc2013-evolution-f811cdac0eb1f73edc33a3491b1f4ce5f9164de0.tar.zst
gsoc2013-evolution-f811cdac0eb1f73edc33a3491b1f4ce5f9164de0.zip
Bug #646442 - [mail-to-task] Edit event details before adding to calendar
Diffstat (limited to 'calendar/gui/dialogs')
-rw-r--r--calendar/gui/dialogs/comp-editor.c16
-rw-r--r--calendar/gui/dialogs/comp-editor.h2
2 files changed, 18 insertions, 0 deletions
diff --git a/calendar/gui/dialogs/comp-editor.c b/calendar/gui/dialogs/comp-editor.c
index 21ac86e9c3..da7759523e 100644
--- a/calendar/gui/dialogs/comp-editor.c
+++ b/calendar/gui/dialogs/comp-editor.c
@@ -121,6 +121,8 @@ struct _CompEditorPrivate {
gboolean changed;
gboolean needs_send;
+ gboolean saved;
+
CalObjModType mod;
gboolean existing_org;
@@ -212,6 +214,7 @@ G_DEFINE_TYPE_WITH_CODE (
enum {
OBJECT_CREATED,
+ COMP_CLOSED,
LAST_SIGNAL
};
@@ -624,6 +627,7 @@ save_comp (CompEditor *editor)
}
priv->changed = FALSE;
+ priv->saved = TRUE;
}
g_free (orig_uid_copy);
@@ -1868,6 +1872,15 @@ comp_editor_class_init (CompEditorClass *class)
NULL, NULL,
g_cclosure_marshal_VOID__VOID,
G_TYPE_NONE, 0);
+
+ signals[COMP_CLOSED] = g_signal_new (
+ "comp_closed",
+ G_TYPE_FROM_CLASS (class),
+ G_SIGNAL_RUN_LAST,
+ G_STRUCT_OFFSET (CompEditorClass, comp_closed),
+ NULL, NULL,
+ g_cclosure_marshal_VOID__BOOLEAN,
+ G_TYPE_NONE, 1, G_TYPE_BOOLEAN);
}
static void
@@ -1920,6 +1933,7 @@ comp_editor_init (CompEditor *editor)
priv->user_org = FALSE;
priv->warned = FALSE;
priv->is_group_item = FALSE;
+ priv->saved = FALSE;
priv->ui_manager = e_ui_manager_new ();
e_ui_manager_set_express_mode (
@@ -2201,6 +2215,8 @@ close_dialog (CompEditor *editor)
{
CompEditorPrivate *priv = editor->priv;
+ g_signal_emit_by_name (editor, "comp_closed", priv->saved);
+
/* FIXME Unfortunately we do this here because otherwise corba
calls happen during destruction and we might get a change
notification back when we are in an inconsistent state */
diff --git a/calendar/gui/dialogs/comp-editor.h b/calendar/gui/dialogs/comp-editor.h
index 3f1ddbb673..aca5c8ef11 100644
--- a/calendar/gui/dialogs/comp-editor.h
+++ b/calendar/gui/dialogs/comp-editor.h
@@ -86,6 +86,8 @@ struct _CompEditorClass {
gboolean visible);
void (*show_type) (CompEditor *editor,
gboolean visible);
+ void (*comp_closed) (CompEditor *editor,
+ gboolean saved);
};
typedef enum {