aboutsummaryrefslogtreecommitdiffstats
path: root/widgets
diff options
context:
space:
mode:
authorSrinivasa Ragavan <sragavan@novell.com>2005-12-22 01:52:04 +0800
committerSrinivasa Ragavan <sragavan@src.gnome.org>2005-12-22 01:52:04 +0800
commit3de1a0bf0ef4a1db6664cb51bfc33eeba0e56c9e (patch)
treee9c83dd2e98379d7ea2a13879f13b97915d7395e /widgets
parent1b6b6de16e323ff153efa481b722df3dc150f289 (diff)
downloadgsoc2013-evolution-3de1a0bf0ef4a1db6664cb51bfc33eeba0e56c9e.tar
gsoc2013-evolution-3de1a0bf0ef4a1db6664cb51bfc33eeba0e56c9e.tar.gz
gsoc2013-evolution-3de1a0bf0ef4a1db6664cb51bfc33eeba0e56c9e.tar.bz2
gsoc2013-evolution-3de1a0bf0ef4a1db6664cb51bfc33eeba0e56c9e.tar.lz
gsoc2013-evolution-3de1a0bf0ef4a1db6664cb51bfc33eeba0e56c9e.tar.xz
gsoc2013-evolution-3de1a0bf0ef4a1db6664cb51bfc33eeba0e56c9e.tar.zst
gsoc2013-evolution-3de1a0bf0ef4a1db6664cb51bfc33eeba0e56c9e.zip
** Fixes bug #324590
2005-12-21 Srinivasa Ragavan <sragavan@novell.com> ** Fixes bug #324590 * e-search-bar.c: (search_now_verb_cb), (clear_verb_cb): Added code to clear search entry from menu. svn path=/trunk/; revision=30925
Diffstat (limited to 'widgets')
-rw-r--r--widgets/misc/ChangeLog7
-rw-r--r--widgets/misc/e-search-bar.c15
2 files changed, 22 insertions, 0 deletions
diff --git a/widgets/misc/ChangeLog b/widgets/misc/ChangeLog
index b22462e323..2f44eb6c3d 100644
--- a/widgets/misc/ChangeLog
+++ b/widgets/misc/ChangeLog
@@ -1,3 +1,10 @@
+2005-12-21 Srinivasa Ragavan <sragavan@novell.com>
+
+ ** Fixes bug #324590
+
+ * e-search-bar.c: (search_now_verb_cb), (clear_verb_cb): Added
+ code to clear search entry from menu.
+
2005-12-20 Johnny Jacob <johnnyjacob@gmail.com>
** See Bug #246233
diff --git a/widgets/misc/e-search-bar.c b/widgets/misc/e-search-bar.c
index 5f322fd25a..7945d90b92 100644
--- a/widgets/misc/e-search-bar.c
+++ b/widgets/misc/e-search-bar.c
@@ -200,8 +200,20 @@ search_now_verb_cb (BonoboUIComponent *ui_component,
const char *verb_name)
{
ESearchBar *esb;
+ GtkStyle *style = gtk_widget_get_default_style ();
+ const char *text;
esb = E_SEARCH_BAR (data);
+ text = gtk_entry_get_text (esb->entry);
+
+ if (text && *text) {
+ gtk_widget_modify_base (esb->entry, GTK_STATE_NORMAL, &(style->base[GTK_STATE_SELECTED]));
+ gtk_widget_modify_text (esb->entry, GTK_STATE_NORMAL, &(style->text[GTK_STATE_SELECTED]));
+ } else {
+ gtk_widget_modify_base (esb->entry, GTK_STATE_NORMAL, NULL);
+ gtk_widget_modify_text (esb->entry, GTK_STATE_NORMAL, NULL);
+ }
+
emit_search_activated (esb);
}
@@ -212,6 +224,9 @@ clear_verb_cb (BonoboUIComponent *ui_component,
{
ESearchBar *esb;
+ gtk_widget_modify_base (esb->entry, GTK_STATE_NORMAL, NULL);
+ gtk_widget_modify_text (esb->entry, GTK_STATE_NORMAL, NULL);
+
esb = E_SEARCH_BAR (data);
clear_search (esb);
}