? stickies.patch
Index: GNOME_StickyNotesApplet.xml
===================================================================
RCS file: /cvs/gnome/gnome-applets/stickynotes/GNOME_StickyNotesApplet.xml,v
retrieving revision 1.5
diff -u -r1.5 GNOME_StickyNotesApplet.xml
--- GNOME_StickyNotesApplet.xml	5 Jan 2005 16:13:53 -0000	1.5
+++ GNOME_StickyNotesApplet.xml	11 Jul 2005 20:58:50 -0000
@@ -1,6 +1,7 @@
 <Root>
     <popups>
 	<popup name="button3">
+	    <menuitem name="new_note" verb="new_note" _label="_New Note" pixtype="stock" pixname="gtk-new"/>
 	    <menuitem name="lock" verb="lock" _label="_Lock Notes" type="toggle" id="lock"/>
 	    <menuitem name="destroy_all" verb="destroy_all" _label="_Delete Notes" pixtype="stock" pixname="gtk-delete"/>
 	    <separator/>
Index: stickynotes.c
===================================================================
RCS file: /cvs/gnome/gnome-applets/stickynotes/stickynotes.c,v
retrieving revision 1.62
diff -u -r1.62 stickynotes.c
--- stickynotes.c	20 Mar 2005 10:40:43 -0000	1.62
+++ stickynotes.c	11 Jul 2005 20:58:51 -0000
@@ -21,15 +21,40 @@
 #include <libxml/parser.h>
 
 #include <gdk/gdkx.h>
+#include <X11/Xatom.h>
 #define WNCK_I_KNOW_THIS_IS_UNSTABLE 1
 #include <libwnck/libwnck.h>
-
 #include "stickynotes.h"
 #include "stickynotes_callbacks.h"
 #include "util.h"
+#include "stickynotes_applet.h"
 
 static void response_cb (GtkWidget *dialog, gint id, gpointer data);
 
+/* Based on a function found in wnck */
+static void
+set_icon_geometry  (GdkWindow *window,
+		    int        x,
+		    int        y,
+		    int        width,
+		    int        height)
+{
+	gulong data[4];
+	Display *dpy = gdk_x11_drawable_get_xdisplay (window);
+
+	data[0] = x;
+	data[1] = y;
+	data[2] = width;
+	data[3] = height;
+
+	XChangeProperty (dpy,
+			 GDK_WINDOW_XID (window),
+			 gdk_x11_get_xatom_by_name_for_display (gdk_drawable_get_display (window),
+								"_NET_WM_ICON_GEOMETRY"),
+			 XA_CARDINAL, 32, PropModeReplace,
+			 (guchar *)&data, 4);
+}
+
 /* Create a new (empty) Sticky Note */
 StickyNote *
 stickynote_new (GdkScreen *screen)
@@ -522,8 +547,7 @@
 				TRUE);
 		gtk_window_set_skip_pager_hint (GTK_WINDOW (note->w_window),
 				TRUE);
-		gtk_window_set_keep_above (GTK_WINDOW (note->w_window), TRUE);
-		gtk_widget_show (note->w_window);
+		gtk_window_present (GTK_WINDOW (note->w_window));
 		
 		if (note->x != -1 || note->y != -1)
 			gtk_window_move (GTK_WINDOW (note->w_window),
@@ -561,7 +585,11 @@
 	}
 	else {
 		/* Hide sticky note */
-		gtk_widget_hide(note->w_window);
+		int x, y, width, height;
+		stickynotes_applet_panel_icon_get_geometry (&x, &y, &width, &height);
+		set_icon_geometry (GTK_WIDGET (note->w_window)->window,
+				   x, y, width, height);
+		gtk_window_iconify(GTK_WINDOW (note->w_window));
 	}
 }
 
@@ -575,8 +603,7 @@
 	stickynotes->notes = g_list_append(stickynotes->notes, note);
 	stickynotes_applet_update_tooltips();
 	stickynotes_save();
-	stickynote_set_visible (note, gconf_client_get_bool (stickynotes->gconf,
-				GCONF_PATH "/settings/visible", NULL));
+	stickynote_set_visible (note, TRUE);
 }
 
 /* Remove a sticky note with confirmation, if needed */
@@ -652,18 +679,15 @@
 
 		xid = GDK_WINDOW_XID (note->w_window->window);
 		wnck_win = wnck_window_get (xid);
