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

Unified Diff: content/browser/android/content_view_core_impl.cc

Issue 327573002: Properly route screen orientation IPC messages. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@screen_lock_view
Patch Set: review comments Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | content/browser/renderer_host/render_process_host_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/android/content_view_core_impl.cc
diff --git a/content/browser/android/content_view_core_impl.cc b/content/browser/android/content_view_core_impl.cc
index 0fdc058b01df1913bdd2fd047833cf83185792e2..2335d0a5fb05b9ca4df9420b4bb70bf60b3a5609 100644
--- a/content/browser/android/content_view_core_impl.cc
+++ b/content/browser/android/content_view_core_impl.cc
@@ -1542,38 +1542,6 @@ void ContentViewCoreImpl::SendOrientationChangeEventInternal() {
RenderWidgetHostViewAndroid* rwhv = GetRenderWidgetHostViewAndroid();
if (rwhv)
rwhv->UpdateScreenInfo(GetViewAndroid());
-
- // TODO(mlamouri): temporary plumbing for Screen Orientation, this will change
- // in the future. The OnResize IPC message sent from UpdateScreenInfo() will
- // propagate the information.
- blink::WebScreenOrientationType orientation =
- blink::WebScreenOrientationPortraitPrimary;
-
- switch (device_orientation_) {
- case 0:
- orientation = blink::WebScreenOrientationPortraitPrimary;
- break;
- case 90:
- orientation = blink::WebScreenOrientationLandscapePrimary;
- break;
- case -90:
- orientation = blink::WebScreenOrientationLandscapeSecondary;
- break;
- case 180:
- orientation = blink::WebScreenOrientationPortraitSecondary;
- break;
- default:
- NOTREACHED();
- }
-
- ScreenOrientationDispatcherHost* sodh =
- static_cast<RenderProcessHostImpl*>(web_contents_->
- GetRenderProcessHost())->screen_orientation_dispatcher_host();
-
- // sodh can be null if the RenderProcessHost is in the process of being
- // destroyed or not yet initialized.
- if (sodh)
- sodh->OnOrientationChange(orientation);
}
void ContentViewCoreImpl::ExtractSmartClipData(JNIEnv* env,
« no previous file with comments | « no previous file | content/browser/renderer_host/render_process_host_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698