diff options
author | Xan Lopez <xan@igalia.com> | 2011-12-20 22:17:22 +0800 |
---|---|---|
committer | Xan Lopez <xan@igalia.com> | 2011-12-20 22:22:51 +0800 |
commit | 9ccc3fb7f66191a4131f9b150304b3c43a3ecdda (patch) | |
tree | fdde3ff918688fc24c4f7d0d7b30ebc1459d859f /src | |
parent | 463d7b377543077540bdcdc27524361dacf29e6d (diff) | |
download | gsoc2013-epiphany-9ccc3fb7f66191a4131f9b150304b3c43a3ecdda.tar gsoc2013-epiphany-9ccc3fb7f66191a4131f9b150304b3c43a3ecdda.tar.gz gsoc2013-epiphany-9ccc3fb7f66191a4131f9b150304b3c43a3ecdda.tar.bz2 gsoc2013-epiphany-9ccc3fb7f66191a4131f9b150304b3c43a3ecdda.tar.lz gsoc2013-epiphany-9ccc3fb7f66191a4131f9b150304b3c43a3ecdda.tar.xz gsoc2013-epiphany-9ccc3fb7f66191a4131f9b150304b3c43a3ecdda.tar.zst gsoc2013-epiphany-9ccc3fb7f66191a4131f9b150304b3c43a3ecdda.zip |
Remove NavigationUp
It's not used anymore.
Diffstat (limited to 'src')
-rw-r--r-- | src/Makefile.am | 2 | ||||
-rw-r--r-- | src/ephy-lockdown.c | 1 | ||||
-rw-r--r-- | src/ephy-navigation-up-action.c | 78 | ||||
-rw-r--r-- | src/ephy-navigation-up-action.h | 57 | ||||
-rw-r--r-- | src/ephy-window.c | 22 |
5 files changed, 0 insertions, 160 deletions
diff --git a/src/Makefile.am b/src/Makefile.am index d71fd4263..14705e0a5 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -28,7 +28,6 @@ NOINST_H_FILES = \ ephy-location-action.h \ ephy-navigation-action.h \ ephy-navigation-history-action.h \ - ephy-navigation-up-action.h \ ephy-password-info.h \ languages.h \ pdm-dialog.h \ @@ -67,7 +66,6 @@ libephymain_la_SOURCES = \ ephy-lockdown.c \ ephy-navigation-action.c \ ephy-navigation-history-action.c \ - ephy-navigation-up-action.c \ ephy-notebook.c \ ephy-password-info.c \ ephy-session.c \ diff --git a/src/ephy-lockdown.c b/src/ephy-lockdown.c index 801b08ad1..bd40f2a26 100644 --- a/src/ephy-lockdown.c +++ b/src/ephy-lockdown.c @@ -129,7 +129,6 @@ static const BindAction popup_actions[] = { static const BindAction special_toolbar_actions[] = { { EPHY_PREFS_LOCKDOWN_ARBITRARY_URL, "Location", "editable" }, - { EPHY_PREFS_LOCKDOWN_ARBITRARY_URL, "NavigationUp", "sensitive" }, { EPHY_PREFS_LOCKDOWN_HISTORY, "NavigationBack", "visible" }, { EPHY_PREFS_LOCKDOWN_HISTORY, "NavigationBack", "sensitive" }, diff --git a/src/ephy-navigation-up-action.c b/src/ephy-navigation-up-action.c deleted file mode 100644 index 9d3f78dd0..000000000 --- a/src/ephy-navigation-up-action.c +++ /dev/null @@ -1,78 +0,0 @@ -/* - * Copyright © 2003, 2004 Marco Pesenti Gritti - * Copyright © 2003, 2004 Christian Persch - * Copyright © 2008 Jan Alonzo - * Copyright © 2009 Igalia S.L. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - * - */ - -#include "config.h" -#include "ephy-navigation-up-action.h" - -#include "ephy-debug.h" -#include "ephy-embed-container.h" -#include "ephy-embed-shell.h" -#include "ephy-embed-utils.h" -#include "ephy-gui.h" -#include "ephy-history.h" -#include "ephy-link.h" -#include "ephy-shell.h" -#include "ephy-type-builtins.h" -#include "ephy-window.h" - -#include <gtk/gtk.h> -#include <webkit/webkit.h> - -#define URL_DATA_KEY "GoURL" - -static void ephy_navigation_up_action_init (EphyNavigationUpAction *action); -static void ephy_navigation_up_action_class_init (EphyNavigationUpActionClass *klass); - -G_DEFINE_TYPE (EphyNavigationUpAction, ephy_navigation_up_action, EPHY_TYPE_NAVIGATION_ACTION) - -static void -action_activate (GtkAction *action) -{ - EphyWindow *window; - EphyEmbed *embed; - GSList *up_list; - - window = _ephy_navigation_action_get_window (EPHY_NAVIGATION_ACTION (action)); - embed = ephy_embed_container_get_active_child (EPHY_EMBED_CONTAINER (window)); - g_return_if_fail (embed != NULL); - - up_list = ephy_web_view_get_go_up_list (ephy_embed_get_web_view (embed)); - ephy_link_open (EPHY_LINK (action), - up_list->data, - NULL, - ephy_gui_is_middle_click () ? EPHY_LINK_NEW_TAB : 0); - g_slist_foreach (up_list, (GFunc) g_free, NULL); - g_slist_free (up_list); -} - -static void -ephy_navigation_up_action_init (EphyNavigationUpAction *action) -{ -} - -static void -ephy_navigation_up_action_class_init (EphyNavigationUpActionClass *klass) -{ - GtkActionClass *action_class = GTK_ACTION_CLASS (klass); - - action_class->activate = action_activate; -} diff --git a/src/ephy-navigation-up-action.h b/src/ephy-navigation-up-action.h deleted file mode 100644 index 66c19190f..000000000 --- a/src/ephy-navigation-up-action.h +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright © 2003, 2004 Marco Pesenti Gritti - * Copyright © 2003, 2004 Christian Persch - * Copyright © 2010, Igalia S.L. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - * - */ - -#if !defined (__EPHY_EPIPHANY_H_INSIDE__) && !defined (EPIPHANY_COMPILATION) -#error "Only <epiphany/epiphany.h> can be included directly." -#endif - -#ifndef EPHY_NAVIGATION_UP_ACTION_H -#define EPHY_NAVIGATION_UP_ACTION_H - -#include "ephy-navigation-action.h" - -G_BEGIN_DECLS - -#define EPHY_TYPE_NAVIGATION_UP_ACTION (ephy_navigation_up_action_get_type ()) -#define EPHY_NAVIGATION_UP_ACTION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), EPHY_TYPE_NAVIGATION_UP_ACTION, EphyNavigationUpAction)) -#define EPHY_NAVIGATION_UP_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), EPHY_TYPE_NAVIGATION_UP_ACTION, EphyNavigationUpActionClass)) -#define EPHY_IS_NAVIGATION_UP_ACTION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), EPHY_TYPE_NAVIGATION_UP_ACTION)) -#define EPHY_IS_NAVIGATION_UP_ACTION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((obj), EPHY_TYPE_NAVIGATION_UP_ACTION)) -#define EPHY_NAVIGATION_UP_ACTION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), EPHY_TYPE_NAVIGATION_UP_ACTION, EphyNavigationUpActionClass)) - -typedef struct _EphyNavigationUpAction EphyNavigationUpAction; -typedef struct _EphyNavigationUpActionClass EphyNavigationUpActionClass; - -struct _EphyNavigationUpAction -{ - EphyNavigationAction parent; -}; - -struct _EphyNavigationUpActionClass -{ - EphyNavigationActionClass parent_class; -}; - -GType ephy_navigation_up_action_get_type (void); - -G_END_DECLS - -#endif diff --git a/src/ephy-window.c b/src/ephy-window.c index a3b2f04db..9aa3f3c1a 100644 --- a/src/ephy-window.c +++ b/src/ephy-window.c @@ -48,7 +48,6 @@ #include "ephy-location-entry.h" #include "ephy-navigation-action.h" #include "ephy-navigation-history-action.h" -#include "ephy-navigation-up-action.h" #include "ephy-notebook.h" #include "ephy-prefs.h" #include "ephy-settings.h" @@ -404,8 +403,6 @@ static const struct { GDK_KEY_KP_4, GDK_MOD1_MASK /*Alt*/, "NavigationBack", TRUE }, { GDK_KEY_KP_Right, GDK_MOD1_MASK /*Alt*/, "NavigationForward", TRUE }, { GDK_KEY_KP_6, GDK_MOD1_MASK /*Alt*/, "NavigationForward", TRUE }, - { GDK_KEY_KP_Up, GDK_MOD1_MASK /*Alt*/, "NavigationUp", TRUE }, - { GDK_KEY_KP_8, GDK_MOD1_MASK /*Alt*/, "NavigationUp", TRUE }, { GDK_KEY_KP_Page_Up, GDK_CONTROL_MASK, "TabsPrevious", FALSE }, { GDK_KEY_KP_9, GDK_CONTROL_MASK, "TabsPrevious", FALSE }, { GDK_KEY_KP_Page_Down, GDK_CONTROL_MASK, "TabsNext", FALSE }, @@ -1658,18 +1655,6 @@ setup_ui_manager (EphyWindow *window) "<alt>Right"); g_object_unref (action); - action = - g_object_new (EPHY_TYPE_NAVIGATION_UP_ACTION, - "name", "NavigationUp", - "label", _("_Up"), - "stock_id", GTK_STOCK_GO_UP, - "tooltip", _("Go up one level"), - "window", window, - NULL); - gtk_action_group_add_action_with_accel (action_group, action, - "<alt>Up"); - g_object_unref (action); - /* FIXME: I'm still waiting for the exact term to * user here from the docs team. */ @@ -1856,8 +1841,6 @@ _ephy_window_set_navigation_actions (EphyWindow *window, ephy_action_change_sensitivity_flags (action, SENS_FLAG, !back); action = gtk_action_group_get_action (priv->toolbar_action_group, "NavigationForward"); ephy_action_change_sensitivity_flags (action, SENS_FLAG, !forward); - action = gtk_action_group_get_action (priv->toolbar_action_group, "NavigationUp"); - ephy_action_change_sensitivity_flags (action, SENS_FLAG, !up); } static void @@ -3776,11 +3759,6 @@ setup_toolbar (EphyWindow *window) G_CALLBACK (ephy_link_open), window); action = gtk_action_group_get_action (priv->toolbar_action_group, - "NavigationUp"); - g_signal_connect_swapped (action, "open-link", - G_CALLBACK (ephy_link_open), window); - - action = gtk_action_group_get_action (priv->toolbar_action_group, "Location"); g_signal_connect (action, "notify::address", G_CALLBACK (sync_user_input_cb), window); |