diff options
author | erg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-12-13 20:10:45 +0000 |
---|---|---|
committer | erg@google.com <erg@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-12-13 20:10:45 +0000 |
commit | ddb1e5ae096bd91da721887fd55e68c603bf7067 (patch) | |
tree | 401d9a379ff03bb8b69a1ce9c23fe182f673f587 /ppapi | |
parent | 1c9526e0650a91e412d815417634c9f193b1a4d5 (diff) | |
download | chromium_src-ddb1e5ae096bd91da721887fd55e68c603bf7067.zip chromium_src-ddb1e5ae096bd91da721887fd55e68c603bf7067.tar.gz chromium_src-ddb1e5ae096bd91da721887fd55e68c603bf7067.tar.bz2 |
Even more virtual method deinlining.
BUG=none
TEST=compiles
Review URL: http://codereview.chromium.org/5741001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@69041 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ppapi')
-rw-r--r-- | ppapi/proxy/image_data.cc | 4 | ||||
-rw-r--r-- | ppapi/proxy/image_data.h | 2 | ||||
-rw-r--r-- | ppapi/proxy/plugin_resource.cc | 3 | ||||
-rw-r--r-- | ppapi/proxy/plugin_resource.h | 8 |
4 files changed, 10 insertions, 7 deletions
diff --git a/ppapi/proxy/image_data.cc b/ppapi/proxy/image_data.cc index c01896d..2af7026 100644 --- a/ppapi/proxy/image_data.cc +++ b/ppapi/proxy/image_data.cc @@ -26,6 +26,10 @@ ImageData::~ImageData() { Unmap(); } +ImageData* ImageData::AsImageData() { + return this; +} + void* ImageData::Map() { #if defined(OS_WIN) NOTIMPLEMENTED(); diff --git a/ppapi/proxy/image_data.h b/ppapi/proxy/image_data.h index fb4a839..6e962ab 100644 --- a/ppapi/proxy/image_data.h +++ b/ppapi/proxy/image_data.h @@ -19,7 +19,7 @@ class ImageData : public PluginResource { virtual ~ImageData(); // Resource overrides. - virtual ImageData* AsImageData() { return this; } + virtual ImageData* AsImageData(); void* Map(); void Unmap(); diff --git a/ppapi/proxy/plugin_resource.cc b/ppapi/proxy/plugin_resource.cc index d535cc7..05803ef 100644 --- a/ppapi/proxy/plugin_resource.cc +++ b/ppapi/proxy/plugin_resource.cc @@ -15,9 +15,8 @@ PluginResource::~PluginResource() { #define DEFINE_TYPE_GETTER(RESOURCE) \ RESOURCE* PluginResource::As##RESOURCE() { return NULL; } -FOR_ALL_RESOURCES(DEFINE_TYPE_GETTER) +FOR_ALL_PLUGIN_RESOURCES(DEFINE_TYPE_GETTER) #undef DEFINE_TYPE_GETTER - } // namespace proxy } // namespace pp diff --git a/ppapi/proxy/plugin_resource.h b/ppapi/proxy/plugin_resource.h index 2c195bc..780a2bd 100644 --- a/ppapi/proxy/plugin_resource.h +++ b/ppapi/proxy/plugin_resource.h @@ -10,7 +10,7 @@ #include "ppapi/proxy/plugin_resource_tracker.h" // If you inherit from resource, make sure you add the class name here. -#define FOR_ALL_RESOURCES(F) \ +#define FOR_ALL_PLUGIN_RESOURCES(F) \ F(Audio) \ F(AudioConfig) \ F(Buffer) \ @@ -27,7 +27,7 @@ namespace proxy { // Forward declaration of Resource classes. #define DECLARE_RESOURCE_CLASS(RESOURCE) class RESOURCE; -FOR_ALL_RESOURCES(DECLARE_RESOURCE_CLASS) +FOR_ALL_PLUGIN_RESOURCES(DECLARE_RESOURCE_CLASS) #undef DECLARE_RESOURCE_CLASS class PluginResource { @@ -51,7 +51,7 @@ class PluginResource { // function. #define DEFINE_TYPE_GETTER(RESOURCE) \ virtual RESOURCE* As##RESOURCE(); - FOR_ALL_RESOURCES(DEFINE_TYPE_GETTER) + FOR_ALL_PLUGIN_RESOURCES(DEFINE_TYPE_GETTER) #undef DEFINE_TYPE_GETTER DISALLOW_COPY_AND_ASSIGN(PluginResource); @@ -62,7 +62,7 @@ class PluginResource { template <> inline Type* PluginResource::Cast<Type>() { \ return As##Type(); \ } -FOR_ALL_RESOURCES(DEFINE_RESOURCE_CAST) +FOR_ALL_PLUGIN_RESOURCES(DEFINE_RESOURCE_CAST) #undef DEFINE_RESOURCE_CAST } // namespace proxy |