| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 "content/browser/android/content_view_core_impl.h" | 5 #include "content/browser/android/content_view_core_impl.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include "base/android/jni_android.h" | 9 #include "base/android/jni_android.h" |
| 10 #include "base/android/jni_array.h" | 10 #include "base/android/jni_array.h" |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 #include "content/browser/web_contents/web_contents_view_android.h" | 36 #include "content/browser/web_contents/web_contents_view_android.h" |
| 37 #include "content/common/frame_messages.h" | 37 #include "content/common/frame_messages.h" |
| 38 #include "content/common/input_messages.h" | 38 #include "content/common/input_messages.h" |
| 39 #include "content/common/view_messages.h" | 39 #include "content/common/view_messages.h" |
| 40 #include "content/public/browser/android/compositor.h" | 40 #include "content/public/browser/android/compositor.h" |
| 41 #include "content/public/browser/browser_context.h" | 41 #include "content/public/browser/browser_context.h" |
| 42 #include "content/public/browser/browser_thread.h" | 42 #include "content/public/browser/browser_thread.h" |
| 43 #include "content/public/browser/favicon_status.h" | 43 #include "content/public/browser/favicon_status.h" |
| 44 #include "content/public/browser/render_frame_host.h" | 44 #include "content/public/browser/render_frame_host.h" |
| 45 #include "content/public/browser/render_view_host.h" | 45 #include "content/public/browser/render_view_host.h" |
| 46 #include "content/public/browser/screen_orientation_provider.h" | |
| 47 #include "content/public/browser/ssl_host_state_delegate.h" | 46 #include "content/public/browser/ssl_host_state_delegate.h" |
| 48 #include "content/public/browser/web_contents.h" | 47 #include "content/public/browser/web_contents.h" |
| 49 #include "content/public/common/content_client.h" | 48 #include "content/public/common/content_client.h" |
| 50 #include "content/public/common/content_switches.h" | 49 #include "content/public/common/content_switches.h" |
| 51 #include "content/public/common/menu_item.h" | 50 #include "content/public/common/menu_item.h" |
| 52 #include "content/public/common/user_agent.h" | 51 #include "content/public/common/user_agent.h" |
| 53 #include "device/geolocation/geolocation_service_context.h" | 52 #include "device/geolocation/geolocation_service_context.h" |
| 54 #include "jni/ContentViewCore_jni.h" | 53 #include "jni/ContentViewCore_jni.h" |
| 55 #include "jni/DragEvent_jni.h" | 54 #include "jni/DragEvent_jni.h" |
| 56 #include "third_party/WebKit/public/platform/WebInputEvent.h" | 55 #include "third_party/WebKit/public/platform/WebInputEvent.h" |
| (...skipping 1311 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1368 accessibility_state->accessibility_mode()); | 1367 accessibility_state->accessibility_mode()); |
| 1369 } | 1368 } |
| 1370 } | 1369 } |
| 1371 } | 1370 } |
| 1372 | 1371 |
| 1373 void ContentViewCoreImpl::SendOrientationChangeEventInternal() { | 1372 void ContentViewCoreImpl::SendOrientationChangeEventInternal() { |
| 1374 RenderWidgetHostViewAndroid* rwhv = GetRenderWidgetHostViewAndroid(); | 1373 RenderWidgetHostViewAndroid* rwhv = GetRenderWidgetHostViewAndroid(); |
| 1375 if (rwhv) | 1374 if (rwhv) |
| 1376 rwhv->UpdateScreenInfo(GetViewAndroid()); | 1375 rwhv->UpdateScreenInfo(GetViewAndroid()); |
| 1377 | 1376 |
| 1378 static_cast<WebContentsImpl*>(web_contents()) | 1377 static_cast<WebContentsImpl*>(web_contents())->OnScreenOrientationChange(); |
| 1379 ->GetScreenOrientationProvider() | |
| 1380 ->OnOrientationChange(); | |
| 1381 } | 1378 } |
| 1382 | 1379 |
| 1383 jint ContentViewCoreImpl::GetCurrentRenderProcessId( | 1380 jint ContentViewCoreImpl::GetCurrentRenderProcessId( |
| 1384 JNIEnv* env, | 1381 JNIEnv* env, |
| 1385 const JavaParamRef<jobject>& obj) { | 1382 const JavaParamRef<jobject>& obj) { |
| 1386 return GetRenderProcessIdFromRenderViewHost( | 1383 return GetRenderProcessIdFromRenderViewHost( |
| 1387 web_contents_->GetRenderViewHost()); | 1384 web_contents_->GetRenderViewHost()); |
| 1388 } | 1385 } |
| 1389 | 1386 |
| 1390 void ContentViewCoreImpl::SetBackgroundOpaque(JNIEnv* env, | 1387 void ContentViewCoreImpl::SetBackgroundOpaque(JNIEnv* env, |
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1531 return ScopedJavaLocalRef<jobject>(); | 1528 return ScopedJavaLocalRef<jobject>(); |
| 1532 | 1529 |
| 1533 return view->GetJavaObject(); | 1530 return view->GetJavaObject(); |
| 1534 } | 1531 } |
| 1535 | 1532 |
| 1536 bool RegisterContentViewCore(JNIEnv* env) { | 1533 bool RegisterContentViewCore(JNIEnv* env) { |
| 1537 return RegisterNativesImpl(env); | 1534 return RegisterNativesImpl(env); |
| 1538 } | 1535 } |
| 1539 | 1536 |
| 1540 } // namespace content | 1537 } // namespace content |
| OLD | NEW |