-		if (gconf_client_get_bool (stickynotes->gconf,
-			     		GCONF_PATH "/settings/visible", NULL))
-		{
-			if (!gconf_client_get_bool (stickynotes->gconf,
-					GCONF_PATH "/settings/sticky", NULL) &&
-				wnck_win)
-				note->workspace = 1 +
-					wnck_workspace_get_number (
-					wnck_window_get_workspace (wnck_win));
-			else
-				note->workspace = 0;
-		}
+
+		if (!gconf_client_get_bool (stickynotes->gconf,
+				GCONF_PATH "/settings/sticky", NULL) &&
+			wnck_win)
+			note->workspace = 1 +
+				wnck_workspace_get_number (
+				wnck_window_get_workspace (wnck_win));
+		else
+			note->workspace = 0;
 		
 		/* Retreive the title of the note */
 		title = gtk_label_get_text(GTK_LABEL(note->w_title));
@@ -902,15 +926,10 @@
 	{
 		StickyNote *note = tmp1->data;
 
-		stickynote_set_visible (note, gconf_client_get_bool (
-						stickynotes->gconf,
-						GCONF_PATH "/settings/visible",
-						NULL));
-
+		stickynote_set_visible (note, TRUE);
 		tmp1 = tmp1->next;
 	}
 
-
 	g_list_free (new_notes);
 	g_list_free (new_nodes);
 
Index: stickynotes.schemas.in
===================================================================
RCS file: /cvs/gnome/gnome-applets/stickynotes/stickynotes.schemas.in,v
retrieving revision 1.16
diff -u -r1.16 stickynotes.schemas.in
--- stickynotes.schemas.in	9 Jan 2005 15:42:42 -0000	1.16
+++ stickynotes.schemas.in	11 Jul 2005 20:58:51 -0000
@@ -74,18 +74,6 @@
 </schema>
 
 <schema>
-	<key>/schemas/apps/stickynotes_applet/settings/visible</key>
-	<applyto>/apps/stickynotes_applet/settings/visible</applyto>
-	<owner>stickynotes_applet</owner>
-	<type>bool</type>
-	<default>true</default>
-	<locale name="C">
-		<short>Sticky notes' visibility</short>
-		<long>Specifies whether the sticky notes are visible or not.</long>
-	</locale>
-</schema>
-
-<schema>
 	<key>/schemas/apps/stickynotes_applet/settings/locked</key>
 	<applyto>/apps/stickynotes_applet/settings/locked</applyto>
 	<owner>stickynotes_applet</owner>
Index: stickynotes_applet.c
===================================================================
RCS file: /cvs/gnome/gnome-applets/stickynotes/stickynotes_applet.c,v
retrieving revision 1.61
diff -u -r1.61 stickynotes_applet.c
--- stickynotes_applet.c	20 Mar 2005 10:40:43 -0000	1.61
+++ stickynotes_applet.c	11 Jul 2005 20:58:52 -0000
@@ -32,6 +32,7 @@
 /* Popup menu on the applet */
 static const BonoboUIVerb stickynotes_applet_menu_verbs[] = 
 {
+        BONOBO_UI_UNSAFE_VERB ("new_note", menu_new_note_cb),
         BONOBO_UI_UNSAFE_VERB ("destroy_all", menu_destroy_all_cb),
         BONOBO_UI_UNSAFE_VERB ("preferences", menu_preferences_cb),
         BONOBO_UI_UNSAFE_VERB ("help", menu_help_cb),
@@ -182,6 +183,7 @@
 	g_timeout_add (1000 * 60 * gconf_client_get_int(stickynotes->gconf,
 				GCONF_PATH "/settings/autosave_time", NULL),
 		      (GSourceFunc) applet_save_cb, NULL);
+	g_timeout_add (100, applet_check_click_on_desktop_cb, NULL);
 }
 
 /* Initialize Sticky Notes Icons */
@@ -356,7 +358,6 @@
 	applet->prelighted = FALSE;
 	applet->pressed = FALSE;
 
-	applet->popup_menu = NULL;
 	applet->menu_tip = NULL;
 	applet->menu_show = NULL;
 
@@ -386,7 +387,6 @@
 					      NULL);
 	}
 
