Commit bba75580 authored by csaavedra@igalia.com's avatar csaavedra@igalia.com

[GTK] Add xdg.origin.url extended attribute to downloads

https://bugs.webkit.org/show_bug.cgi?id=126638

Reviewed by Carlos Garcia Campos.

This is proposed by fdo in
http://www.freedesktop.org/wiki/CommonExtendedAttributes/

Source/WebKit/gtk:

* webkit/webkitdownload.cpp:
(webkit_download_open_stream_for_uri):

Source/WebKit2:

* Shared/Downloads/soup/DownloadSoup.cpp:
(WebKit::DownloadClient::didReceiveResponse):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@161536 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 1de0b008
2014-01-08 Claudio Saavedra <csaavedra@igalia.com>
[GTK] Add xdg.origin.url extended attribute to downloads
https://bugs.webkit.org/show_bug.cgi?id=126638
Reviewed by Carlos Garcia Campos.
This is proposed by fdo in
http://www.freedesktop.org/wiki/CommonExtendedAttributes/
* webkit/webkitdownload.cpp:
(webkit_download_open_stream_for_uri):
2014-01-04 Carlos Garcia Campos <cgarcia@igalia.com>
[GTK] Move all GTK/GObject unit tests to Tools/TestWebKitAPI
......
......@@ -477,7 +477,9 @@ static gboolean webkit_download_open_stream_for_uri(WebKitDownload* download, co
}
GRefPtr<GFileInfo> info = adoptGRef(g_file_info_new());
g_file_info_set_attribute_string(info.get(), "metadata::download-uri", webkit_download_get_uri(download));
const char* uri_string = webkit_download_get_uri(download);
g_file_info_set_attribute_string(info.get(), "metadata::download-uri", uri_string);
g_file_info_set_attribute_string(info.get(), "xattr::xdg.origin.url", uri_string);
g_file_set_attributes_async(file.get(), info.get(), G_FILE_QUERY_INFO_NONE, G_PRIORITY_DEFAULT, 0, 0, 0);
return TRUE;
......
2014-01-08 Claudio Saavedra <csaavedra@igalia.com>
[GTK] Add xdg.origin.url extended attribute to downloads
https://bugs.webkit.org/show_bug.cgi?id=126638
Reviewed by Carlos Garcia Campos.
This is proposed by fdo in
http://www.freedesktop.org/wiki/CommonExtendedAttributes/
* Shared/Downloads/soup/DownloadSoup.cpp:
(WebKit::DownloadClient::didReceiveResponse):
2014-01-08 Simon Fraser <simon.fraser@apple.com>
Make WK2 build when ENABLE(ASYNC_SCROLLING) is not defined
......
......@@ -104,7 +104,9 @@ public:
}
GRefPtr<GFileInfo> info = adoptGRef(g_file_info_new());
g_file_info_set_attribute_string(info.get(), "metadata::download-uri", response.url().string().utf8().data());
const char* uri = response.url().string().utf8().data();
g_file_info_set_attribute_string(info.get(), "metadata::download-uri", uri);
g_file_info_set_attribute_string(info.get(), "xattr::xdg.origin.url", uri);
g_file_set_attributes_async(file.get(), info.get(), G_FILE_QUERY_INFO_NONE, G_PRIORITY_DEFAULT, 0, 0, 0);
m_download->didCreateDestination(destinationURI);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment