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

Unified Diff: content/renderer/renderer_webkitplatformsupport_impl.cc

Issue 164913004: Chromium plumbing for Screen Orientation API orientationchange events. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: updated Created 6 years, 10 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: content/renderer/renderer_webkitplatformsupport_impl.cc
diff --git a/content/renderer/renderer_webkitplatformsupport_impl.cc b/content/renderer/renderer_webkitplatformsupport_impl.cc
index a92c3ae9616e954f0a2b6772e15e73153ae66e48..b8b6824a0b61bb4fc3853724aa723de87cffba28 100644
--- a/content/renderer/renderer_webkitplatformsupport_impl.cc
+++ b/content/renderer/renderer_webkitplatformsupport_impl.cc
@@ -49,6 +49,7 @@
#include "content/renderer/media/webcontentdecryptionmodule_impl.h"
#include "content/renderer/render_thread_impl.h"
#include "content/renderer/renderer_clipboard_client.h"
+#include "content/renderer/screen_orientation/screen_orientation_dispatcher.h"
#include "content/renderer/webclipboard_impl.h"
#include "content/renderer/webcrypto/webcrypto_impl.h"
#include "content/renderer/webgraphicscontext3d_provider_impl.h"
@@ -1063,6 +1064,18 @@ void RendererWebKitPlatformSupportImpl::cancelVibration() {
//------------------------------------------------------------------------------
+void RendererWebKitPlatformSupportImpl::setScreenOrientationListener(
+ blink::WebScreenOrientationListener* listener) {
+ if (!screen_orientation_dispatcher_) {
+ screen_orientation_dispatcher_.reset(
+ new ScreenOrientationDispatcher(RenderThreadImpl::current()));
+ }
+
+ screen_orientation_dispatcher_->setListener(listener);
+}
+
+//------------------------------------------------------------------------------
+
void RendererWebKitPlatformSupportImpl::queryStorageUsageAndQuota(
const blink::WebURL& storage_partition,
blink::WebStorageQuotaType type,

Powered by Google App Engine
This is Rietveld 408576698