-	bonobo_ui_component_add_listener(panel_applet_get_popup_component(panel_applet), "show", (BonoboUIListenerFn) menu_toggle_show_cb, applet);
 	bonobo_ui_component_add_listener(panel_applet_get_popup_component(panel_applet), "lock", (BonoboUIListenerFn) menu_toggle_lock_cb, applet);
 
 	/* Connect all signals for applet management */
@@ -558,10 +558,7 @@
 
 void stickynotes_applet_update_menus(void)
 {
-	gboolean visible = gconf_client_get_bool(stickynotes->gconf, GCONF_PATH "/settings/visible", NULL);
-	gboolean locked = gconf_client_get_bool(stickynotes->gconf, GCONF_PATH "/settings/locked", NULL);
-	
-	gboolean visible_writable = gconf_client_key_is_writable(stickynotes->gconf, GCONF_PATH "/settings/visible", NULL);
+	gboolean locked = gconf_client_get_bool(stickynotes->gconf, GCONF_PATH "/settings/locked", NULL);	
 	gboolean locked_writable = gconf_client_key_is_writable(stickynotes->gconf, GCONF_PATH "/settings/locked", NULL);
 	
 	gboolean inconsistent = FALSE;
@@ -578,12 +575,8 @@
 		StickyNotesApplet *applet = g_list_nth_data(stickynotes->applets, i);
 		BonoboUIComponent *popup = panel_applet_get_popup_component(PANEL_APPLET(applet->w_applet));
 		
-		bonobo_ui_component_set_prop(popup, "/commands/show", "state", visible ? "1" : "0", NULL);
 		bonobo_ui_component_set_prop(popup, "/commands/lock", "state", locked ? "1" : "0", NULL);
-
 		bonobo_ui_component_set_prop(popup, "/commands/lock", "inconsistent", inconsistent ? "1" : "0", NULL); /* FIXME : Doesn't work */
-
-		bonobo_ui_component_set_prop(popup, "/commands/show", "sensitive", visible_writable ? "1" : "0", NULL);
 		bonobo_ui_component_set_prop(popup, "/commands/lock", "sensitive", locked_writable ? "1" : "0", NULL);
 	}
 }
@@ -600,7 +593,7 @@
 	num = g_list_length (stickynotes->notes);
 	
 	no_notes = g_strdup_printf (ngettext ("%d note", "%d notes", num), num);
-	tooltip = g_strdup_printf ("%s\n%s", _("Sticky Notes"), no_notes);
+	tooltip = g_strdup_printf ("%s\n%s", _("Show sticky notes"), no_notes);
 
 	for (l = stickynotes->applets; l; l = l->next)
 	{
@@ -619,3 +612,23 @@
 	g_free (tooltip);
 	g_free (no_notes);
 }
+
+void
+stickynotes_applet_panel_icon_get_geometry (int *x, int *y, int *width, int *height)
+{
+	GtkWidget *widget;
+	GtkRequisition requisition;
+	StickyNotesApplet *applet;
+
+	applet = stickynotes->applets->data;
+
+	widget = GTK_WIDGET (applet->w_image);
+  
+	gtk_widget_size_request (widget, &requisition);
+  
+	gdk_window_get_origin (widget->window, x, y);
+  
+	*width = widget->allocation.x;
+	*height = widget->allocation.y;
+}
+
Index: stickynotes_applet.h
===================================================================
RCS file: /cvs/gnome/gnome-applets/stickynotes/stickynotes_applet.h,v
retrieving revision 1.28
diff -u -r1.28 stickynotes_applet.h
--- stickynotes_applet.h	20 Mar 2005 10:40:43 -0000	1.28
+++ stickynotes_applet.h	11 Jul 2005 20:58:52 -0000
@@ -90,7 +90,6 @@
 	gint panel_size;
 	PanelAppletOrient panel_orient;
 	
-	GtkWidget *popup_menu;			/* Popup Menu */
 	GtkWidget *menu_tip;
 	GtkWidget *menu_show;
 } StickyNotesApplet;
@@ -118,4 +117,6 @@
 
 void stickynotes_applet_do_default_action(GdkScreen *screen);
 
+void stickynotes_applet_panel_icon_get_geometry (int *x, int *y, int *width, int *height);
+
 #endif /* __STICKYNOTES_APPLET_H__ */
