aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorXan Lopez <xan@igalia.com>2012-08-02 18:04:28 +0800
committerXan Lopez <xan@igalia.com>2012-08-02 18:05:45 +0800
commit8a38c7a9ba0238092edc4e398ca7635bb4392c5f (patch)
tree8343ec4bd3938bf56aeda94e3c07c416e4087e2e /src
parent55b5a767c59f5a3010522dfcee89a773510ab8c6 (diff)
downloadgsoc2013-epiphany-8a38c7a9ba0238092edc4e398ca7635bb4392c5f.tar
gsoc2013-epiphany-8a38c7a9ba0238092edc4e398ca7635bb4392c5f.tar.gz
gsoc2013-epiphany-8a38c7a9ba0238092edc4e398ca7635bb4392c5f.tar.bz2
gsoc2013-epiphany-8a38c7a9ba0238092edc4e398ca7635bb4392c5f.tar.lz
gsoc2013-epiphany-8a38c7a9ba0238092edc4e398ca7635bb4392c5f.tar.xz
gsoc2013-epiphany-8a38c7a9ba0238092edc4e398ca7635bb4392c5f.tar.zst
gsoc2013-epiphany-8a38c7a9ba0238092edc4e398ca7635bb4392c5f.zip
window-commands: suggest the right name in 'Save As'
Use the info in the Content-Disposition header instead of the base name of the resource. https://bugzilla.gnome.org/show_bug.cgi?id=674291
Diffstat (limited to 'src')
-rw-r--r--src/window-commands.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/window-commands.c b/src/window-commands.c
index da8a2f960..5a4d2117e 100644
--- a/src/window-commands.c
+++ b/src/window-commands.c
@@ -307,9 +307,8 @@ get_suggested_filename (EphyWebView *view)
}
else
{
- SoupURI *soup_uri = soup_uri_new (webkit_web_resource_get_uri (web_resource));
- suggested_filename = g_path_get_basename (soup_uri->path);
- soup_uri_free (soup_uri);
+ WebKitNetworkResponse *response = webkit_web_frame_get_network_response (frame);
+ suggested_filename = g_strdup (webkit_network_response_get_suggested_filename (response));
}
return suggested_filename;