aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui
diff options
context:
space:
mode:
authorRodrigo Moya <rodrigo@ximian.com>2003-10-29 02:45:49 +0800
committerRodrigo Moya <rodrigo@src.gnome.org>2003-10-29 02:45:49 +0800
commit6f42e1922604ce384de19f6fe71dc73b184892e1 (patch)
tree797fd004dc5eaa2dffeae3be8002f0b34c964c35 /calendar/gui
parentc6fb640109eadb091cb867ad6930811ce9c501e6 (diff)
downloadgsoc2013-evolution-6f42e1922604ce384de19f6fe71dc73b184892e1.tar
gsoc2013-evolution-6f42e1922604ce384de19f6fe71dc73b184892e1.tar.gz
gsoc2013-evolution-6f42e1922604ce384de19f6fe71dc73b184892e1.tar.bz2
gsoc2013-evolution-6f42e1922604ce384de19f6fe71dc73b184892e1.tar.lz
gsoc2013-evolution-6f42e1922604ce384de19f6fe71dc73b184892e1.tar.xz
gsoc2013-evolution-6f42e1922604ce384de19f6fe71dc73b184892e1.tar.zst
gsoc2013-evolution-6f42e1922604ce384de19f6fe71dc73b184892e1.zip
connect to "fill_popup_menu" on the ESourceSelector.
2003-10-28 Rodrigo Moya <rodrigo@ximian.com> * gui/calendar-component.c (impl_createControls): connect to "fill_popup_menu" on the ESourceSelector. (fill_popup_menu_callback): add popup menu items here. (add_popup_menu_item): new function to add items to the popup menu. (new_calendar_cb): callbacks for the popup menu items. svn path=/trunk/; revision=23108
Diffstat (limited to 'calendar/gui')
-rw-r--r--calendar/gui/calendar-component.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/calendar/gui/calendar-component.c b/calendar/gui/calendar-component.c
index 82332073ad..a64d0bc339 100644
--- a/calendar/gui/calendar-component.c
+++ b/calendar/gui/calendar-component.c
@@ -30,6 +30,7 @@
#include "calendar-commands.h"
#include "gnome-cal.h"
#include "migration.h"
+#include "dialogs/new-calendar.h"
#include "widgets/misc/e-source-selector.h"
@@ -146,9 +147,15 @@ add_popup_menu_item (GtkMenu *menu, const char *label, const char *pixmap,
}
static void
+new_calendar_cb (GtkWidget *widget, ESourceSelector *selector)
+{
+ new_calendar_dialog (GTK_WINDOW (gtk_widget_get_toplevel (widget)));
+}
+
+static void
fill_popup_menu_callback (ESourceSelector *selector, GtkMenu *menu, CalendarComponent *comp)
{
- add_popup_menu_item (menu, _("_New Calendar"), NULL, NULL, selector);
+ add_popup_menu_item (menu, _("_New Calendar"), NULL, G_CALLBACK (new_calendar_cb), selector);
}
static void