Index: stickynotes_applet_callbacks.c
===================================================================
RCS file: /cvs/gnome/gnome-applets/stickynotes/stickynotes_applet_callbacks.c,v
retrieving revision 1.62
diff -u -r1.62 stickynotes_applet_callbacks.c
--- stickynotes_applet_callbacks.c	20 Mar 2005 10:40:43 -0000	1.62
+++ stickynotes_applet_callbacks.c	11 Jul 2005 20:58:52 -0000
@@ -23,60 +23,31 @@
 
 #include <gdk/gdkkeysyms.h>
 #include <libgnome/gnome-help.h>
+#include <X11/Xatom.h>
+#include <gdk/gdkx.h>
 
-static void
-position_menu (GtkMenu *menu, gint *x, gint *y,
-	       gboolean *push_in, gpointer user_data)
+static Window get_desktop_window()
 {
-	GtkWidget *widget = GTK_WIDGET (user_data);
-	GdkScreen *screen;
-	gint twidth, theight, tx, ty;
-	GtkTextDirection direction;
-	GdkRectangle monitor;
-	gint monitor_num;
-	
-	g_return_if_fail (menu != NULL);
-	g_return_if_fail (x != NULL);
-	g_return_if_fail (y != NULL);
-	
-	if (push_in) *push_in = FALSE;
-	
-	direction = gtk_widget_get_direction (widget);
-	
-	twidth = GTK_WIDGET (menu)->requisition.width;
-	theight = GTK_WIDGET (menu)->requisition.height;
-	
-	screen = gtk_widget_get_screen (GTK_WIDGET (menu));
-	monitor_num = gdk_screen_get_monitor_at_window (screen, widget->window);
-	if (monitor_num < 0) monitor_num = 0;
-	gdk_screen_get_monitor_geometry (screen, monitor_num, &monitor);
-	
-	if (!gdk_window_get_origin (widget->window, &tx, &ty)) {
-	    g_warning ("Menu not on screen");
-	    return;
+	Window *desktop_window = NULL;
+	GdkWindow *root_window;
+	GdkAtom type_returned;
+	int format_returned;
+	int length_returned;
+
+	root_window = gdk_screen_get_root_window (
+				gdk_screen_get_default ());
+
+	if (!gdk_property_get (root_window,
+			       gdk_atom_intern ("NAUTILUS_DESKTOP_WINDOW_ID", FALSE),
+		               gdk_x11_xatom_to_atom (XA_WINDOW),
+			       0, 4, FALSE,
+			       &type_returned,
+			       &format_returned,
+			       &length_returned,
+			       (guchar**) &desktop_window)) {
+		g_warning ("not able to get desktop window id");
 	}
-	
-	tx += widget->allocation.x;
-	ty += widget->allocation.y;
-	
-	if (direction == GTK_TEXT_DIR_RTL)
-	    tx += widget->allocation.width - twidth;
-	
-	if ((ty + widget->allocation.height + theight) <=
-			monitor.y + monitor.height)
-	     ty += widget->allocation.height;
-	else if ((ty - theight) >= monitor.y)
-	    ty -= theight;
-	else if (monitor.y + monitor.height -
-			(ty + widget->allocation.height) > ty)
-		ty += widget->allocation.height;
-	else
-	    ty -= theight;
-	
-	*x = CLAMP (tx, monitor.x,
-			MAX (monitor.x, monitor.x + monitor.width - twidth));
-	*y = ty;
-	gtk_menu_set_monitor (menu, monitor_num);
+	return *desktop_window;
 }
 
 static void
@@ -98,63 +69,16 @@
 }
 
 static void
