aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2005-08-18 01:31:23 +0800
committerChristian Persch <chpe@src.gnome.org>2005-08-18 01:31:23 +0800
commit3200b1592abd9f4ff0a020b3048bf6abf2cfb437 (patch)
treec3279ebeecc5cfdb545926155bb0a658f62aa826 /src
parent9dc72322ce56b9e377a1d889ea5bd4453f69ea47 (diff)
downloadgsoc2013-epiphany-3200b1592abd9f4ff0a020b3048bf6abf2cfb437.tar
gsoc2013-epiphany-3200b1592abd9f4ff0a020b3048bf6abf2cfb437.tar.gz
gsoc2013-epiphany-3200b1592abd9f4ff0a020b3048bf6abf2cfb437.tar.bz2
gsoc2013-epiphany-3200b1592abd9f4ff0a020b3048bf6abf2cfb437.tar.lz
gsoc2013-epiphany-3200b1592abd9f4ff0a020b3048bf6abf2cfb437.tar.xz
gsoc2013-epiphany-3200b1592abd9f4ff0a020b3048bf6abf2cfb437.tar.zst
gsoc2013-epiphany-3200b1592abd9f4ff0a020b3048bf6abf2cfb437.zip
Add EPHY_EMBED_PERSIST_FROM_CACHE, and try harder to get a cache
2005-08-17 Christian Persch <chpe@cvs.gnome.org> * embed/ephy-embed-persist.h: * embed/mozilla/mozilla-embed-persist.cpp: Add EPHY_EMBED_PERSIST_FROM_CACHE, and try harder to get a cache descriptor for the source URL. * src/popup-commands.c: (save_property_url), (popup_cmd_set_image_as_background), (save_temp_source): Use EPHY_EMBED_PERSIST_FROM_CACHE to try to get the content from cache when saving background, images or links. Part of bug #168554.
Diffstat (limited to 'src')
-rw-r--r--src/popup-commands.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/popup-commands.c b/src/popup-commands.c
index a637241cd..bd76c3825 100644
--- a/src/popup-commands.c
+++ b/src/popup-commands.c
@@ -199,11 +199,11 @@ save_property_url (GtkAction *action,
persist = EPHY_EMBED_PERSIST
(ephy_embed_factory_new_object (EPHY_TYPE_EMBED_PERSIST));
- ephy_embed_persist_set_embed (persist, embed);
ephy_embed_persist_set_fc_title (persist, title);
ephy_embed_persist_set_fc_parent (persist, GTK_WINDOW (window));
ephy_embed_persist_set_flags
- (persist, ask_dest ? EPHY_EMBED_PERSIST_ASK_DESTINATION : 0);
+ (persist, EPHY_EMBED_PERSIST_FROM_CACHE |
+ (ask_dest ? EPHY_EMBED_PERSIST_ASK_DESTINATION : 0));
ephy_embed_persist_set_persist_key
(persist, CONF_STATE_SAVE_DIR);
ephy_embed_persist_set_source (persist, location);
@@ -309,9 +309,9 @@ popup_cmd_set_image_as_background (GtkAction *action,
base_converted = g_filename_from_utf8 (base, -1, NULL, NULL, NULL);
dest = g_build_filename (ephy_dot_dir (), base_converted, NULL);
- ephy_embed_persist_set_embed (persist, embed);
ephy_embed_persist_set_dest (persist, dest);
- ephy_embed_persist_set_flags (persist, EPHY_EMBED_PERSIST_NO_VIEW);
+ ephy_embed_persist_set_flags (persist, EPHY_EMBED_PERSIST_NO_VIEW |
+ EPHY_EMBED_PERSIST_FROM_CACHE);
ephy_embed_persist_set_source (persist, location);
g_signal_connect (persist, "completed",
@@ -421,7 +421,8 @@ save_temp_source (const char *address)
(ephy_embed_factory_new_object (EPHY_TYPE_EMBED_PERSIST));
ephy_embed_persist_set_source (persist, address);
- ephy_embed_persist_set_flags (persist, EPHY_EMBED_PERSIST_NO_VIEW);
+ ephy_embed_persist_set_flags (persist, EPHY_EMBED_PERSIST_FROM_CACHE |
+ EPHY_EMBED_PERSIST_NO_VIEW);
ephy_embed_persist_set_dest (persist, tmp);
g_signal_connect (persist, "completed",