aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui
diff options
context:
space:
mode:
authorRodrigo Moya <rodrigo@novell.com>2004-06-24 01:17:07 +0800
committerRodrigo Moya <rodrigo@src.gnome.org>2004-06-24 01:17:07 +0800
commite659218812616a19532ccdabf1274d296cd0566c (patch)
tree5a28415f0cbc496bde9040e9dbce7e9fb05ba7d4 /calendar/gui
parentc2bd7a6754627f0af3d4fe2684a2576cb0f1b45d (diff)
downloadgsoc2013-evolution-e659218812616a19532ccdabf1274d296cd0566c.tar
gsoc2013-evolution-e659218812616a19532ccdabf1274d296cd0566c.tar.gz
gsoc2013-evolution-e659218812616a19532ccdabf1274d296cd0566c.tar.bz2
gsoc2013-evolution-e659218812616a19532ccdabf1274d296cd0566c.tar.lz
gsoc2013-evolution-e659218812616a19532ccdabf1274d296cd0566c.tar.xz
gsoc2013-evolution-e659218812616a19532ccdabf1274d296cd0566c.tar.zst
gsoc2013-evolution-e659218812616a19532ccdabf1274d296cd0566c.zip
fixed gtk-doc comments and made it enable/disable the dialog's OK button
2004-06-23 Rodrigo Moya <rodrigo@novell.com> * gui/dialogs/comp-editor.c (comp_editor_notify_client_changed): fixed gtk-doc comments and made it enable/disable the dialog's OK button depending on the selected source. svn path=/trunk/; revision=26479
Diffstat (limited to 'calendar/gui')
-rw-r--r--calendar/gui/dialogs/comp-editor.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/calendar/gui/dialogs/comp-editor.c b/calendar/gui/dialogs/comp-editor.c
index 0ddecc101e..f6148c8f4b 100644
--- a/calendar/gui/dialogs/comp-editor.c
+++ b/calendar/gui/dialogs/comp-editor.c
@@ -1256,17 +1256,17 @@ comp_editor_focus (CompEditor *editor)
}
/**
- * comp_editor_page_notify_client_changed:
- * @page: An editor page.
+ * comp_editor_notify_client_changed:
+ * @editor: A component editor.
*
- * Makes an editor page emit the "client_changed" signal. This is meant to be
- * used only by page implementations.
+ * Makes an editor emit the "client_changed" signal.
**/
void
comp_editor_notify_client_changed (CompEditor *editor, ECal *client)
{
GList *l;
CompEditorPrivate *priv;
+ gboolean read_only;
g_return_if_fail (editor != NULL);
g_return_if_fail (IS_COMP_EDITOR (editor));
@@ -1278,6 +1278,11 @@ comp_editor_notify_client_changed (CompEditor *editor, ECal *client)
comp_editor_set_e_cal (editor, client);
for (l = priv->pages; l != NULL; l = l->next)
comp_editor_page_notify_client_changed (COMP_EDITOR_PAGE (l->data), client);
+
+ if (!e_cal_is_read_only (client, &read_only, NULL))
+ read_only = TRUE;
+
+ gtk_dialog_set_response_sensitive (GTK_DIALOG (editor), GTK_RESPONSE_OK, !read_only);
}
static void