Changeset 107180 in webkit
- Timestamp:
- Feb 8, 2012 10:12:47 PM (12 years ago)
- Location:
- trunk/Source/WebKit2
- Files:
-
- 1 added
- 4 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit2/ChangeLog
r107176 r107180 1 2012-02-08 Keunsoon Lee <keunsoon.lee@samsung.com> 2 3 [WK2][EFL] creating dummy class derived from ResourceHandleClient for Efl download module. 4 https://bugs.webkit.org/show_bug.cgi?id=76171 5 6 Reviewed by Andreas Kling. 7 8 FileDownloaderEfl is a practical class to operate file download. 9 It communicates with Download class to start download 10 and to notify downloading states to user(e.g. client application). 11 Besides FileDownloaderEfl derives from ResourceHandleClient 12 and receives chunked data from ResourceHandle directly 13 or redirects data flow which is started from MainResourceLoader 14 by mean of exchanging ResourceHandle's existing client for FileDownloaderEfl. 15 16 This patch has only dummy functions to make easy to review. 17 Working patch will be uploaded on another bug thread. 18 19 * PlatformEfl.cmake: added new file to compile. 20 * WebProcess/Downloads/Download.h: added FileDownloaderEfl's instance as a form of OwnPtr<FileDownloaderEfl>. 21 (WebKit): 22 (Download): 23 * WebProcess/Downloads/efl/DownloadEfl.cpp: 24 (WebKit::Download::start): calling to FileDownloaderEfl::start() to start download for passing ResourceRequest. 25 * WebProcess/Downloads/efl/FileDownloaderEfl.cpp: Added. a practical class to operate file download. 26 (WebKit): 27 (WebKit::FileDownloaderEfl::create): create function, which returns PassOwnPtr<FileDownloaderEfl>. 28 (WebKit::FileDownloaderEfl::FileDownloaderEfl): constructor, which receives Download* as a parameter. 29 (WebKit::FileDownloaderEfl::~FileDownloaderEfl): deconstructor. 30 (WebKit::FileDownloaderEfl::start): a function to start downloading for passed ResourceRequest. 31 It does nothing for now, but shows how Download class can call FileDownloaderEfl's function. 32 (WebKit::FileDownloaderEfl::didReceiveResponse): virtual function for ResourceHandleClient. 33 It will receive response header information from ResourceHandle. 34 (WebKit::FileDownloaderEfl::didReceiveData): virtual function for ResourceHandleClient. 35 It will receive chunk data from ResourceHandle. 36 (WebKit::FileDownloaderEfl::didFinishLoading): virtual function for ResourceHandleClient. 37 It will be notified loading is finished from ResourceHandle. 38 (WebKit::FileDownloaderEfl::didFail): virtual function for ResourceHandleClient. 39 It will be notified loading is fail with ResourceError from ResourceHandle. 40 (WebKit::FileDownloaderEfl::shouldUseCredentialStorage): virtual function for ResourceHandleClient. 41 It returns whether to use credential storage or not. 42 (WebKit::FileDownloaderEfl::didReceiveAuthenticationChallenge): virtual function for ResourceHandleClient. 43 It will receive AuthenticationChallenge. 44 (WebKit::FileDownloaderEfl::didCancelAuthenticationChallenge): virtual function for ResourceHandleClient. 45 It will be notified AuthenticationChallenge is canceled. 46 (WebKit::FileDownloaderEfl::receivedCancellation): virtual function for ResourceHandleClient. 47 * WebProcess/Downloads/efl/FileDownloaderEfl.h: Added. 48 (WebCore): 49 (WebKit): 50 (FileDownloaderEfl): 51 1 52 2012-02-07 MORITA Hajime <morrita@google.com> 2 53 -
trunk/Source/WebKit2/PlatformEfl.cmake
r104122 r107180 46 46 47 47 WebProcess/Downloads/efl/DownloadEfl.cpp 48 WebProcess/Downloads/efl/FileDownloaderEfl.cpp 48 49 49 50 WebProcess/efl/WebProcessEfl.cpp … … 66 67 "${WEBKIT2_DIR}/Shared/efl" 67 68 "${WEBKIT2_DIR}/UIProcess/API/efl/" 69 "${WEBKIT2_DIR}/WebProcess/Downloads/efl" 68 70 "${WEBKIT2_DIR}/WebProcess/efl" 69 71 "${WEBKIT2_DIR}/WebProcess/WebCoreSupport/efl" -
trunk/Source/WebKit2/WebProcess/Downloads/Download.h
r101609 r107180 48 48 #endif 49 49 50 #if PLATFORM(EFL) 51 #include <FileDownloaderEfl.h> 52 #endif 53 50 54 namespace CoreIPC { 51 55 class DataReference; … … 68 72 #if PLATFORM(QT) 69 73 class QtFileDownloader; 74 #endif 75 76 #if PLATFORM(EFL) 77 class FileDownloaderEfl; 70 78 #endif 71 79 … … 147 155 RefPtr<WebCore::ResourceHandle> m_resourceHandle; 148 156 #endif 157 #if PLATFORM(EFL) 158 OwnPtr<FileDownloaderEfl> m_fileDownloader; 159 #endif 149 160 }; 150 161 -
trunk/Source/WebKit2/WebProcess/Downloads/efl/DownloadEfl.cpp
r104122 r107180 21 21 #include "Download.h" 22 22 23 #include "FileDownloaderEfl.h" 23 24 #include <WebCore/NotImplemented.h> 24 25 … … 29 30 void Download::start(WebPage* initiatingWebPage) 30 31 { 31 notImplemented(); 32 m_fileDownloader = FileDownloaderEfl::create(this); 33 m_fileDownloader->start(initiatingWebPage, m_request); 32 34 } 33 35 -
trunk/Source/WebKit2/WebProcess/Downloads/efl/FileDownloaderEfl.cpp
- Property svn:executable deleted
r107179 r107180 19 19 20 20 #include "config.h" 21 #include " Download.h"21 #include "FileDownloaderEfl.h" 22 22 23 23 #include <WebCore/NotImplemented.h> … … 27 27 namespace WebKit { 28 28 29 void Download::start(WebPage* initiatingWebPage) 29 PassOwnPtr<FileDownloaderEfl> FileDownloaderEfl::create(Download* download) 30 { 31 return adoptPtr(new FileDownloaderEfl(download)); 32 } 33 34 FileDownloaderEfl::FileDownloaderEfl(Download* download) 35 : m_download(download) 36 { 37 ASSERT(download); 38 } 39 40 FileDownloaderEfl::~FileDownloaderEfl() 41 { 42 } 43 44 void FileDownloaderEfl::start(WebPage*, ResourceRequest&) 30 45 { 31 46 notImplemented(); 32 47 } 33 48 34 void Download::startWithHandle(WebPage* initiatingPage, ResourceHandle* handle, const ResourceResponse& response)49 void FileDownloaderEfl::didReceiveResponse(ResourceHandle*, const ResourceResponse&) 35 50 { 36 51 notImplemented(); 37 52 } 38 53 39 void Download::cancel()54 void FileDownloaderEfl::didReceiveData(ResourceHandle*, const char*, int, int) 40 55 { 41 56 notImplemented(); 42 57 } 43 58 44 void Download::platformInvalidate()59 void FileDownloaderEfl::didFinishLoading(ResourceHandle*, double) 45 60 { 46 61 notImplemented(); 47 62 } 48 63 49 void Download::didDecideDestination(const String& destination, bool allowOverwrite)64 void FileDownloaderEfl::didFail(ResourceHandle*, const ResourceError&) 50 65 { 51 66 notImplemented(); 52 67 } 53 68 54 void Download::platformDidFinish() 69 bool FileDownloaderEfl::shouldUseCredentialStorage(ResourceHandle*) 70 { 71 return false; 72 } 73 74 void FileDownloaderEfl::didReceiveAuthenticationChallenge(ResourceHandle*, const AuthenticationChallenge&) 55 75 { 56 76 notImplemented(); 57 77 } 58 78 59 void Download::receivedCredential(const AuthenticationChallenge& authenticationChallenge, const Credential& credential)79 void FileDownloaderEfl::didCancelAuthenticationChallenge(ResourceHandle*, const AuthenticationChallenge&) 60 80 { 61 81 notImplemented(); 62 82 } 63 83 64 void Download::receivedRequestToContinueWithoutCredential(const AuthenticationChallenge& authenticationChallenge) 65 { 66 notImplemented(); 67 } 68 69 void Download::receivedCancellation(const AuthenticationChallenge& authenticationChallenge) 70 { 71 notImplemented(); 72 } 73 74 void Download::useCredential(const WebCore::AuthenticationChallenge& authenticationChallenge, const WebCore::Credential& credential) 75 { 76 notImplemented(); 77 } 78 79 void Download::continueWithoutCredential(const WebCore::AuthenticationChallenge& authenticationChallenge) 80 { 81 notImplemented(); 82 } 83 84 void Download::cancelAuthenticationChallenge(const WebCore::AuthenticationChallenge& authenticationChallenge) 84 void FileDownloaderEfl::receivedCancellation(ResourceHandle*, const AuthenticationChallenge&) 85 85 { 86 86 notImplemented();
Note: See TracChangeset
for help on using the changeset viewer.