[gnome-builder] devhelp: focus search when grabbing workspace focus.
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] devhelp: focus search when grabbing workspace focus.
- Date: Thu, 11 Sep 2014 23:49:39 +0000 (UTC)
commit de3342c64769ba11fce9df3b4be649ea958262a4
Author: Christian Hergert <christian hergert me>
Date: Thu Sep 11 16:49:34 2014 -0700
devhelp: focus search when grabbing workspace focus.
src/devhelp/gb-devhelp-workspace.c | 11 +++++++++++
1 files changed, 11 insertions(+), 0 deletions(-)
---
diff --git a/src/devhelp/gb-devhelp-workspace.c b/src/devhelp/gb-devhelp-workspace.c
index 194103e..5d6c893 100644
--- a/src/devhelp/gb-devhelp-workspace.c
+++ b/src/devhelp/gb-devhelp-workspace.c
@@ -178,6 +178,14 @@ gb_devhelp_workspace_get_actions (GbWorkspace *workspace)
}
static void
+gb_devhelp_workspace_grab_focus (GtkWidget *widget)
+{
+ g_assert (GB_IS_DEVHELP_WORKSPACE (widget));
+
+ dh_sidebar_set_search_focus (GB_DEVHELP_WORKSPACE (widget)->priv->sidebar);
+}
+
+static void
gb_devhelp_workspace_finalize (GObject *object)
{
GbDevhelpWorkspacePrivate *priv;
@@ -194,11 +202,14 @@ static void
gb_devhelp_workspace_class_init (GbDevhelpWorkspaceClass *klass)
{
GObjectClass *object_class = G_OBJECT_CLASS (klass);
+ GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);
GbWorkspaceClass *workspace_class = GB_WORKSPACE_CLASS (klass);
object_class->constructed = gb_devhelp_workspace_constructed;
object_class->finalize = gb_devhelp_workspace_finalize;
+ widget_class->grab_focus = gb_devhelp_workspace_grab_focus;
+
workspace_class->get_actions = gb_devhelp_workspace_get_actions;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]