Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1283)

Unified Diff: webkit/plugins/ppapi/ppb_url_loader_impl.h

Issue 5828003: Move the Pepper implementation from webkit/glue/plugins/pepper_* to... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webkit/plugins/ppapi/ppb_transport_impl.cc ('k') | webkit/plugins/ppapi/ppb_url_loader_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/plugins/ppapi/ppb_url_loader_impl.h
===================================================================
--- webkit/plugins/ppapi/ppb_url_loader_impl.h (revision 0)
+++ webkit/plugins/ppapi/ppb_url_loader_impl.h (working copy)
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef WEBKIT_GLUE_PLUGINS_PEPPER_URL_LOADER_H_
-#define WEBKIT_GLUE_PLUGINS_PEPPER_URL_LOADER_H_
+#ifndef WEBKIT_PLUGINS_PPAPI_PPB_URL_LOADER_IMPL_H_
+#define WEBKIT_PLUGINS_PPAPI_PPB_URL_LOADER_IMPL_H_
#include <deque>
@@ -11,8 +11,8 @@
#include "ppapi/c/pp_completion_callback.h"
#include "ppapi/c/trusted/ppb_url_loader_trusted.h"
#include "third_party/WebKit/WebKit/chromium/public/WebURLLoaderClient.h"
-#include "webkit/glue/plugins/pepper_plugin_instance.h"
-#include "webkit/glue/plugins/pepper_resource.h"
+#include "webkit/plugins/ppapi/plugin_instance.h"
+#include "webkit/plugins/ppapi/resource.h"
struct PPB_URLLoader;
struct PPB_URLLoaderTrusted;
@@ -22,18 +22,19 @@
class WebURL;
}
-namespace pepper {
+namespace webkit {
+namespace ppapi {
class PluginInstance;
-class URLRequestInfo;
-class URLResponseInfo;
+class PPB_URLRequestInfo_Impl;
+class PPB_URLResponseInfo_Impl;
-class URLLoader : public Resource,
+class PPB_URLLoader_Impl : public Resource,
public WebKit::WebURLLoaderClient,
public PluginInstance::Observer {
public:
- URLLoader(PluginInstance* instance, bool main_document_loader);
- virtual ~URLLoader();
+ PPB_URLLoader_Impl(PluginInstance* instance, bool main_document_loader);
+ virtual ~PPB_URLLoader_Impl();
// Returns a pointer to the interface implementing PPB_URLLoader that is
// exposed to the plugin.
@@ -44,10 +45,11 @@
static const PPB_URLLoaderTrusted* GetTrustedInterface();
// Resource overrides.
- virtual URLLoader* AsURLLoader();
+ virtual PPB_URLLoader_Impl* AsPPB_URLLoader_Impl();
// PPB_URLLoader implementation.
- int32_t Open(URLRequestInfo* request, PP_CompletionCallback callback);
+ int32_t Open(PPB_URLRequestInfo_Impl* request,
+ PP_CompletionCallback callback);
int32_t FollowRedirect(PP_CompletionCallback callback);
bool GetUploadProgress(int64_t* bytes_sent,
int64_t* total_bytes_to_be_sent);
@@ -84,7 +86,7 @@
// PluginInstance::Observer implementation.
virtual void InstanceDestroyed(PluginInstance* instance);
- URLResponseInfo* response_info() const { return response_info_; }
+ PPB_URLResponseInfo_Impl* response_info() const { return response_info_; }
private:
void RunCallback(int32_t result);
@@ -108,7 +110,7 @@
bool RecordDownloadProgress() const;
bool RecordUploadProgress() const;
- // This will be NULL if the instance has been deleted but this URLLoader was
+ // This will be NULL if the instance has been deleted but this PPB_URLLoader_Impl was
// somehow leaked. In general, you should not need to check this for NULL.
// However, if you see a NULL pointer crash, that means somebody is holding
// a reference to this object longer than the PluginInstance's lifetime.
@@ -118,8 +120,8 @@
// wrapping the main document's loader (i.e. loader_ is null).
bool main_document_loader_;
scoped_ptr<WebKit::WebURLLoader> loader_;
- scoped_refptr<URLRequestInfo> request_info_;
- scoped_refptr<URLResponseInfo> response_info_;
+ scoped_refptr<PPB_URLRequestInfo_Impl> request_info_;
+ scoped_refptr<PPB_URLResponseInfo_Impl> response_info_;
PP_CompletionCallback pending_callback_;
std::deque<char> buffer_;
int64_t bytes_sent_;
@@ -133,8 +135,11 @@
bool has_universal_access_;
PP_URLLoaderTrusted_StatusCallback status_callback_;
+
+ DISALLOW_COPY_AND_ASSIGN(PPB_URLLoader_Impl);
};
-} // namespace pepper
+} // namespace ppapi
+} // namespace webkit
-#endif // WEBKIT_GLUE_PLUGINS_PEPPER_URL_LOADER_H_
+#endif // WEBKIT_PLUGINS_PPAPI_PPB_URL_LOADER_IMPL_H_
« no previous file with comments | « webkit/plugins/ppapi/ppb_transport_impl.cc ('k') | webkit/plugins/ppapi/ppb_url_loader_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698