aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/dialogs/task-details-page.c
diff options
context:
space:
mode:
authorJP Rosevear <jpr@novell.com>2004-06-23 06:35:41 +0800
committerJP Rosevear <jpr@src.gnome.org>2004-06-23 06:35:41 +0800
commit2e266d5ae53296ce9b647c2318b42b2d9111a7b1 (patch)
treeae3635b63e45a7d0d4ef9e2c46ee0d860da27601 /calendar/gui/dialogs/task-details-page.c
parent433db9d759e49c0200d9b27553add4afcddc100d (diff)
downloadgsoc2013-evolution-2e266d5ae53296ce9b647c2318b42b2d9111a7b1.tar.gz
gsoc2013-evolution-2e266d5ae53296ce9b647c2318b42b2d9111a7b1.tar.zst
gsoc2013-evolution-2e266d5ae53296ce9b647c2318b42b2d9111a7b1.zip
HIGify and newer design; alarm page is gone, Cancel/OK buttons for the
2004-06-22 JP Rosevear <jpr@novell.com> * gui/dialogs/Makefile.am, gui/dialogs/alarm-dialog.c, gui/dialogs/alarm-dialog.glade, gui/dialogs/alarm-dialog.h, gui/dialogs/alarm-list-dialog.c, gui/dialogs/alarm-list-dialog.glade, gui/dialogs/alarm-list-dialog.h, gui/dialogs/alarm-options.c, gui/dialogs/alarm-options.h, gui/dialogs/alarm-page.c, gui/dialogs/alarm-page.glade, gui/dialogs/alarm-page.h, gui/dialogs/comp-editor.c, gui/dialogs/comp-editor.h, gui/dialogs/event-editor.c, gui/dialogs/event-page.c, gui/dialogs/event-page.glade, gui/dialogs/meeting-page.c, gui/dialogs/meeting-page.glade, gui/dialogs/recurrence-page.c, gui/dialogs/recurrence-page.glade, gui/dialogs/task-details-page.c, gui/dialogs/task-details-page.glade, gui/dialogs/task-editor.c, gui/dialogs/task-page.c, gui/dialogs/task-page.glade: HIGify and newer design; alarm page is gone, Cancel/OK buttons for the dialog, no more menus; slightly improve read-only workings for entry areas svn path=/trunk/; revision=26463
Diffstat (limited to 'calendar/gui/dialogs/task-details-page.c')
-rw-r--r--calendar/gui/dialogs/task-details-page.c32
1 files changed, 31 insertions, 1 deletions
diff --git a/calendar/gui/dialogs/task-details-page.c b/calendar/gui/dialogs/task-details-page.c
index 6c8dcbba32..029ba07929 100644
--- a/calendar/gui/dialogs/task-details-page.c
+++ b/calendar/gui/dialogs/task-details-page.c
@@ -277,6 +277,25 @@ clear_widgets (TaskDetailsPage *tdpage)
e_dialog_editable_set (priv->url, NULL);
}
+static void
+sensitize_widgets (TaskDetailsPage *tdpage)
+{
+ gboolean read_only;
+ TaskDetailsPagePrivate *priv;
+
+ priv = tdpage->priv;
+
+ if (!e_cal_is_read_only (COMP_EDITOR_PAGE (tdpage)->client, &read_only, NULL))
+ read_only = TRUE;
+
+ gtk_widget_set_sensitive (priv->status, !read_only);
+ gtk_widget_set_sensitive (priv->priority, !read_only);
+ gtk_widget_set_sensitive (priv->percent_complete, !read_only);
+ gtk_widget_set_sensitive (priv->completed_date, !read_only);
+ gtk_widget_set_sensitive (priv->url_label, !read_only);
+ gtk_entry_set_editable (GTK_ENTRY (e_url_entry_get_entry (priv->url_entry)), !read_only);
+}
+
/* fill_widgets handler for the task page */
static gboolean
task_details_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
@@ -363,6 +382,8 @@ task_details_page_fill_widgets (CompEditorPage *page, ECalComponent *comp)
priv->updating = FALSE;
+ sensitize_widgets (tdpage);
+
return TRUE;
}
@@ -729,7 +750,13 @@ init_widgets (TaskDetailsPage *tdpage)
G_CALLBACK (field_changed_cb), tdpage);
}
-
+static void
+client_changed_cb (CompEditorPage *page, ECal *client, gpointer user_data)
+{
+ TaskDetailsPage *tdpage = TASK_DETAILS_PAGE (page);
+
+ sensitize_widgets (tdpage);
+}
/**
* task_details_page_construct:
@@ -763,6 +790,9 @@ task_details_page_construct (TaskDetailsPage *tdpage)
init_widgets (tdpage);
+ g_signal_connect_after (G_OBJECT (tdpage), "client_changed",
+ G_CALLBACK (client_changed_cb), NULL);
+
return tdpage;
}