[geany/geany-plugins] a3c89b: Focus the file view when switching to sidebar using the keyboard

Jiří Techet git-noreply at xxxxx
Thu Apr 4 21:33:47 UTC 2013


Branch:      refs/heads/master
Author:      Jiří Techet <techet at gmail.com>
Committer:   Jiří Techet <techet at gmail.com>
Date:        Thu, 04 Apr 2013 21:33:47 UTC
Commit:      a3c89b94a75378f74295317771bfe5d172cfdac8
             https://github.com/geany/geany-plugins/commit/a3c89b94a75378f74295317771bfe5d172cfdac8

Log Message:
-----------
Focus the file view when switching to sidebar using the keyboard

Thanks to Giuseppe Corbelli.


Modified Paths:
--------------
    gproject/src/gproject-sidebar.c

Modified: gproject/src/gproject-sidebar.c
3 files changed, 3 insertions(+), 0 deletions(-)
===================================================================
@@ -689,6 +689,7 @@ void gprj_sidebar_init(void)
 	GtkTreeViewColumn *column;
 	GtkTreeSelection *sel;
 	PangoFontDescription *pfd;
+	GList *focus_chain = NULL;
 
 	s_file_view_vbox = gtk_vbox_new(FALSE, 0);
 
@@ -814,6 +815,8 @@ void gprj_sidebar_init(void)
 
 	/**** the rest ****/
 
+	focus_chain = g_list_prepend(focus_chain, s_file_view);
+	gtk_container_set_focus_chain(GTK_CONTAINER(s_file_view_vbox), focus_chain);
 	scrollwin = gtk_scrolled_window_new(NULL, NULL);
 	gtk_scrolled_window_set_policy(GTK_SCROLLED_WINDOW(scrollwin),
 				       GTK_POLICY_AUTOMATIC, GTK_POLICY_AUTOMATIC);



--------------
This E-Mail was brought to you by github_commit_mail.py (Source: https://github.com/geany/infrastructure).


More information about the Plugins-Commits mailing list