summaryrefslogtreecommitdiffstats
path: root/ppapi/cpp
diff options
context:
space:
mode:
authorbbudge <bbudge@chromium.org>2014-11-26 11:55:47 -0800
committerCommit bot <commit-bot@chromium.org>2014-11-26 19:56:06 +0000
commit44c5fffdbe8e5774914501beec274ebe1361e182 (patch)
tree0f4aa0806f81d041747843bc5dd83c6520281803 /ppapi/cpp
parent2c98cb19ec1d18375cee20e84bc123f5d9b41d6d (diff)
downloadchromium_src-44c5fffdbe8e5774914501beec274ebe1361e182.zip
chromium_src-44c5fffdbe8e5774914501beec274ebe1361e182.tar.gz
chromium_src-44c5fffdbe8e5774914501beec274ebe1361e182.tar.bz2
Pepper: Query all versions of PPB_VideoDecoder to construct C++ wrapper.
BUG=none Review URL: https://codereview.chromium.org/752033007 Cr-Commit-Position: refs/heads/master@{#305861}
Diffstat (limited to 'ppapi/cpp')
-rw-r--r--ppapi/cpp/video_decoder.cc8
1 files changed, 7 insertions, 1 deletions
diff --git a/ppapi/cpp/video_decoder.cc b/ppapi/cpp/video_decoder.cc
index 42236e4..ea954a6 100644
--- a/ppapi/cpp/video_decoder.cc
+++ b/ppapi/cpp/video_decoder.cc
@@ -69,7 +69,13 @@ VideoDecoder::VideoDecoder() {
}
VideoDecoder::VideoDecoder(const InstanceHandle& instance) {
- if (has_interface<PPB_VideoDecoder_0_1>()) {
+ if (has_interface<PPB_VideoDecoder_1_0>()) {
+ PassRefFromConstructor(
+ get_interface<PPB_VideoDecoder_1_0>()->Create(instance.pp_instance()));
+ } else if (has_interface<PPB_VideoDecoder_0_2>()) {
+ PassRefFromConstructor(
+ get_interface<PPB_VideoDecoder_0_2>()->Create(instance.pp_instance()));
+ } else if (has_interface<PPB_VideoDecoder_0_1>()) {
PassRefFromConstructor(
get_interface<PPB_VideoDecoder_0_1>()->Create(instance.pp_instance()));
}