]> Dogcows Code - chaz/openbox/blobdiff - openbox/menu.h
cleanups for keyboard menu shotcuts. dont let & set a shortcut from stuff like menu...
[chaz/openbox] / openbox / menu.h
index bdc05266b95b32f4111ac2bc2354b016153d7c6e..2315351ab37c4796f84076896e729e230ae87335 100644 (file)
@@ -133,7 +133,10 @@ struct _ObMenuEntry
 void menu_startup(gboolean reconfig);
 void menu_shutdown(gboolean reconfig);
 
-ObMenu* menu_new(const gchar *name, const gchar *title, gpointer data);
+/*! @param allow_shortcut this should be false when the label is coming from
+           outside data like window or desktop titles */
+ObMenu* menu_new(const gchar *name, const gchar *title,
+                 gboolean allow_shortcut, gpointer data);
 void menu_free(ObMenu *menu);
 
 /* Repopulate a pipe-menu by running its command */
@@ -148,15 +151,18 @@ void menu_set_execute_func(ObMenu *menu, ObMenuExecuteFunc func);
 void menu_set_destroy_func(ObMenu *menu, ObMenuDestroyFunc func);
 
 /* functions for building menus */
+/*! @param allow_shortcut this should be false when the label is coming from
+           outside data like window or desktop titles */
 ObMenuEntry* menu_add_normal(ObMenu *menu, gint id, const gchar *label,
-                             GSList *actions);
+                             GSList *actions, gboolean allow_shortcut);
 ObMenuEntry* menu_add_submenu(ObMenu *menu, gint id, const gchar *submenu);
 ObMenuEntry* menu_add_separator(ObMenu *menu, gint id, const gchar *label);
 
 void menu_clear_entries(ObMenu *menu);
 void menu_entry_remove(ObMenuEntry *self);
 
-void menu_entry_set_label(ObMenuEntry *self, const gchar *label);
+void menu_entry_set_label(ObMenuEntry *self, const gchar *label,
+                          gboolean allow_shortcut);
 
 ObMenuEntry* menu_find_entry_id(ObMenu *self, gint id);
 
This page took 0.020897 seconds and 4 git commands to generate.