| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "webkit/plugins/ppapi/ppapi_plugin_instance.h" | 5 #include "webkit/plugins/ppapi/ppapi_plugin_instance.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/callback_helpers.h" | 8 #include "base/callback_helpers.h" |
| 9 #include "base/debug/trace_event.h" | 9 #include "base/debug/trace_event.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 1617 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1628 const std::string& init_data) { | 1628 const std::string& init_data) { |
| 1629 if (!LoadContentDecryptorInterface()) | 1629 if (!LoadContentDecryptorInterface()) |
| 1630 return false; | 1630 return false; |
| 1631 if (key_system.empty()) | 1631 if (key_system.empty()) |
| 1632 return false; | 1632 return false; |
| 1633 | 1633 |
| 1634 PP_Var init_data_array = | 1634 PP_Var init_data_array = |
| 1635 PpapiGlobals::Get()->GetVarTracker()->MakeArrayBufferPPVar( | 1635 PpapiGlobals::Get()->GetVarTracker()->MakeArrayBufferPPVar( |
| 1636 init_data.size(), init_data.data()); | 1636 init_data.size(), init_data.data()); |
| 1637 | 1637 |
| 1638 // TODO(tomfinegan): Pass "type" once PPP_ContentDecryptor_Private is updated. | |
| 1639 plugin_decryption_interface_->GenerateKeyRequest( | 1638 plugin_decryption_interface_->GenerateKeyRequest( |
| 1640 pp_instance(), | 1639 pp_instance(), |
| 1641 StringVar::StringToPPVar(key_system), | 1640 StringVar::StringToPPVar(key_system), |
| 1641 StringVar::StringToPPVar(type), |
| 1642 init_data_array); | 1642 init_data_array); |
| 1643 return true; | 1643 return true; |
| 1644 } | 1644 } |
| 1645 | 1645 |
| 1646 bool PluginInstance::AddKey(const std::string& session_id, | 1646 bool PluginInstance::AddKey(const std::string& session_id, |
| 1647 const std::string& key, | 1647 const std::string& key, |
| 1648 const std::string& init_data) { | 1648 const std::string& init_data) { |
| 1649 if (!LoadContentDecryptorInterface()) | 1649 if (!LoadContentDecryptorInterface()) |
| 1650 return false; | 1650 return false; |
| 1651 PP_Var key_array = | 1651 PP_Var key_array = |
| (...skipping 1576 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3228 screen_size_for_fullscreen_ = gfx::Size(); | 3228 screen_size_for_fullscreen_ = gfx::Size(); |
| 3229 WebElement element = container_->element(); | 3229 WebElement element = container_->element(); |
| 3230 element.setAttribute(WebString::fromUTF8(kWidth), width_before_fullscreen_); | 3230 element.setAttribute(WebString::fromUTF8(kWidth), width_before_fullscreen_); |
| 3231 element.setAttribute(WebString::fromUTF8(kHeight), height_before_fullscreen_); | 3231 element.setAttribute(WebString::fromUTF8(kHeight), height_before_fullscreen_); |
| 3232 element.setAttribute(WebString::fromUTF8(kBorder), border_before_fullscreen_); | 3232 element.setAttribute(WebString::fromUTF8(kBorder), border_before_fullscreen_); |
| 3233 element.setAttribute(WebString::fromUTF8(kStyle), style_before_fullscreen_); | 3233 element.setAttribute(WebString::fromUTF8(kStyle), style_before_fullscreen_); |
| 3234 } | 3234 } |
| 3235 | 3235 |
| 3236 } // namespace ppapi | 3236 } // namespace ppapi |
| 3237 } // namespace webkit | 3237 } // namespace webkit |
| OLD | NEW |