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

Side by Side Diff: webkit/child/webthemeengine_impl_android.cc

Issue 61553006: Rename WebKit namespace to blink (part 5) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « webkit/child/webthemeengine_impl_android.h ('k') | webkit/child/webthemeengine_impl_default.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 "webkit/child/webthemeengine_impl_android.h" 5 #include "webkit/child/webthemeengine_impl_android.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "skia/ext/platform_canvas.h" 8 #include "skia/ext/platform_canvas.h"
9 #include "third_party/WebKit/public/platform/WebRect.h" 9 #include "third_party/WebKit/public/platform/WebRect.h"
10 #include "third_party/WebKit/public/platform/WebSize.h" 10 #include "third_party/WebKit/public/platform/WebSize.h"
11 #include "ui/native_theme/native_theme.h" 11 #include "ui/native_theme/native_theme.h"
12 12
13 using WebKit::WebCanvas; 13 using blink::WebCanvas;
14 using WebKit::WebColor; 14 using blink::WebColor;
15 using WebKit::WebRect; 15 using blink::WebRect;
16 using WebKit::WebThemeEngine; 16 using blink::WebThemeEngine;
17 17
18 namespace webkit_glue { 18 namespace webkit_glue {
19 19
20 static ui::NativeTheme::Part NativeThemePart( 20 static ui::NativeTheme::Part NativeThemePart(
21 WebThemeEngine::Part part) { 21 WebThemeEngine::Part part) {
22 switch (part) { 22 switch (part) {
23 case WebThemeEngine::PartScrollbarDownArrow: 23 case WebThemeEngine::PartScrollbarDownArrow:
24 return ui::NativeTheme::kScrollbarDownArrow; 24 return ui::NativeTheme::kScrollbarDownArrow;
25 case WebThemeEngine::PartScrollbarLeftArrow: 25 case WebThemeEngine::PartScrollbarLeftArrow:
26 return ui::NativeTheme::kScrollbarLeftArrow; 26 return ui::NativeTheme::kScrollbarLeftArrow;
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
154 native_theme_extra_params->progress_bar.value_rect_width = 154 native_theme_extra_params->progress_bar.value_rect_width =
155 extra_params->progressBar.valueRectWidth; 155 extra_params->progressBar.valueRectWidth;
156 native_theme_extra_params->progress_bar.value_rect_height = 156 native_theme_extra_params->progress_bar.value_rect_height =
157 extra_params->progressBar.valueRectHeight; 157 extra_params->progressBar.valueRectHeight;
158 break; 158 break;
159 default: 159 default:
160 break; // Parts that have no extra params get here. 160 break; // Parts that have no extra params get here.
161 } 161 }
162 } 162 }
163 163
164 WebKit::WebSize WebThemeEngineImpl::getSize(WebThemeEngine::Part part) { 164 blink::WebSize WebThemeEngineImpl::getSize(WebThemeEngine::Part part) {
165 ui::NativeTheme::ExtraParams extra; 165 ui::NativeTheme::ExtraParams extra;
166 return ui::NativeTheme::instance()->GetPartSize( 166 return ui::NativeTheme::instance()->GetPartSize(
167 NativeThemePart(part), ui::NativeTheme::kNormal, extra); 167 NativeThemePart(part), ui::NativeTheme::kNormal, extra);
168 } 168 }
169 169
170 void WebThemeEngineImpl::paint( 170 void WebThemeEngineImpl::paint(
171 WebKit::WebCanvas* canvas, 171 blink::WebCanvas* canvas,
172 WebThemeEngine::Part part, 172 WebThemeEngine::Part part,
173 WebThemeEngine::State state, 173 WebThemeEngine::State state,
174 const WebKit::WebRect& rect, 174 const blink::WebRect& rect,
175 const WebThemeEngine::ExtraParams* extra_params) { 175 const WebThemeEngine::ExtraParams* extra_params) {
176 ui::NativeTheme::ExtraParams native_theme_extra_params; 176 ui::NativeTheme::ExtraParams native_theme_extra_params;
177 GetNativeThemeExtraParams( 177 GetNativeThemeExtraParams(
178 part, state, extra_params, &native_theme_extra_params); 178 part, state, extra_params, &native_theme_extra_params);
179 ui::NativeTheme::instance()->Paint( 179 ui::NativeTheme::instance()->Paint(
180 canvas, 180 canvas,
181 NativeThemePart(part), 181 NativeThemePart(part),
182 NativeThemeState(state), 182 NativeThemeState(state),
183 gfx::Rect(rect), 183 gfx::Rect(rect),
184 native_theme_extra_params); 184 native_theme_extra_params);
185 } 185 }
186 } // namespace webkit_glue 186 } // namespace webkit_glue
OLDNEW
« no previous file with comments | « webkit/child/webthemeengine_impl_android.h ('k') | webkit/child/webthemeengine_impl_default.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698