summaryrefslogtreecommitdiffstats
path: root/gpu
diff options
context:
space:
mode:
authorraymes@chromium.org <raymes@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-06-06 23:25:06 +0000
committerraymes@chromium.org <raymes@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-06-06 23:25:06 +0000
commit829cfcdba6cbade6b8e64641b1739f3dc8e13733 (patch)
tree2abfa11b4a7fe8126f67caa19fea1a0de1f26295 /gpu
parentf0090103b07868ae41984413238e71c324c19e41 (diff)
downloadchromium_src-829cfcdba6cbade6b8e64641b1739f3dc8e13733.zip
chromium_src-829cfcdba6cbade6b8e64641b1739f3dc8e13733.tar.gz
chromium_src-829cfcdba6cbade6b8e64641b1739f3dc8e13733.tar.bz2
Add simple hand-rolled RTTI for Pepper ResourceHosts
This allows Pepper ResourceHosts to be safely dynamically cast to a given type. For example, you may have a PP_Resource provided by the plugin which corresponds to a ResourceHost object which should be of type X. But statically casting to type X would be unsafe because the plugin is untrusted. I've kept this simple for now because we don't have too many types which need to be dynamically cast. To add RTTI for a new class, you need to add a new AsPepperXXXHost virtual function in ResourceHost and override it in your derived class. This also cleans up the previous RTTI checks for Graphics2D and the unsafe checks that were being used for FileSystem. BUG=246396 Review URL: https://chromiumcodereview.appspot.com/16057021 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@204652 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'gpu')
0 files changed, 0 insertions, 0 deletions