From af850aee2ba02a59abe0f4e4292b7782a64ea975 Mon Sep 17 00:00:00 2001 From: Xan Lopez Date: Sat, 17 Nov 2007 21:10:59 +0000 Subject: Use go_back and go_forward methods for navigation. Instead of jumping to -1 and +1 in the history. Less code, and it even works in WebKit :) svn path=/trunk/; revision=7716 --- src/ephy-navigation-action.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/ephy-navigation-action.c b/src/ephy-navigation-action.c index 56ad8081a..7aea4520b 100644 --- a/src/ephy-navigation-action.c +++ b/src/ephy-navigation-action.c @@ -402,20 +402,17 @@ ephy_navigation_action_activate (GtkAction *gtk_action) EphyNavigationAction *action = EPHY_NAVIGATION_ACTION (gtk_action); EphyWindow *window = action->priv->window; EphyEmbed *embed; - int pos; embed = ephy_embed_container_get_active_child (EPHY_EMBED_CONTAINER (window)); g_return_if_fail (embed != NULL); - pos = ephy_embed_shistory_get_pos (embed); - if (action->priv->direction == EPHY_NAVIGATION_DIRECTION_BACK) { - activate_by_history_index (action, pos - 1); + ephy_embed_go_back (embed); } else if (action->priv->direction == EPHY_NAVIGATION_DIRECTION_FORWARD) { - activate_by_history_index (action, pos + 1); + ephy_embed_go_forward (embed); } else if (action->priv->direction == EPHY_NAVIGATION_DIRECTION_UP) { -- cgit v1.2.3