aboutsummaryrefslogtreecommitdiffstats
path: root/shell/e-shell-content.c
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2009-12-18 01:17:21 +0800
committerMilan Crha <mcrha@redhat.com>2009-12-18 01:17:21 +0800
commitfe15c797a036820ac4b5e8cf232ad0a559fcd06b (patch)
tree52b9861302be476ee9671212233ea562d93634e3 /shell/e-shell-content.c
parent858c42577c240a3ae83feaa6f5bb7c696da8df43 (diff)
downloadgsoc2013-evolution-fe15c797a036820ac4b5e8cf232ad0a559fcd06b.tar
gsoc2013-evolution-fe15c797a036820ac4b5e8cf232ad0a559fcd06b.tar.gz
gsoc2013-evolution-fe15c797a036820ac4b5e8cf232ad0a559fcd06b.tar.bz2
gsoc2013-evolution-fe15c797a036820ac4b5e8cf232ad0a559fcd06b.tar.lz
gsoc2013-evolution-fe15c797a036820ac4b5e8cf232ad0a559fcd06b.tar.xz
gsoc2013-evolution-fe15c797a036820ac4b5e8cf232ad0a559fcd06b.tar.zst
gsoc2013-evolution-fe15c797a036820ac4b5e8cf232ad0a559fcd06b.zip
Bug #603184 - Various problems with search box in folders
Diffstat (limited to 'shell/e-shell-content.c')
-rw-r--r--shell/e-shell-content.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/shell/e-shell-content.c b/shell/e-shell-content.c
index 6ffa73fa0a..13f807e79b 100644
--- a/shell/e-shell-content.c
+++ b/shell/e-shell-content.c
@@ -127,7 +127,7 @@ shell_content_update_search_widgets (EShellContent *shell_content)
const GdkColor *color;
style = gtk_widget_get_style (widget);
- color = &style->base[GTK_STATE_SELECTED];
+ color = &style->light[GTK_STATE_SELECTED];
gtk_widget_modify_base (widget, GTK_STATE_NORMAL, color);
style = gtk_widget_get_style (widget);
@@ -172,11 +172,17 @@ shell_content_entry_activate_cb (EShellContent *shell_content,
EShellView *shell_view;
EShellWindow *shell_window;
GtkAction *action;
+ const gchar *text;
shell_view = e_shell_content_get_shell_view (shell_content);
shell_window = e_shell_view_get_shell_window (shell_view);
- action = E_SHELL_WINDOW_ACTION_SEARCH_QUICK (shell_window);
+ text = gtk_entry_get_text (entry);
+ if (text && *text)
+ action = E_SHELL_WINDOW_ACTION_SEARCH_QUICK (shell_window);
+ else
+ action = E_SHELL_WINDOW_ACTION_SEARCH_CLEAR (shell_window);
+
gtk_action_activate (action);
}
@@ -1664,6 +1670,7 @@ e_shell_content_restore_state (EShellContent *shell_content,
* the search action until the state is fully restored. */
action = E_SHELL_WINDOW_ACTION_SEARCH_QUICK (shell_window);
gtk_action_block_activate (action);
+ e_shell_view_block_execute_search (shell_view);
key = STATE_KEY_SEARCH_FILTER;
string = g_key_file_get_string (key_file, group_name, key, NULL);
@@ -1703,6 +1710,7 @@ e_shell_content_restore_state (EShellContent *shell_content,
action = E_SHELL_WINDOW_ACTION_SEARCH_QUICK (shell_window);
gtk_action_unblock_activate (action);
+ e_shell_view_unblock_execute_search (shell_view);
/* Now execute the search. */
e_shell_view_execute_search (shell_view);