OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "ppapi/proxy/interface_list.h" | 5 #include "ppapi/proxy/interface_list.h" |
6 | 6 |
7 #include "base/memory/singleton.h" | 7 #include "base/memory/singleton.h" |
8 #include "ppapi/c/dev/ppb_audio_input_dev.h" | 8 #include "ppapi/c/dev/ppb_audio_input_dev.h" |
9 #include "ppapi/c/dev/ppb_buffer_dev.h" | 9 #include "ppapi/c/dev/ppb_buffer_dev.h" |
10 #include "ppapi/c/dev/ppb_char_set_dev.h" | 10 #include "ppapi/c/dev/ppb_char_set_dev.h" |
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
241 const void* InterfaceList::GetInterfaceForPPP(const std::string& name) const { | 241 const void* InterfaceList::GetInterfaceForPPP(const std::string& name) const { |
242 NameToInterfaceInfoMap::const_iterator found = | 242 NameToInterfaceInfoMap::const_iterator found = |
243 name_to_plugin_info_.find(name); | 243 name_to_plugin_info_.find(name); |
244 if (found == name_to_plugin_info_.end()) | 244 if (found == name_to_plugin_info_.end()) |
245 return NULL; | 245 return NULL; |
246 return found->second.iface; | 246 return found->second.iface; |
247 } | 247 } |
248 | 248 |
249 void InterfaceList::AddFlashInterfaces() { | 249 void InterfaceList::AddFlashInterfaces() { |
250 AddProxy(API_ID_PPB_FLASH, &ProxyFactory<PPB_Flash_Proxy>); | 250 AddProxy(API_ID_PPB_FLASH, &ProxyFactory<PPB_Flash_Proxy>); |
251 AddPPB(PPB_FLASH_INTERFACE, API_ID_PPB_FLASH, | 251 AddPPB(PPB_FLASH_INTERFACE_11_0, API_ID_PPB_FLASH, |
252 PPB_Flash_Proxy::GetInterface()); | 252 PPB_Flash_Proxy::GetInterface11()); |
| 253 AddPPB(PPB_FLASH_INTERFACE_12_0, API_ID_PPB_FLASH, |
| 254 PPB_Flash_Proxy::GetInterface12()); |
253 | 255 |
254 AddProxy(API_ID_PPB_FLASH_CLIPBOARD, | 256 AddProxy(API_ID_PPB_FLASH_CLIPBOARD, |
255 &ProxyFactory<PPB_Flash_Clipboard_Proxy>); | 257 &ProxyFactory<PPB_Flash_Clipboard_Proxy>); |
256 AddPPB(PPB_FLASH_CLIPBOARD_INTERFACE, API_ID_PPB_FLASH_CLIPBOARD, | 258 AddPPB(PPB_FLASH_CLIPBOARD_INTERFACE, API_ID_PPB_FLASH_CLIPBOARD, |
257 thunk::GetPPB_Flash_Clipboard_Thunk()); | 259 thunk::GetPPB_Flash_Clipboard_Thunk()); |
258 AddPPB(PPB_FLASH_CLIPBOARD_INTERFACE_3_LEGACY, API_ID_PPB_FLASH_CLIPBOARD, | 260 AddPPB(PPB_FLASH_CLIPBOARD_INTERFACE_3_LEGACY, API_ID_PPB_FLASH_CLIPBOARD, |
259 thunk::GetPPB_Flash_Clipboard_Thunk()); | 261 thunk::GetPPB_Flash_Clipboard_Thunk()); |
260 | 262 |
261 AddProxy(API_ID_PPB_FLASH_FILE_FILEREF, | 263 AddProxy(API_ID_PPB_FLASH_FILE_FILEREF, |
262 &ProxyFactory<PPB_Flash_File_FileRef_Proxy>); | 264 &ProxyFactory<PPB_Flash_File_FileRef_Proxy>); |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
320 AddPPB(info->name, info->id, info->interface_ptr); | 322 AddPPB(info->name, info->id, info->interface_ptr); |
321 } | 323 } |
322 | 324 |
323 void InterfaceList::AddPPP(const InterfaceProxy::Info* info) { | 325 void InterfaceList::AddPPP(const InterfaceProxy::Info* info) { |
324 AddProxy(info->id, info->create_proxy); | 326 AddProxy(info->id, info->create_proxy); |
325 AddPPP(info->name, info->id, info->interface_ptr); | 327 AddPPP(info->name, info->id, info->interface_ptr); |
326 } | 328 } |
327 | 329 |
328 } // namespace proxy | 330 } // namespace proxy |
329 } // namespace ppapi | 331 } // namespace ppapi |
OLD | NEW |