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

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

Issue 10628020: webkit/ppapi: Notify the container when a plugin is accepting touch events. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 6 months 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
« no previous file with comments | « webkit/plugins/ppapi/ppapi_plugin_instance.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_webplugin_impl.h" 5 #include "webkit/plugins/ppapi/ppapi_webplugin_impl.h"
6 6
7 #include <cmath> 7 #include <cmath>
8 8
9 #include "base/message_loop.h" 9 #include "base/message_loop.h"
10 #include "googleurl/src/gurl.h" 10 #include "googleurl/src/gurl.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 init_data_->module->path()); 101 init_data_->module->path());
102 if (!replacement_plugin || !replacement_plugin->initialize(container)) 102 if (!replacement_plugin || !replacement_plugin->initialize(container))
103 return false; 103 return false;
104 104
105 container->setPlugin(replacement_plugin); 105 container->setPlugin(replacement_plugin);
106 return true; 106 return true;
107 } 107 }
108 108
109 init_data_.reset(); 109 init_data_.reset();
110 container_ = container; 110 container_ = container;
111 container_->setAcceptingTouchEvents(instance_->IsAcceptingTouchEvents());
brettw 2012/06/22 18:03:54 Should the instance do this in Initialize() instea
sadrul 2012/06/22 21:37:09 Good point. Done.
111 return true; 112 return true;
112 } 113 }
113 114
114 void WebPluginImpl::destroy() { 115 void WebPluginImpl::destroy() {
115 if (instance_) { 116 if (instance_) {
116 ::ppapi::PpapiGlobals::Get()->GetVarTracker()->ReleaseVar(instance_object_); 117 ::ppapi::PpapiGlobals::Get()->GetVarTracker()->ReleaseVar(instance_object_);
117 instance_object_ = PP_MakeUndefined(); 118 instance_object_ = PP_MakeUndefined();
118 instance_->Delete(); 119 instance_->Delete();
119 instance_ = NULL; 120 instance_ = NULL;
120 } 121 }
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
289 void WebPluginImpl::rotateView(RotationType type) { 290 void WebPluginImpl::rotateView(RotationType type) {
290 instance_->RotateView(type); 291 instance_->RotateView(type);
291 } 292 }
292 293
293 bool WebPluginImpl::isPlaceholder() { 294 bool WebPluginImpl::isPlaceholder() {
294 return false; 295 return false;
295 } 296 }
296 297
297 } // namespace ppapi 298 } // namespace ppapi
298 } // namespace webkit 299 } // namespace webkit
OLDNEW
« no previous file with comments | « webkit/plugins/ppapi/ppapi_plugin_instance.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698