Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(71)

Side by Side Diff: webkit/plugins/ppapi/ppapi_plugin_instance.cc

Issue 11270057: Add type argument to pepper content decryptor method GenerateKeyRequest(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 1599 matching lines...) Expand 10 before | Expand all | Expand 10 after
1610 const std::string& init_data) { 1610 const std::string& init_data) {
1611 if (!LoadContentDecryptorInterface()) 1611 if (!LoadContentDecryptorInterface())
1612 return false; 1612 return false;
1613 if (key_system.empty()) 1613 if (key_system.empty())
1614 return false; 1614 return false;
1615 1615
1616 PP_Var init_data_array = 1616 PP_Var init_data_array =
1617 PpapiGlobals::Get()->GetVarTracker()->MakeArrayBufferPPVar( 1617 PpapiGlobals::Get()->GetVarTracker()->MakeArrayBufferPPVar(
1618 init_data.size(), init_data.data()); 1618 init_data.size(), init_data.data());
1619 1619
1620 // TODO(tomfinegan): Add mime type argument to this method, and remove the
1621 // hard coded mime type.
1622 const std::string mime_type = "video/webm";
ddorwin 2012/10/26 18:37:06 Let's just go with the empty string. CDMs will hav
Tom Finegan 2012/10/26 22:51:33 Done.
1620 plugin_decryption_interface_->GenerateKeyRequest( 1623 plugin_decryption_interface_->GenerateKeyRequest(
1621 pp_instance(), 1624 pp_instance(),
1622 StringVar::StringToPPVar(key_system), 1625 StringVar::StringToPPVar(key_system),
1626 StringVar::StringToPPVar(mime_type),
1623 init_data_array); 1627 init_data_array);
1624 return true; 1628 return true;
1625 } 1629 }
1626 1630
1627 bool PluginInstance::AddKey(const std::string& session_id, 1631 bool PluginInstance::AddKey(const std::string& session_id,
1628 const std::string& key, 1632 const std::string& key,
1629 const std::string& init_data) { 1633 const std::string& init_data) {
1630 if (!LoadContentDecryptorInterface()) 1634 if (!LoadContentDecryptorInterface())
1631 return false; 1635 return false;
1632 PP_Var key_array = 1636 PP_Var key_array =
(...skipping 1576 matching lines...) Expand 10 before | Expand all | Expand 10 after
3209 screen_size_for_fullscreen_ = gfx::Size(); 3213 screen_size_for_fullscreen_ = gfx::Size();
3210 WebElement element = container_->element(); 3214 WebElement element = container_->element();
3211 element.setAttribute(WebString::fromUTF8(kWidth), width_before_fullscreen_); 3215 element.setAttribute(WebString::fromUTF8(kWidth), width_before_fullscreen_);
3212 element.setAttribute(WebString::fromUTF8(kHeight), height_before_fullscreen_); 3216 element.setAttribute(WebString::fromUTF8(kHeight), height_before_fullscreen_);
3213 element.setAttribute(WebString::fromUTF8(kBorder), border_before_fullscreen_); 3217 element.setAttribute(WebString::fromUTF8(kBorder), border_before_fullscreen_);
3214 element.setAttribute(WebString::fromUTF8(kStyle), style_before_fullscreen_); 3218 element.setAttribute(WebString::fromUTF8(kStyle), style_before_fullscreen_);
3215 } 3219 }
3216 3220
3217 } // namespace ppapi 3221 } // namespace ppapi
3218 } // namespace webkit 3222 } // namespace webkit
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698