aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui/main.c
diff options
context:
space:
mode:
authorArturo Espinosa <unammx@src.gnome.org>1998-05-09 08:04:08 +0800
committerArturo Espinosa <unammx@src.gnome.org>1998-05-09 08:04:08 +0800
commita9b1af2b26c0be96173149078b4e98b2b1d3aac2 (patch)
tree457f1242ed55d2503a3e8cca55c35e597fa0bd2d /calendar/gui/main.c
parentca6dd05c600cfbaf6c9b16059b2377932463ea0d (diff)
downloadgsoc2013-evolution-a9b1af2b26c0be96173149078b4e98b2b1d3aac2.tar
gsoc2013-evolution-a9b1af2b26c0be96173149078b4e98b2b1d3aac2.tar.gz
gsoc2013-evolution-a9b1af2b26c0be96173149078b4e98b2b1d3aac2.tar.bz2
gsoc2013-evolution-a9b1af2b26c0be96173149078b4e98b2b1d3aac2.tar.lz
gsoc2013-evolution-a9b1af2b26c0be96173149078b4e98b2b1d3aac2.tar.xz
gsoc2013-evolution-a9b1af2b26c0be96173149078b4e98b2b1d3aac2.tar.zst
gsoc2013-evolution-a9b1af2b26c0be96173149078b4e98b2b1d3aac2.zip
1. Fix: `New Appointment' defaults to the current day. 2. Add `New
1. Fix: `New Appointment' defaults to the current day. 2. Add `New appointment today' entry. 3. Use the new freeze/thaw changes to avoid the extensive flicker. Miguel. svn path=/trunk/; revision=209
Diffstat (limited to 'calendar/gui/main.c')
-rw-r--r--calendar/gui/main.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/calendar/gui/main.c b/calendar/gui/main.c
index 64b58cb1fc..dec25e737c 100644
--- a/calendar/gui/main.c
+++ b/calendar/gui/main.c
@@ -141,7 +141,23 @@ static void
display_objedit (GtkWidget *widget, GnomeCalendar *gcal)
{
GtkWidget *ee;
+ iCalObject *ico;
+
+ /* Default to the day the user is looking at */
+ ico = ical_new ("", user_name, "");
+ ico->new = 1;
+ ico->dtstart = time_add_minutes (gcal->current_display, day_begin * 60);
+ ico->dtend = time_add_minutes (ico->dtstart, day_begin * 60 + 30 );
+
+ ee = event_editor_new (gcal, ico);
+ gtk_widget_show (ee);
+}
+static void
+display_objedit_today (GtkWidget *widget, GnomeCalendar *gcal)
+{
+ GtkWidget *ee;
+
ee = event_editor_new (gcal, NULL);
gtk_widget_show (ee);
}
@@ -330,6 +346,7 @@ static GnomeUIInfo gnome_cal_about_menu [] = {
static GnomeUIInfo gnome_cal_edit_menu [] = {
{ GNOME_APP_UI_ITEM, N_("New appointment..."), NULL, display_objedit },
+ { GNOME_APP_UI_ITEM, N_("New appointment for today..."), NULL, display_objedit_today },
GNOMEUIINFO_SEPARATOR,
{ GNOME_APP_UI_ITEM, N_("Properties..."), NULL, properties, NULL, NULL,
GNOME_APP_PIXMAP_STOCK, GNOME_STOCK_MENU_PROP },