-popup_toggle_show_notes (StickyNotesApplet *applet, GtkWidget *item)
-{
-	gboolean visible;
-	
-	visible = gconf_client_get_bool (stickynotes->gconf,
-			GCONF_PATH "/settings/visible", NULL);
-	if (gconf_client_key_is_writable (stickynotes->gconf,
-				GCONF_PATH "/settings/visible", NULL))
-		gconf_client_set_bool (stickynotes->gconf,
-				GCONF_PATH "/settings/visible", !visible, NULL);
-}
-
-static void
-stickynote_applet_ensure_popup (StickyNotesApplet *applet)
+stickynote_show_notes (gboolean visible)
 {
-	GtkWidget *item;
-	GtkWidget *image;
-
-	if (applet->popup_menu)
-		return;
-
-	applet->popup_menu = gtk_menu_new ();
+	StickyNote *note;
+	GList *l;
 
-	/* menu item - no# notes */
-	item = gtk_menu_item_new_with_label ("???");
-	applet->menu_tip = item;
-	gtk_widget_set_sensitive (item, FALSE);
-	gtk_widget_show (item);
-	gtk_container_add (GTK_CONTAINER (applet->popup_menu), item);
-
-	/* separator */
-	item = gtk_separator_menu_item_new ();
-	gtk_widget_show (item);
-	gtk_container_add (GTK_CONTAINER (applet->popup_menu), item);
-	
-	/* menu item - New Note */
-	item = gtk_image_menu_item_new_with_mnemonic (_("_New Note"));
-	image = gtk_image_new_from_stock (GTK_STOCK_NEW, GTK_ICON_SIZE_MENU);
-	gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (item), image);
-	g_signal_connect_swapped (item, "activate",
-			G_CALLBACK (popup_add_note), applet);
-	gtk_widget_show (image);
-	gtk_widget_show (item);
-	gtk_container_add (GTK_CONTAINER (applet->popup_menu), item);
-
-	/* menu item - Show Notes */
-	item = gtk_check_menu_item_new_with_mnemonic (_("_Show Notes"));
-	applet->menu_show = item;
-	gtk_check_menu_item_set_active (GTK_CHECK_MENU_ITEM (item),
-			gconf_client_get_bool (stickynotes->gconf,
-				GCONF_PATH "/settings/visible", NULL));
-	g_signal_connect_swapped (item, "toggled",
-			G_CALLBACK (popup_toggle_show_notes), applet);
-	gtk_widget_show (item);
-	gtk_container_add (GTK_CONTAINER (applet->popup_menu), item);
-	
-	stickynotes_applet_update_tooltips ();
+	for (l = stickynotes->notes; l; l = l->next)
+	{
+		note = l->data;
+		stickynote_set_visible (note, visible);
+	}
 }
 
 /* Applet Callback : Mouse button press on the applet. */
@@ -163,23 +87,17 @@
 		  GdkEventButton    *event,
 		  StickyNotesApplet *applet)
 {
-	if (event->type == GDK_2BUTTON_PRESS) /* FIXME */
+	if (event->type == GDK_2BUTTON_PRESS)
 	{
 		popup_add_note (applet, NULL);
 		return TRUE;
 	}
 	else if (event->button == 1)
 	{
-		stickynote_applet_ensure_popup (applet);
-		if (applet->popup_menu)
-		{
-			gtk_menu_popup (GTK_MENU (applet->popup_menu),
-					NULL, NULL,
-					position_menu, applet->w_applet,
-					event->button, event->time);
-		}
+		stickynote_show_notes (TRUE);
 		return TRUE;
 	}
+
 	return FALSE;
 }
 
@@ -195,16 +113,10 @@
 		case GDK_space:
 		case GDK_KP_Enter:
 		case GDK_Return:
-			stickynote_applet_ensure_popup (applet);
-			if (applet->popup_menu) {
-				gtk_menu_popup (GTK_MENU (applet->popup_menu),
-						NULL, NULL,
-						position_menu, applet->w_applet,
-						0, event->time);
-			}
+			stickynote_show_notes (TRUE);
 			return TRUE;
 	}
-	return FALSE;
+ 	return FALSE;
 }
 
 /* Applet Callback : Cross (enter or leave) the applet. */
@@ -235,6 +147,28 @@
 	return TRUE;
 }
 
+/* Applet Callback : Click on the desktop background */
+gboolean applet_check_click_on_desktop_cb(gpointer data)
+{
+	static Window desktop_window = 0;
+	static Display *dpy;
+
+	if (desktop_window == 0) {
+		desktop_window = get_desktop_window ();
+		dpy = XOpenDisplay (NULL);
+		/* X does not let us monitor mouse clicks in two applications
+                 * so we look at the PropertyChange event which is also fired
+                 * at every click on the desktop */
+		XSelectInput(dpy, desktop_window, PropertyChangeMask);
+	}
+	XEvent event;
+
+	if (XCheckWindowEvent(dpy, desktop_window, PropertyChangeMask, &event) == True) {
+		stickynote_show_notes (FALSE);
+	}
+	return TRUE;
+}
+
 /* Applet Callback : Change the panel orientation. */
 void applet_change_orient_cb(PanelApplet *panel_applet, PanelAppletOrient orient, StickyNotesApplet *applet)
 {
@@ -349,6 +283,11 @@
 	applet->destroy_all_dialog = NULL;
 }
 
