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

Unified Diff: webkit/plugins/ppapi/ppapi_plugin_instance.cc

Issue 7538006: Pepper and WebKit API change to support a plugin knowing if a scrollbar is an overlay one. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Redo by adding ScrollbarGroup to pepper and WebKit Created 9 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: webkit/plugins/ppapi/ppapi_plugin_instance.cc
===================================================================
--- webkit/plugins/ppapi/ppapi_plugin_instance.cc (revision 95420)
+++ webkit/plugins/ppapi/ppapi_plugin_instance.cc (working copy)
@@ -14,6 +14,7 @@
#include "ppapi/c/dev/ppb_memory_dev.h"
#include "ppapi/c/dev/ppb_zoom_dev.h"
#include "ppapi/c/dev/ppp_find_dev.h"
+#include "ppapi/c/dev/ppp_resize_dev.h"
#include "ppapi/c/dev/ppp_policy_update_dev.h"
#include "ppapi/c/dev/ppp_selection_dev.h"
#include "ppapi/c/dev/ppp_zoom_dev.h"
@@ -223,6 +224,7 @@
plugin_private_interface_(NULL),
plugin_pdf_interface_(NULL),
plugin_policy_updated_interface_(NULL),
+ plugin_resize_interface_(NULL),
plugin_selection_interface_(NULL),
plugin_zoom_interface_(NULL),
checked_for_plugin_input_event_interface_(false),
@@ -672,6 +674,18 @@
plugin_find_interface_->StopFind(pp_instance());
}
+void PluginInstance::WillStartLiveResize() {
+ if (!LoadResizeInterface())
+ return;
+ plugin_resize_interface_->WillStartLiveResize(pp_instance());
+}
+
+void PluginInstance::WillEndLiveResize() {
+ if (!LoadResizeInterface())
+ return;
+ plugin_resize_interface_->WillEndLiveResize(pp_instance());
+}
+
bool PluginInstance::LoadFindInterface() {
if (!plugin_find_interface_) {
plugin_find_interface_ =
@@ -752,6 +766,16 @@
return !!plugin_private_interface_;
}
+bool PluginInstance::LoadResizeInterface() {
+ if (!plugin_resize_interface_) {
+ plugin_resize_interface_ =
+ static_cast<const PPP_Resize_Dev*>(module_->GetPluginInterface(
+ PPP_RESIZE_DEV_INTERFACE));
+ }
+
+ return !!plugin_resize_interface_;
+}
+
bool PluginInstance::LoadSelectionInterface() {
if (!plugin_selection_interface_) {
plugin_selection_interface_ =

Powered by Google App Engine
This is Rietveld 408576698