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

Side by Side Diff: chrome/browser/android/compositor/scene_layer/reader_mode_scene_layer.cc

Issue 2801153003: [Contextual Search] Add a handle to the bar when Chrome Home is enabled (Closed)
Patch Set: Revert changes to OverlayPanelBase#initializeUiState() Created 3 years, 8 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 unified diff | Download patch
« no previous file with comments | « chrome/browser/android/compositor/scene_layer/contextual_search_scene_layer.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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/reader_mode_scene_layer. h" 5 #include "chrome/browser/android/compositor/scene_layer/reader_mode_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/reader_mode_layer.h" 10 #include "chrome/browser/android/compositor/layer/reader_mode_layer.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 } 47 }
48 48
49 void ReaderModeSceneLayer::SetResourceIds( 49 void ReaderModeSceneLayer::SetResourceIds(
50 JNIEnv* env, 50 JNIEnv* env,
51 const JavaParamRef<jobject>& object, 51 const JavaParamRef<jobject>& object,
52 jint text_resource_id, 52 jint text_resource_id,
53 jint bar_background_resource_id, 53 jint bar_background_resource_id,
54 jint bar_shadow_resource_id, 54 jint bar_shadow_resource_id,
55 jint panel_icon_resource_id, 55 jint panel_icon_resource_id,
56 jint close_icon_resource_id) { 56 jint close_icon_resource_id) {
57
58 reader_mode_layer_->SetResourceIds( 57 reader_mode_layer_->SetResourceIds(
59 text_resource_id, 58 text_resource_id, bar_background_resource_id, bar_shadow_resource_id,
60 bar_background_resource_id, 59 panel_icon_resource_id, close_icon_resource_id, 0);
61 bar_shadow_resource_id,
62 panel_icon_resource_id,
63 close_icon_resource_id);
64 } 60 }
65 61
66 void ReaderModeSceneLayer::Update( 62 void ReaderModeSceneLayer::Update(
67 JNIEnv* env, 63 JNIEnv* env,
68 const JavaParamRef<jobject>& object, 64 const JavaParamRef<jobject>& object,
69 jfloat dp_to_px, 65 jfloat dp_to_px,
70 jfloat base_page_brightness, 66 jfloat base_page_brightness,
71 jfloat base_page_offset, 67 jfloat base_page_offset,
72 const JavaParamRef<jobject>& jweb_contents, 68 const JavaParamRef<jobject>& jweb_contents,
73 jfloat panel_X, 69 jfloat panel_X,
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
155 ReaderModeSceneLayer* reader_mode_scene_layer = 151 ReaderModeSceneLayer* reader_mode_scene_layer =
156 new ReaderModeSceneLayer(env, jobj); 152 new ReaderModeSceneLayer(env, jobj);
157 return reinterpret_cast<intptr_t>(reader_mode_scene_layer); 153 return reinterpret_cast<intptr_t>(reader_mode_scene_layer);
158 } 154 }
159 155
160 bool RegisterReaderModeSceneLayer(JNIEnv* env) { 156 bool RegisterReaderModeSceneLayer(JNIEnv* env) {
161 return RegisterNativesImpl(env); 157 return RegisterNativesImpl(env);
162 } 158 }
163 159
164 } // namespace android 160 } // namespace android
OLDNEW
« no previous file with comments | « chrome/browser/android/compositor/scene_layer/contextual_search_scene_layer.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698