+/* Menu Callback : New Note */
+void menu_new_note_cb(BonoboUIComponent *uic, StickyNotesApplet *applet, const gchar *verbname)
+{
+	popup_add_note (applet, NULL);
+}
 /* Menu Callback : Destroy all sticky notes */
 void menu_destroy_all_cb(BonoboUIComponent *uic, StickyNotesApplet *applet, const gchar *verbname)
 {
@@ -376,13 +315,6 @@
 	gtk_widget_show_all (applet->destroy_all_dialog);
 }
 
-/* Menu Callback : Show/Hide sticky notes */
-void menu_toggle_show_cb(BonoboUIComponent *uic, const gchar *path, Bonobo_UIComponent_EventType type, const gchar *state, StickyNotesApplet *applet)
-{
-	if (gconf_client_key_is_writable(stickynotes->gconf, GCONF_PATH "/settings/visible", NULL))
-		gconf_client_set_bool(stickynotes->gconf, GCONF_PATH "/settings/visible", strcmp(state, "0") != 0, NULL);
-}
-
 /* Menu Callback: Lock/Unlock sticky notes */
 void menu_toggle_lock_cb(BonoboUIComponent *uic, const gchar *path, Bonobo_UIComponent_EventType type, const gchar *state, StickyNotesApplet *applet)
 {
@@ -566,17 +498,6 @@
 		stickynotes_save();
 	}
 
-	else if (!strcmp (entry->key, GCONF_PATH "/settings/visible"))
-	{
-		for (l = stickynotes->notes; l; l = l->next)
-		{
-			note = l->data;
-			stickynote_set_visible (note,
-					gconf_value_get_bool (entry->value));
-		}
-		stickynotes_save();
-	}
-
 	else if (!strcmp (entry->key,
 				GCONF_PATH "/settings/use_system_color") ||
 		 !strcmp (entry->key, GCONF_PATH "/defaults/color"))
Index: stickynotes_applet_callbacks.h
===================================================================
RCS file: /cvs/gnome/gnome-applets/stickynotes/stickynotes_applet_callbacks.h,v
retrieving revision 1.16
diff -u -r1.16 stickynotes_applet_callbacks.h
--- stickynotes_applet_callbacks.h	3 Jan 2005 11:11:31 -0000	1.16
+++ stickynotes_applet_callbacks.h	11 Jul 2005 20:58:52 -0000
@@ -28,6 +28,7 @@
 gboolean applet_cross_cb(GtkWidget *widget, GdkEventCrossing *event, StickyNotesApplet *applet);
 gboolean applet_focus_cb(GtkWidget *widget, GdkEventFocus *event, StickyNotesApplet *applet);
 gboolean applet_save_cb(StickyNotesApplet *applet);
+gboolean applet_check_click_on_desktop_cb (gpointer data);
 void applet_change_orient_cb(PanelApplet *panel_applet, PanelAppletOrient orient, StickyNotesApplet *applet);
 void applet_size_allocate_cb(GtkWidget *widget, GtkAllocation *allocation, StickyNotesApplet *applet);
 void applet_change_bg_cb (PanelApplet *panel_applet,
@@ -39,8 +40,8 @@
 
 /* Callbacks for sticky notes applet menu */
 void menu_create_cb(BonoboUIComponent *uic, StickyNotesApplet *applet, const gchar *verbname);
+void menu_new_note_cb(BonoboUIComponent *uic, StickyNotesApplet *applet, const gchar *verbname);
 void menu_destroy_all_cb(BonoboUIComponent *uic, StickyNotesApplet *applet, const gchar *verbname);
-void menu_toggle_show_cb(BonoboUIComponent *uic, const gchar *path, Bonobo_UIComponent_EventType type, const gchar *state, StickyNotesApplet *applet);
 void menu_toggle_lock_cb(BonoboUIComponent *uic, const gchar *path, Bonobo_UIComponent_EventType type, const gchar *state, StickyNotesApplet *applet);
 void menu_preferences_cb(BonoboUIComponent *uic, StickyNotesApplet *applet, const gchar *verbname);
 void menu_help_cb(BonoboUIComponent *uic, StickyNotesApplet *applet, const gchar *verbname);
