OLD | NEW |
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 "content/browser/android/content_view_core_impl.h" | 5 #include "content/browser/android/content_view_core_impl.h" |
6 | 6 |
7 #include "base/android/jni_android.h" | 7 #include "base/android/jni_android.h" |
8 #include "base/android/jni_array.h" | 8 #include "base/android/jni_array.h" |
9 #include "base/android/jni_string.h" | 9 #include "base/android/jni_string.h" |
10 #include "base/android/scoped_java_ref.h" | 10 #include "base/android/scoped_java_ref.h" |
(...skipping 1211 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1222 RenderViewHost* host = web_contents_->GetRenderViewHost(); | 1222 RenderViewHost* host = web_contents_->GetRenderViewHost(); |
1223 host->ExitFullscreen(); | 1223 host->ExitFullscreen(); |
1224 } | 1224 } |
1225 | 1225 |
1226 void ContentViewCoreImpl::EnableHidingTopControls(JNIEnv* env, jobject obj, | 1226 void ContentViewCoreImpl::EnableHidingTopControls(JNIEnv* env, jobject obj, |
1227 bool enable) { | 1227 bool enable) { |
1228 RenderViewHost* host = web_contents_->GetRenderViewHost(); | 1228 RenderViewHost* host = web_contents_->GetRenderViewHost(); |
1229 host->Send(new ViewMsg_EnableHidingTopControls(host->GetRoutingID(), enable)); | 1229 host->Send(new ViewMsg_EnableHidingTopControls(host->GetRoutingID(), enable)); |
1230 } | 1230 } |
1231 | 1231 |
| 1232 void ContentViewCoreImpl::ShowTopControls(JNIEnv* env, jobject obj, bool show) { |
| 1233 RenderViewHost* host = web_contents_->GetRenderViewHost(); |
| 1234 host->Send(new ViewMsg_ShowTopControls(host->GetRoutingID(), show)); |
| 1235 } |
| 1236 |
1232 void ContentViewCoreImpl::ShowImeIfNeeded(JNIEnv* env, jobject obj) { | 1237 void ContentViewCoreImpl::ShowImeIfNeeded(JNIEnv* env, jobject obj) { |
1233 RenderViewHost* host = web_contents_->GetRenderViewHost(); | 1238 RenderViewHost* host = web_contents_->GetRenderViewHost(); |
1234 host->Send(new ViewMsg_ShowImeIfNeeded(host->GetRoutingID())); | 1239 host->Send(new ViewMsg_ShowImeIfNeeded(host->GetRoutingID())); |
1235 } | 1240 } |
1236 | 1241 |
1237 void ContentViewCoreImpl::ScrollFocusedEditableNodeIntoView(JNIEnv* env, | 1242 void ContentViewCoreImpl::ScrollFocusedEditableNodeIntoView(JNIEnv* env, |
1238 jobject obj) { | 1243 jobject obj) { |
1239 RenderViewHost* host = web_contents_->GetRenderViewHost(); | 1244 RenderViewHost* host = web_contents_->GetRenderViewHost(); |
1240 host->Send(new ViewMsg_ScrollFocusedEditableNodeIntoRect(host->GetRoutingID(), | 1245 host->Send(new ViewMsg_ScrollFocusedEditableNodeIntoRect(host->GetRoutingID(), |
1241 gfx::Rect())); | 1246 gfx::Rect())); |
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1443 reinterpret_cast<WebContents*>(native_web_contents), | 1448 reinterpret_cast<WebContents*>(native_web_contents), |
1444 reinterpret_cast<ui::WindowAndroid*>(native_window)); | 1449 reinterpret_cast<ui::WindowAndroid*>(native_window)); |
1445 return reinterpret_cast<jint>(view); | 1450 return reinterpret_cast<jint>(view); |
1446 } | 1451 } |
1447 | 1452 |
1448 bool RegisterContentViewCore(JNIEnv* env) { | 1453 bool RegisterContentViewCore(JNIEnv* env) { |
1449 return RegisterNativesImpl(env); | 1454 return RegisterNativesImpl(env); |
1450 } | 1455 } |
1451 | 1456 |
1452 } // namespace content | 1457 } // namespace content |
OLD | NEW |