summaryrefslogtreecommitdiff
blob: c76602ea527166236c3840b4648c05b27c17287b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
From 90859ca39bb877b665bb99da73c47569dc6a55b0 Mon Sep 17 00:00:00 2001
From: Bastien Nocera <hadess@hadess.net>
Date: Wed, 09 Jun 2010 16:13:01 +0000
Subject: Make the last selected medium's widget grab focus

https://bugzilla.gnome.org/show_bug.cgi?id=615214
---
diff --git a/src/nautilus-sendto-command.c b/src/nautilus-sendto-command.c
index 674d774..dd21620 100644
--- a/src/nautilus-sendto-command.c
+++ b/src/nautilus-sendto-command.c
@@ -429,6 +429,7 @@ set_model_for_options_combobox (NS_ui *ui)
         GtkListStore *model;
 	GtkIconTheme *it;
 	GtkCellRenderer *renderer;
+	GtkWidget *widget;
 	GList *aux;
 	NstPlugin *p;
 	char *last_used = NULL;
@@ -484,6 +485,10 @@ set_model_for_options_combobox (NS_ui *ui)
 
 	gtk_combo_box_set_active (GTK_COMBO_BOX (ui->options_combobox), option);
 
+	/* Grab the focus for the most recently used widget */
+	widget = g_list_nth_data (ui->contact_widgets, option);
+	gtk_widget_grab_focus (widget);
+
 	return last_used_support_dirs;
 }
 
--
cgit v0.8.3.1