OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "chrome/browser/android/compositor/scene_layer/contextual_search_scene_
layer.h" | 5 #include "chrome/browser/android/compositor/scene_layer/contextual_search_scene_
layer.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 "cc/layers/solid_color_layer.h" | 9 #include "cc/layers/solid_color_layer.h" |
10 #include "chrome/browser/android/compositor/layer/contextual_search_layer.h" | 10 #include "chrome/browser/android/compositor/layer/contextual_search_layer.h" |
11 #include "content/public/browser/android/compositor.h" | 11 #include "content/public/browser/android/compositor.h" |
12 #include "content/public/browser/web_contents.h" | 12 #include "content/public/browser/web_contents.h" |
13 #include "jni/ContextualSearchSceneLayer_jni.h" | 13 #include "jni/ContextualSearchSceneLayer_jni.h" |
14 #include "ui/android/resources/resource_manager_impl.h" | 14 #include "ui/android/resources/resource_manager_impl.h" |
15 #include "ui/android/view_android.h" | 15 #include "ui/android/view_android.h" |
16 #include "ui/gfx/android/java_bitmap.h" | 16 #include "ui/gfx/android/java_bitmap.h" |
17 | 17 |
| 18 using base::android::JavaParamRef; |
| 19 |
18 namespace chrome { | 20 namespace chrome { |
19 namespace android { | 21 namespace android { |
20 | 22 |
21 ContextualSearchSceneLayer::ContextualSearchSceneLayer(JNIEnv* env, | 23 ContextualSearchSceneLayer::ContextualSearchSceneLayer(JNIEnv* env, |
22 jobject jobj) | 24 jobject jobj) |
23 : SceneLayer(env, jobj), | 25 : SceneLayer(env, jobj), |
24 base_page_brightness_(1.0f), | 26 base_page_brightness_(1.0f), |
25 content_container_(cc::Layer::Create()) { | 27 content_container_(cc::Layer::Create()) { |
26 // Responsible for moving the base page without modifying the layer itself. | 28 // Responsible for moving the base page without modifying the layer itself. |
27 content_container_->SetIsDrawable(true); | 29 content_container_->SetIsDrawable(true); |
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
209 new ContextualSearchSceneLayer(env, jobj); | 211 new ContextualSearchSceneLayer(env, jobj); |
210 return reinterpret_cast<intptr_t>(tree_provider); | 212 return reinterpret_cast<intptr_t>(tree_provider); |
211 } | 213 } |
212 | 214 |
213 bool RegisterContextualSearchSceneLayer(JNIEnv* env) { | 215 bool RegisterContextualSearchSceneLayer(JNIEnv* env) { |
214 return RegisterNativesImpl(env); | 216 return RegisterNativesImpl(env); |
215 } | 217 } |
216 | 218 |
217 } // namespace android | 219 } // namespace android |
218 } // namespace chrome | 220 } // namespace chrome |
OLD | NEW |