aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2006-04-11 04:00:17 +0800
committerChristian Persch <chpe@src.gnome.org>2006-04-11 04:00:17 +0800
commit811f46ca79796425fb283e622cc13fa1c9e1980a (patch)
tree4efa0d56f0865c0ed51d25478a07ff74e9490a4c
parentb88345e8ac844db6bbefecff212e5e4ca37905f7 (diff)
downloadgsoc2013-epiphany-811f46ca79796425fb283e622cc13fa1c9e1980a.tar
gsoc2013-epiphany-811f46ca79796425fb283e622cc13fa1c9e1980a.tar.gz
gsoc2013-epiphany-811f46ca79796425fb283e622cc13fa1c9e1980a.tar.bz2
gsoc2013-epiphany-811f46ca79796425fb283e622cc13fa1c9e1980a.tar.lz
gsoc2013-epiphany-811f46ca79796425fb283e622cc13fa1c9e1980a.tar.xz
gsoc2013-epiphany-811f46ca79796425fb283e622cc13fa1c9e1980a.tar.zst
gsoc2013-epiphany-811f46ca79796425fb283e622cc13fa1c9e1980a.zip
Don't set find next/prev insensitive since that's redundant with the
2006-04-10 Christian Persch <chpe@cvs.gnome.org> * src/ephy-find-toolbar.c: Don't set find next/prev insensitive since that's redundant with the status indication, and breaks find while the document is loading.
-rw-r--r--ChangeLog7
-rw-r--r--src/ephy-find-toolbar.c34
2 files changed, 9 insertions, 32 deletions
diff --git a/ChangeLog b/ChangeLog
index 09353d0b7..958632328 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
2006-04-10 Christian Persch <chpe@cvs.gnome.org>
+ * src/ephy-find-toolbar.c:
+
+ Don't set find next/prev insensitive since that's redundant with
+ the status indication, and breaks find while the document is loading.
+
+2006-04-10 Christian Persch <chpe@cvs.gnome.org>
+
* embed/mozilla/mozilla-embed.cpp:
Emit document-change event on fastback restore. Fixes bug #312785.
diff --git a/src/ephy-find-toolbar.c b/src/ephy-find-toolbar.c
index 7841db4dc..32bad37ef 100644
--- a/src/ephy-find-toolbar.c
+++ b/src/ephy-find-toolbar.c
@@ -102,17 +102,6 @@ get_find (EphyFindToolbar *toolbar)
}
static void
-set_controls (EphyFindToolbar *toolbar,
- gboolean can_find_next,
- gboolean can_find_prev)
-{
- EphyFindToolbarPrivate *priv = toolbar->priv;
-
- gtk_widget_set_sensitive (GTK_WIDGET (priv->next), can_find_next);
- gtk_widget_set_sensitive (GTK_WIDGET (priv->prev), can_find_prev);
-}
-
-static void
set_status (EphyFindToolbar *toolbar,
EphyEmbedFindResult result)
{
@@ -151,14 +140,6 @@ clear_status (EphyFindToolbar *toolbar)
priv->links_only ? _("Find links:") : _("Find:"));
}
-static void
-tab_content_changed_cb (EphyEmbed *embed,
- const char *uri,
- EphyFindToolbar *toolbar)
-{
- set_controls (toolbar, TRUE, TRUE);
-}
-
#ifdef HAVE_TYPEAHEADFIND
/* Code adapted from gtktreeview.c:gtk_tree_view_key_press() and
@@ -219,7 +200,7 @@ entry_changed_cb (GtkEntry *entry,
#ifdef HAVE_TYPEAHEADFIND
EphyEmbedFindResult result;
#endif
- gboolean found = TRUE, case_sensitive;
+ gboolean case_sensitive;
text = gtk_entry_get_text (GTK_ENTRY (priv->entry));
@@ -234,10 +215,8 @@ entry_changed_cb (GtkEntry *entry,
#ifdef HAVE_TYPEAHEADFIND
result = ephy_embed_find_find (get_find (toolbar), text, priv->links_only);
- found = result != EPHY_EMBED_FIND_NOTFOUND;
set_status (toolbar, result);
#endif
- set_controls (toolbar, found, found);
}
static gboolean
@@ -600,12 +579,8 @@ ephy_find_toolbar_set_embed (EphyFindToolbar *toolbar,
priv->embed = embed;
if (embed != NULL)
{
- set_controls (toolbar, TRUE, TRUE);
clear_status (toolbar);
- g_signal_connect_object (embed, "ge-content-change",
- G_CALLBACK (tab_content_changed_cb),
- toolbar, G_CONNECT_AFTER);
#ifdef HAVE_TYPEAHEADFIND
g_signal_connect_object (embed, "ge-search-key-press",
G_CALLBACK (tab_search_key_press_cb),
@@ -625,12 +600,9 @@ void
ephy_find_toolbar_find_next (EphyFindToolbar *toolbar)
{
EphyEmbedFindResult result;
- gboolean found;
result = ephy_embed_find_find_again (get_find (toolbar), TRUE);
- found = result != EPHY_EMBED_FIND_NOTFOUND;
- set_controls (toolbar, found, found);
set_status (toolbar, result);
}
@@ -638,11 +610,9 @@ void
ephy_find_toolbar_find_previous (EphyFindToolbar *toolbar)
{
EphyEmbedFindResult result;
- gboolean found;
result = ephy_embed_find_find_again (get_find (toolbar), FALSE);
- found = result != EPHY_EMBED_FIND_NOTFOUND;
- set_controls (toolbar, found, found);
+
set_status (toolbar, result);
}