diff options
author | JP Rosevear <jpr@ximian.com> | 2002-03-30 05:45:33 +0800 |
---|---|---|
committer | JP Rosevear <jpr@src.gnome.org> | 2002-03-30 05:45:33 +0800 |
commit | a3aae682ce9911e451faae370ed4e88b2d6f4a2a (patch) | |
tree | 2f1fdfd7de8ec1d25d2891ac9497b283f2d30410 /calendar/gui/dialogs/task-editor.c | |
parent | 5b8bbd736fce436933bbb1f6f02df36c1b86a5fc (diff) | |
download | gsoc2013-evolution-a3aae682ce9911e451faae370ed4e88b2d6f4a2a.tar gsoc2013-evolution-a3aae682ce9911e451faae370ed4e88b2d6f4a2a.tar.gz gsoc2013-evolution-a3aae682ce9911e451faae370ed4e88b2d6f4a2a.tar.bz2 gsoc2013-evolution-a3aae682ce9911e451faae370ed4e88b2d6f4a2a.tar.lz gsoc2013-evolution-a3aae682ce9911e451faae370ed4e88b2d6f4a2a.tar.xz gsoc2013-evolution-a3aae682ce9911e451faae370ed4e88b2d6f4a2a.tar.zst gsoc2013-evolution-a3aae682ce9911e451faae370ed4e88b2d6f4a2a.zip |
implement new pop up menu items for "Save as", "Print", "Assign Task",
2002-03-29 JP Rosevear <jpr@ximian.com>
* gui/e-calendar-table.c: implement new pop up menu items for
"Save as", "Print", "Assign Task", "Forward as iCalendar"
* gui/e-day-view.c: similarly, also "Publish Free/Busy
Information" and "New Meeting" and "New Task"
* gui/e-week-view.c: ditto
* gui/dialogs/task-editor.c (show_assignment): move the assignment
page stuff here
(task_editor_show_assignment): use it
(assign_task_cmd): ditto
* gui/dialogs/task-editor.h: new proto
* gui/dialogs/comp-editor.c (save_as_cmd): use new e-util file
selector function
svn path=/trunk/; revision=16287
Diffstat (limited to 'calendar/gui/dialogs/task-editor.c')
-rw-r--r-- | calendar/gui/dialogs/task-editor.c | 41 |
1 files changed, 29 insertions, 12 deletions
diff --git a/calendar/gui/dialogs/task-editor.c b/calendar/gui/dialogs/task-editor.c index c5c4d61826..1ede12fff3 100644 --- a/calendar/gui/dialogs/task-editor.c +++ b/calendar/gui/dialogs/task-editor.c @@ -42,7 +42,7 @@ struct _TaskEditorPrivate { EMeetingModel *model; - gboolean meeting_shown; + gboolean assignment_shown; gboolean existing_org; gboolean updating; }; @@ -134,7 +134,7 @@ set_menu_sens (TaskEditor *te) priv = te->priv; - sens = priv->meeting_shown; + sens = priv->assignment_shown; comp_editor_set_ui_prop (COMP_EDITOR (te), "/commands/ActionAssignTask", "sensitive", sens ? "0" : "1"); @@ -191,7 +191,7 @@ task_editor_init (TaskEditor *te) comp_editor_merge_ui (COMP_EDITOR (te), "evolution-task-editor.xml", verbs); - priv->meeting_shown = TRUE; + priv->assignment_shown = TRUE; priv->existing_org = FALSE; priv->updating = FALSE; @@ -217,11 +217,11 @@ task_editor_edit_comp (CompEditor *editor, CalComponent *comp) e_meeting_model_remove_all_attendees (priv->model); if (attendees == NULL) { comp_editor_remove_page (editor, COMP_EDITOR_PAGE (priv->meet_page)); - priv->meeting_shown = FALSE; + priv->assignment_shown = FALSE; } else { GSList *l; - if (!priv->meeting_shown) + if (!priv->assignment_shown) comp_editor_append_page (COMP_EDITOR (te), COMP_EDITOR_PAGE (priv->meet_page), _("Assignment")); @@ -233,12 +233,12 @@ task_editor_edit_comp (CompEditor *editor, CalComponent *comp) e_meeting_model_add_attendee (priv->model, ia); gtk_object_unref (GTK_OBJECT (ia)); } - priv->meeting_shown = TRUE; + priv->assignment_shown = TRUE; } cal_component_free_attendee_list (attendees); set_menu_sens (te); - comp_editor_set_needs_send (COMP_EDITOR (te), priv->meeting_shown); + comp_editor_set_needs_send (COMP_EDITOR (te), priv->assignment_shown); priv->updating = FALSE; @@ -312,27 +312,44 @@ task_editor_new (void) } static void -assign_task_cmd (GtkWidget *widget, gpointer data) +show_assignment (TaskEditor *te) { - TaskEditor *te = TASK_EDITOR (data); TaskEditorPrivate *priv; priv = te->priv; - if (!priv->meeting_shown) { + if (!priv->assignment_shown) { comp_editor_append_page (COMP_EDITOR (te), COMP_EDITOR_PAGE (priv->meet_page), _("Assignment")); - priv->meeting_shown = TRUE; + priv->assignment_shown = TRUE; set_menu_sens (te); - comp_editor_set_needs_send (COMP_EDITOR (te), priv->meeting_shown); + comp_editor_set_needs_send (COMP_EDITOR (te), priv->assignment_shown); + comp_editor_set_changed (COMP_EDITOR (te), TRUE); } comp_editor_show_page (COMP_EDITOR (te), COMP_EDITOR_PAGE (priv->meet_page)); } +void +task_editor_show_assignment (TaskEditor *te) +{ + g_return_if_fail (te != NULL); + g_return_if_fail (IS_TASK_EDITOR (te)); + + show_assignment (te); +} + +static void +assign_task_cmd (GtkWidget *widget, gpointer data) +{ + TaskEditor *te = TASK_EDITOR (data); + + show_assignment (te); +} + static void refresh_task_cmd (GtkWidget *widget, gpointer data) { |