Kaydet (Commit) e57535bb authored tarafından Nick Treleaven's avatar Nick Treleaven

Load keybindings keyfile after plugins have loaded at startup, so

their shortcuts are also loaded. Still to do: loading individual
plugin keybindings after startup.


git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/branches/plugin-keybindings@2321 ea778897-0a13-0410-b9d1-a72fbfd435f5
üst a51962e6
...@@ -11,6 +11,10 @@ ...@@ -11,6 +11,10 @@
Make keybindings_send_command() take guint parameters, not gint. Make keybindings_send_command() take guint parameters, not gint.
* src/plugindata.h: * src/plugindata.h:
Avoid including keybindings.h. Avoid including keybindings.h.
* src/keybindings.c, src/keybindings.h, src/main.c:
Load keybindings keyfile after plugins have loaded at startup, so
their shortcuts are also loaded. Still to do: loading individual
plugin keybindings after startup.
2008-03-07 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com> 2008-03-07 Nick Treleaven <nick(dot)treleaven(at)btinternet(dot)com>
......
...@@ -476,6 +476,11 @@ void keybindings_init(void) ...@@ -476,6 +476,11 @@ void keybindings_init(void)
keybinding_groups = g_ptr_array_sized_new(GEANY_KEYGROUP_COUNT); keybinding_groups = g_ptr_array_sized_new(GEANY_KEYGROUP_COUNT);
init_default_kb(); init_default_kb();
}
void keybindings_load_keyfile(void)
{
load_user_kb(); load_user_kb();
add_menu_accels(); add_menu_accels();
} }
......
...@@ -252,6 +252,8 @@ enum ...@@ -252,6 +252,8 @@ enum
void keybindings_init(void); void keybindings_init(void);
void keybindings_load_keyfile(void);
void keybindings_free(void); void keybindings_free(void);
void keybindings_set_item(KeyBindingGroup *group, gsize key_id, void keybindings_set_item(KeyBindingGroup *group, gsize key_id,
......
...@@ -853,6 +853,9 @@ gint main(gint argc, gchar **argv) ...@@ -853,6 +853,9 @@ gint main(gint argc, gchar **argv)
plugins_init(); plugins_init();
#endif #endif
/* load keybinding settings after plugins have added their groups */
keybindings_load_keyfile();
/* load any command line files or session files */ /* load any command line files or session files */
main_status.opening_session_files = TRUE; main_status.opening_session_files = TRUE;
if (! open_cl_files(argc, argv)) if (! open_cl_files(argc, argv))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment