[seahorse] Bug 596592 - Can't paste into filter field
- From: Adam Schreiber <sadam src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [seahorse] Bug 596592 - Can't paste into filter field
- Date: Sun, 4 Oct 2009 21:56:38 +0000 (UTC)
commit 432d298ed320ea0aaccd27e6d6200bfe345e8c2d
Author: Adam Schreiber <sadam gnome org>
Date: Sun Oct 4 17:55:00 2009 -0400
Bug 596592 - Can't paste into filter field
Check to see if the filter field has focus when pasting and if so
paste to it instead of trying to import text. When filter doesn't
have focus, importing is attempted.
src/seahorse-key-manager.c | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
---
diff --git a/src/seahorse-key-manager.c b/src/seahorse-key-manager.c
index bc72762..793f371 100644
--- a/src/seahorse-key-manager.c
+++ b/src/seahorse-key-manager.c
@@ -575,9 +575,13 @@ on_clipboard_received (GtkClipboard* board, const char* text, SeahorseKeyManager
g_return_if_fail (SEAHORSE_IS_KEY_MANAGER (self));
g_return_if_fail (GTK_IS_CLIPBOARD (board));
g_return_if_fail (text != NULL);
-
- if (text != NULL && g_utf8_strlen (text, -1) > 0)
- import_text (self, text);
+
+ g_assert(self->pv->filter_entry);
+ if (gtk_widget_is_focus (self->pv->filter_entry) == TRUE)
+ gtk_editable_paste_clipboard (GTK_EDITABLE (self->pv->filter_entry));
+ else
+ if (text != NULL && g_utf8_strlen (text, -1) > 0)
+ import_text (self, text);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]