[epiphany/mcatanzaro/revert-pdf] Remove the PDF support
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany/mcatanzaro/revert-pdf] Remove the PDF support
- Date: Thu, 31 Jan 2019 00:25:46 +0000 (UTC)
commit 179955234a40c7863c2f072971311fedacc98f2f
Author: Michael Catanzaro <mcatanzaro igalia com>
Date: Wed Jan 30 18:00:34 2019 -0600
Remove the PDF support
Unfortunately it's not ready for 3.32, and we're reconsidering the
implementation details.
Fixes #659
embed/ephy-download.c | 18 ---
embed/ephy-download.h | 41 +++--
embed/ephy-embed-shell.c | 11 +-
embed/ephy-embed-utils.c | 25 ---
embed/ephy-embed-utils.h | 27 ++--
embed/ephy-embed.c | 89 ----------
embed/ephy-embed.h | 10 --
embed/ephy-evince-document-view.c | 332 --------------------------------------
embed/ephy-evince-document-view.h | 47 ------
embed/ephy-web-view.c | 13 +-
embed/meson.build | 3 -
flatpak/org.gnome.Epiphany.json | 25 ---
meson.build | 2 -
src/ephy-action-bar-end.c | 18 ---
src/ephy-main.c | 3 -
src/ephy-window.c | 8 +-
src/window-commands.c | 8 +-
17 files changed, 38 insertions(+), 642 deletions(-)
---
diff --git a/embed/ephy-download.c b/embed/ephy-download.c
index 10b010f6f..1dffe2271 100644
--- a/embed/ephy-download.c
+++ b/embed/ephy-download.c
@@ -25,7 +25,6 @@
#include "ephy-embed.h"
#include "ephy-embed-shell.h"
#include "ephy-embed-type-builtins.h"
-#include "ephy-evince-document-view.h"
#include "ephy-file-helpers.h"
#include "ephy-flatpak-utils.h"
#include "ephy-prefs.h"
@@ -44,7 +43,6 @@ struct _EphyDownload {
char *content_type;
gboolean show_notification;
- gboolean in_document_mode;
EphyDownloadActionType action;
guint32 start_time;
@@ -635,16 +633,6 @@ download_decide_destination_cb (WebKitDownload *wk_download,
const gchar *suggested_filename,
EphyDownload *download)
{
- if (download->in_document_mode) {
- g_autofree gchar *tmp_file = g_strdup_printf ("%s/%s", g_get_user_cache_dir (), suggested_filename);
- g_autofree gchar *file_uri = g_filename_to_uri (tmp_file, NULL, NULL);
-
- webkit_download_set_allow_overwrite (wk_download, TRUE);
- webkit_download_set_destination (wk_download, file_uri);
-
- return TRUE;
- }
-
if (webkit_download_get_destination (wk_download))
return TRUE;
@@ -827,9 +815,3 @@ ephy_download_disable_desktop_notification (EphyDownload *download)
download->show_notification = FALSE;
}
-
-void
-ephy_download_enable_evince_document_mode (EphyDownload *download)
-{
- download->in_document_mode = TRUE;
-}
diff --git a/embed/ephy-download.h b/embed/ephy-download.h
index fa6bc917f..d2435812f 100644
--- a/embed/ephy-download.h
+++ b/embed/ephy-download.h
@@ -36,33 +36,32 @@ typedef enum
EPHY_DOWNLOAD_ACTION_OPEN
} EphyDownloadActionType;
-EphyDownload *ephy_download_new (WebKitDownload *download);
-EphyDownload *ephy_download_new_for_uri (const char *uri);
+EphyDownload *ephy_download_new (WebKitDownload *download);
+EphyDownload *ephy_download_new_for_uri (const char *uri);
-void ephy_download_cancel (EphyDownload *download);
-gboolean ephy_download_is_active (EphyDownload *download);
-gboolean ephy_download_succeeded (EphyDownload *download);
-gboolean ephy_download_failed (EphyDownload *download,
- GError **error);
+void ephy_download_cancel (EphyDownload *download);
+gboolean ephy_download_is_active (EphyDownload *download);
+gboolean ephy_download_succeeded (EphyDownload *download);
+gboolean ephy_download_failed (EphyDownload *download,
+ GError **error);
-void ephy_download_set_destination_uri (EphyDownload *download,
- const char *destination);
+void ephy_download_set_destination_uri (EphyDownload *download,
+ const char *destination);
-WebKitDownload *ephy_download_get_webkit_download (EphyDownload *download);
+WebKitDownload *ephy_download_get_webkit_download (EphyDownload *download);
-const char *ephy_download_get_destination_uri (EphyDownload *download);
-const char *ephy_download_get_content_type (EphyDownload *download);
+const char *ephy_download_get_destination_uri (EphyDownload *download);
+const char *ephy_download_get_content_type (EphyDownload *download);
-guint32 ephy_download_get_start_time (EphyDownload *download);
+guint32 ephy_download_get_start_time (EphyDownload *download);
-EphyDownloadActionType ephy_download_get_action (EphyDownload *download);
-void ephy_download_set_action (EphyDownload *download,
- EphyDownloadActionType action);
-gboolean ephy_download_do_download_action (EphyDownload *download,
- EphyDownloadActionType action,
- guint32 user_time);
+EphyDownloadActionType ephy_download_get_action (EphyDownload *download);
+void ephy_download_set_action (EphyDownload *download,
+ EphyDownloadActionType action);
+gboolean ephy_download_do_download_action (EphyDownload *download,
+ EphyDownloadActionType action,
+ guint32 user_time);
void ephy_download_disable_desktop_notification
- (EphyDownload *download);
-void ephy_download_enable_evince_document_mode (EphyDownload *download);
+ (EphyDownload *download);
G_END_DECLS
diff --git a/embed/ephy-embed-shell.c b/embed/ephy-embed-shell.c
index 3ed224d0a..3a97c0193 100644
--- a/embed/ephy-embed-shell.c
+++ b/embed/ephy-embed-shell.c
@@ -1130,9 +1130,7 @@ download_started_cb (WebKitWebContext *web_context,
{
EphyEmbedShellPrivate *priv = ephy_embed_shell_get_instance_private (shell);
EphyDownload *ephy_download;
- EphyEmbed *embed;
gboolean ephy_download_set;
- WebKitWebView *web_view;
/* Is download locked down? */
if (g_settings_get_boolean (EPHY_SETTINGS_LOCKDOWN,
@@ -1151,14 +1149,7 @@ download_started_cb (WebKitWebContext *web_context,
return;
ephy_download = ephy_download_new (download);
-
- web_view = webkit_download_get_web_view (download);
- embed = EPHY_GET_EMBED_FROM_EPHY_WEB_VIEW (web_view);
- ephy_embed_download_started (embed, ephy_download);
-
- if (ephy_embed_get_mode (embed) != EPHY_EMBED_MODE_EVINCE_DOCUMENT)
- ephy_downloads_manager_add_download (priv->downloads_manager, ephy_download);
-
+ ephy_downloads_manager_add_download (priv->downloads_manager, ephy_download);
g_object_unref (ephy_download);
}
diff --git a/embed/ephy-embed-utils.c b/embed/ephy-embed-utils.c
index 97b61fcc7..be9389630 100644
--- a/embed/ephy-embed-utils.c
+++ b/embed/ephy-embed-utils.c
@@ -30,7 +30,6 @@
#include "ephy-string.h"
#include "ephy-view-source-handler.h"
-#include <evince-document.h>
#include <glib/gi18n.h>
#include <jsc/jsc.h>
#include <libsoup/soup.h>
@@ -416,27 +415,3 @@ ephy_embed_utils_shutdown (void)
g_clear_pointer (&non_search_regex, g_regex_unref);
g_clear_pointer (&domain_regex, g_regex_unref);
}
-
-gboolean
-ephy_embed_utils_mime_type_is_supported_evince_document (const char *mime_type)
-{
- GList *doc_types = ev_backends_manager_get_all_types_info ();
- GList *l;
- gboolean found = FALSE;
-
- for (l = doc_types; l != NULL && !found; l = l->next) {
- EvTypeInfo *info = (EvTypeInfo *)l->data;
- guint i;
-
- for (i = 0; info->mime_types[i] != NULL; ++i) {
- if (g_ascii_strcasecmp (mime_type, info->mime_types[i]) == 0) {
- found = TRUE;
- break;
- }
- }
- }
-
- g_list_free (doc_types);
-
- return found;
-}
diff --git a/embed/ephy-embed-utils.h b/embed/ephy-embed-utils.h
index 4bd0f6502..3f99b7d89 100644
--- a/embed/ephy-embed-utils.h
+++ b/embed/ephy-embed-utils.h
@@ -36,19 +36,18 @@ G_BEGIN_DECLS
#define EPHY_WEBKIT_BACK_FORWARD_LIMIT 100
-char* ephy_embed_utils_link_message_parse (const char *message);
-gboolean ephy_embed_utils_address_has_web_scheme (const char *address);
-gboolean ephy_embed_utils_address_is_existing_absolute_filename (const char *address);
-gboolean ephy_embed_utils_address_is_valid (const char *address);
-char* ephy_embed_utils_normalize_address (const char *address);
-char * ephy_embed_utils_autosearch_address (const char *search_key);
-char * ephy_embed_utils_normalize_or_autosearch_address (const char *address);
-gboolean ephy_embed_utils_url_is_empty (const char *location);
-gboolean ephy_embed_utils_is_no_show_address (const char *address);
-char *ephy_embed_utils_get_title_from_address (const char *address);
-gboolean ephy_embed_utils_urls_have_same_origin (const char *a_url,
- const char *b_url);
-void ephy_embed_utils_shutdown (void);
-gboolean ephy_embed_utils_mime_type_is_supported_evince_document (const char *mime_type);
+char* ephy_embed_utils_link_message_parse (const char *message);
+gboolean ephy_embed_utils_address_has_web_scheme (const char *address);
+gboolean ephy_embed_utils_address_is_existing_absolute_filename (const char *address);
+gboolean ephy_embed_utils_address_is_valid (const char *address);
+char* ephy_embed_utils_normalize_address (const char *address);
+char * ephy_embed_utils_autosearch_address (const char *search_key);
+char * ephy_embed_utils_normalize_or_autosearch_address (const char *address);
+gboolean ephy_embed_utils_url_is_empty (const char *location);
+gboolean ephy_embed_utils_is_no_show_address (const char *address);
+char *ephy_embed_utils_get_title_from_address (const char *address);
+gboolean ephy_embed_utils_urls_have_same_origin (const char *a_url,
+ const char *b_url);
+void ephy_embed_utils_shutdown (void);
G_END_DECLS
diff --git a/embed/ephy-embed.c b/embed/ephy-embed.c
index 7a1d5a66b..0cea1428b 100644
--- a/embed/ephy-embed.c
+++ b/embed/ephy-embed.c
@@ -29,7 +29,6 @@
#include "ephy-embed-prefs.h"
#include "ephy-embed-shell.h"
#include "ephy-embed-utils.h"
-#include "ephy-evince-document-view.h"
#include "ephy-find-toolbar.h"
#include "ephy-notification-container.h"
#include "ephy-prefs.h"
@@ -66,7 +65,6 @@ struct _EphyEmbed {
GtkWidget *floating_bar;
GtkWidget *progress;
GtkWidget *fullscreen_message_label;
- GtkWidget *document_view;
char *title;
WebKitURIRequest *delayed_request;
@@ -76,9 +74,6 @@ struct _EphyEmbed {
GSList *messages;
GSList *keys;
- EphyEmbedMode mode;
- char *saved_title;
-
guint seq_context_id;
guint seq_message_id;
@@ -392,7 +387,6 @@ ephy_embed_dispose (GObject *object)
embed->fullscreen_message_id = 0;
}
- g_clear_pointer (&embed->saved_title, g_free);
g_clear_object (&embed->delayed_request);
g_clear_pointer (&embed->delayed_state, webkit_web_view_session_state_unref);
@@ -1024,86 +1018,3 @@ ephy_embed_detach_notification_container (EphyEmbed *embed)
gtk_container_remove (GTK_CONTAINER (embed->overlay), g_object_ref (GTK_WIDGET (container)));
}
}
-
-void
-ephy_embed_set_mode (EphyEmbed *embed, EphyEmbedMode mode)
-{
- g_assert (EPHY_IS_EMBED (embed));
-
- if (embed->mode == mode)
- return;
-
- switch (mode) {
- case EPHY_EMBED_MODE_WEB_VIEW:
- if (embed->document_view != NULL) {
- gtk_widget_destroy (embed->document_view);
- embed->document_view = NULL;
- }
- gtk_widget_set_visible (GTK_WIDGET (embed->paned), TRUE);
-
- if (embed->saved_title) {
- ephy_embed_set_title (embed, embed->saved_title);
- g_clear_pointer (&embed->saved_title, g_free);
- }
- break;
- case EPHY_EMBED_MODE_EVINCE_DOCUMENT:
- gtk_widget_set_visible (GTK_WIDGET (embed->paned), FALSE);
- embed->document_view = ephy_evince_document_view_new ();
- ephy_evince_document_set_embed (EPHY_EVINCE_DOCUMENT_VIEW (embed->document_view), embed);
- gtk_box_pack_start (GTK_BOX (embed),
- embed->document_view,
- TRUE, TRUE, 0);
- gtk_widget_show_all (embed->document_view);
- break;
- }
-
- embed->mode = mode;
-}
-
-EphyEmbedMode
-ephy_embed_get_mode (EphyEmbed *embed)
-{
- return embed->mode;
-}
-
-static void
-document_download_failed_cb (WebKitDownload *download,
- GError *error,
- EphyEmbed *embed)
-{
- /* Error occured: Switch back to web view */
- ephy_embed_set_mode (embed, EPHY_EMBED_MODE_WEB_VIEW);
-}
-
-static void
-document_download_finished_cb (WebKitDownload *download,
- EphyEmbed *embed)
-{
- const char *document_uri = webkit_download_get_destination (download);
-
- if (!embed->document_view)
- return;
-
- ephy_evince_document_view_load_uri (EPHY_EVINCE_DOCUMENT_VIEW (embed->document_view),
- document_uri);
-
- embed->saved_title = g_strdup (embed->title);
- ephy_embed_set_title (embed, g_path_get_basename (document_uri));
-}
-
-gboolean
-ephy_embed_download_started (EphyEmbed *embed,
- EphyDownload *ephy_download)
-{
- WebKitDownload *download = ephy_download_get_webkit_download (ephy_download);
- gboolean ret = FALSE;
-
- if (embed->mode == EPHY_EMBED_MODE_EVINCE_DOCUMENT) {
- ephy_download_enable_evince_document_mode (ephy_download);
- g_signal_connect (download, "failed", G_CALLBACK (document_download_failed_cb), embed);
- g_signal_connect (download, "finished", G_CALLBACK (document_download_finished_cb), embed);
- ret = TRUE;
- }
-
- return ret;
-}
diff --git a/embed/ephy-embed.h b/embed/ephy-embed.h
index 1eeb39e83..919a6d366 100644
--- a/embed/ephy-embed.h
+++ b/embed/ephy-embed.h
@@ -37,11 +37,6 @@ typedef enum {
EPHY_EMBED_TOP_WIDGET_POLICY_DESTROY_ON_TRANSITION
} EphyEmbedTopWidgetPolicy;
-typedef enum {
- EPHY_EMBED_MODE_WEB_VIEW,
- EPHY_EMBED_MODE_EVINCE_DOCUMENT
-} EphyEmbedMode;
-
EphyWebView* ephy_embed_get_web_view (EphyEmbed *embed);
EphyFindToolbar* ephy_embed_get_find_toolbar (EphyEmbed *embed);
void ephy_embed_add_top_widget (EphyEmbed *embed,
@@ -59,10 +54,5 @@ gboolean ephy_embed_inspector_is_loaded (EphyEmbed *embed);
const char *ephy_embed_get_title (EphyEmbed *embed);
void ephy_embed_attach_notification_container (EphyEmbed *embed);
void ephy_embed_detach_notification_container (EphyEmbed *embed);
-void ephy_embed_set_mode (EphyEmbed *embed,
- EphyEmbedMode mode);
-EphyEmbedMode ephy_embed_get_mode (EphyEmbed *embed);
-gboolean ephy_embed_download_started (EphyEmbed *embed,
- EphyDownload *ephy_download);
G_END_DECLS
diff --git a/embed/ephy-web-view.c b/embed/ephy-web-view.c
index ae9b2a2dc..2155d482b 100644
--- a/embed/ephy-web-view.c
+++ b/embed/ephy-web-view.c
@@ -1053,10 +1053,9 @@ static gboolean
run_readability_js_if_needed (gpointer data)
{
EphyWebView *web_view = data;
- EphyEmbed *embed = EPHY_GET_EMBED_FROM_EPHY_WEB_VIEW (web_view);
- /* Internal pages and document mode should never receive reader mode. */
- if (!ephy_embed_utils_is_no_show_address (web_view->address) && ephy_embed_get_mode (embed) !=
EPHY_EMBED_MODE_EVINCE_DOCUMENT) {
+ /* Internal pages should never receive reader mode. */
+ if (!ephy_embed_utils_is_no_show_address (web_view->address)) {
webkit_web_view_run_javascript_from_gresource (WEBKIT_WEB_VIEW (web_view),
"/org/gnome/epiphany/readability.js",
NULL,
@@ -1431,12 +1430,6 @@ decide_policy_cb (WebKitWebView *web_view,
response = webkit_response_policy_decision_get_response (response_decision);
mime_type = webkit_uri_response_get_mime_type (response);
- if (ephy_embed_utils_mime_type_is_supported_evince_document (mime_type)) {
- EphyEmbed *embed = EPHY_GET_EMBED_FROM_EPHY_WEB_VIEW (web_view);
-
- ephy_embed_set_mode (embed, EPHY_EMBED_MODE_EVINCE_DOCUMENT);
- }
-
/* If WebKit can't handle the mime type start the download
process */
if (webkit_response_policy_decision_is_mime_type_supported (response_decision))
@@ -1892,7 +1885,6 @@ load_changed_cb (WebKitWebView *web_view,
gpointer user_data)
{
EphyWebView *view = EPHY_WEB_VIEW (web_view);
- EphyEmbed *embed = EPHY_GET_EMBED_FROM_EPHY_WEB_VIEW (web_view);
GObject *object = G_OBJECT (web_view);
g_object_freeze_notify (object);
@@ -1902,7 +1894,6 @@ load_changed_cb (WebKitWebView *web_view,
const char *loading_uri = NULL;
view->load_failed = FALSE;
- ephy_embed_set_mode (embed, EPHY_EMBED_MODE_WEB_VIEW);
if (view->snapshot_timeout_id) {
g_source_remove (view->snapshot_timeout_id);
diff --git a/embed/meson.build b/embed/meson.build
index fad2a2956..c3c11704f 100644
--- a/embed/meson.build
+++ b/embed/meson.build
@@ -22,7 +22,6 @@ libephyembed_sources = [
'ephy-embed-utils.c',
'ephy-encoding.c',
'ephy-encodings.c',
- 'ephy-evince-document-view.c',
'ephy-file-monitor.c',
'ephy-filters-manager.c',
'ephy-find-toolbar.c',
@@ -35,8 +34,6 @@ libephyembed_sources = [
libephyembed_deps = [
libdazzle_dep,
ephymisc_dep,
- evince_document_dep,
- evince_view_dep,
gio_dep,
glib_dep,
gtk_dep,
diff --git a/flatpak/org.gnome.Epiphany.json b/flatpak/org.gnome.Epiphany.json
index 0b4ed5ad2..6d00eadee 100644
--- a/flatpak/org.gnome.Epiphany.json
+++ b/flatpak/org.gnome.Epiphany.json
@@ -68,31 +68,6 @@
}
]
},
- {
- "name" : "evince",
- "buildsystem" : "meson",
- "config-opts" : [
- "-Dplatform=gnome",
- "-Dviewer=false",
- "-Dpreviewer=false",
- "-Dthumbnailer=false",
- "-Dnautilus=false",
- "-Dgtk_doc=false",
- "-Dintrospection=false",
- "-Ddbus=false",
- "-Dkeyring=disabled",
- "-Dgtk_unix_print=disabled",
- "-Dthumbnail_cache=disabled",
- "-Dgspell=disabled",
- "-Dsystemduserunitdir=no"
- ],
- "sources" : [
- {
- "type" : "git",
- "url" : "https://gitlab.gnome.org/GNOME/evince.git"
- }
- ]
- },
{
"name" : "epiphany",
"config-opts" : [
diff --git a/meson.build b/meson.build
index 956e6ad6b..12623a28b 100644
--- a/meson.build
+++ b/meson.build
@@ -85,8 +85,6 @@ nettle_requirement = '>= 3.4'
webkitgtk_requirement = '>= 2.21.92'
cairo_dep = dependency('cairo', version: '>= 1.2')
-evince_document_dep = dependency('evince-document-3.0')
-evince_view_dep = dependency('evince-view-3.0')
gcr_dep = dependency('gcr-3', version: '>= 3.5.5')
gdk_dep = dependency('gdk-3.0', version: gtk_requirement)
gdk_pixbuf_dep = dependency('gdk-pixbuf-2.0', version: '>= 2.36.5')
diff --git a/src/ephy-action-bar-end.c b/src/ephy-action-bar-end.c
index 9074392d0..d20f10b43 100644
--- a/src/ephy-action-bar-end.c
+++ b/src/ephy-action-bar-end.c
@@ -23,8 +23,6 @@
#include "ephy-downloads-popover.h"
#include "ephy-downloads-progress-icon.h"
-#include "ephy-embed.h"
-#include "ephy-embed-container.h"
#include "ephy-shell.h"
#include "ephy-window.h"
@@ -46,19 +44,6 @@ struct _EphyActionBarEnd {
G_DEFINE_TYPE (EphyActionBarEnd, ephy_action_bar_end, GTK_TYPE_BOX)
-static gboolean
-is_document_view_active (void)
-{
- EphyShell *shell = ephy_shell_get_default ();
- GtkWindow *window;
- EphyEmbed *embed;
-
- window = gtk_application_get_active_window (GTK_APPLICATION (shell));
- embed = ephy_embed_container_get_active_child (EPHY_EMBED_CONTAINER (window));
-
- return ephy_embed_get_mode (embed) == EPHY_EMBED_MODE_EVINCE_DOCUMENT;
-}
-
static void
remove_downloads_button_attention_style (EphyActionBarEnd *self)
{
@@ -101,9 +86,6 @@ download_added_cb (EphyDownloadsManager *manager,
GtkAllocation rect;
DzlBoxTheatric *theatric;
- if (is_document_view_active ())
- return;
-
if (!action_bar_end->downloads_popover) {
action_bar_end->downloads_popover = ephy_downloads_popover_new (action_bar_end->downloads_button);
gtk_menu_button_set_popover (GTK_MENU_BUTTON (action_bar_end->downloads_button),
diff --git a/src/ephy-main.c b/src/ephy-main.c
index 0796393c8..877952075 100644
--- a/src/ephy-main.c
+++ b/src/ephy-main.c
@@ -33,7 +33,6 @@
#include "ephy-web-app-utils.h"
#include <errno.h>
-#include <evince-document.h>
#include <glib/gi18n.h>
#include <glib-unix.h>
#include <gtk/gtk.h>
@@ -409,7 +408,6 @@ main (int argc,
}
hdy_init (&argc, &argv);
- ev_init ();
_ephy_shell_create_instance (mode);
@@ -435,7 +433,6 @@ main (int argc,
if (notify_is_initted ())
notify_uninit ();
- ev_shutdown ();
ephy_settings_shutdown ();
ephy_file_helpers_shutdown ();
xmlCleanupParser ();
diff --git a/src/ephy-window.c b/src/ephy-window.c
index d6d34c85c..c6065e4cf 100644
--- a/src/ephy-window.c
+++ b/src/ephy-window.c
@@ -2602,18 +2602,12 @@ static void
download_only_load_cb (EphyWebView *view,
EphyWindow *window)
{
- EphyEmbed *embed = EPHY_GET_EMBED_FROM_EPHY_WEB_VIEW (view);
-
- /* Do not close tab if evince document mode is active */
- if (ephy_embed_get_mode (embed) == EPHY_EMBED_MODE_EVINCE_DOCUMENT)
- return;
-
if (gtk_notebook_get_n_pages (window->notebook) == 1) {
ephy_web_view_load_homepage (view);
return;
}
- g_idle_add (delayed_remove_child, embed);
+ g_idle_add (delayed_remove_child, EPHY_GET_EMBED_FROM_EPHY_WEB_VIEW (view));
}
static void
diff --git a/src/window-commands.c b/src/window-commands.c
index 9e53f69e2..ba230af99 100644
--- a/src/window-commands.c
+++ b/src/window-commands.c
@@ -668,13 +668,7 @@ window_cmd_navigation (GSimpleAction *action,
web_view = EPHY_GET_WEBKIT_WEB_VIEW_FROM_EMBED (embed);
if (strstr (g_action_get_name (G_ACTION (action)), "back")) {
- gboolean in_document_mode = ephy_embed_get_mode (embed) == EPHY_EMBED_MODE_EVINCE_DOCUMENT;
-
- if (in_document_mode)
- ephy_embed_set_mode (embed, EPHY_EMBED_MODE_WEB_VIEW);
- else
- webkit_web_view_go_back (web_view);
-
+ webkit_web_view_go_back (web_view);
gtk_widget_grab_focus (GTK_WIDGET (embed));
} else {
webkit_web_view_go_forward (web_view);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]