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

Side by Side Diff: webkit/child/webfallbackthemeengine_impl.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
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/webfallbackthemeengine_impl.h" 5 #include "webkit/child/webfallbackthemeengine_impl.h"
6 6
7 #include "skia/ext/platform_canvas.h" 7 #include "skia/ext/platform_canvas.h"
8 #include "third_party/WebKit/public/platform/WebRect.h" 8 #include "third_party/WebKit/public/platform/WebRect.h"
9 #include "third_party/WebKit/public/platform/WebSize.h" 9 #include "third_party/WebKit/public/platform/WebSize.h"
10 #include "ui/native_theme/fallback_theme.h" 10 #include "ui/native_theme/fallback_theme.h"
11 11
12 using WebKit::WebCanvas; 12 using blink::WebCanvas;
13 using WebKit::WebColor; 13 using blink::WebColor;
14 using WebKit::WebRect; 14 using blink::WebRect;
15 using WebKit::WebFallbackThemeEngine; 15 using blink::WebFallbackThemeEngine;
16 16
17 namespace webkit_glue { 17 namespace webkit_glue {
18 18
19 static ui::NativeTheme::Part NativeThemePart( 19 static ui::NativeTheme::Part NativeThemePart(
20 WebFallbackThemeEngine::Part part) { 20 WebFallbackThemeEngine::Part part) {
21 switch (part) { 21 switch (part) {
22 case WebFallbackThemeEngine::PartScrollbarDownArrow: 22 case WebFallbackThemeEngine::PartScrollbarDownArrow:
23 return ui::NativeTheme::kScrollbarDownArrow; 23 return ui::NativeTheme::kScrollbarDownArrow;
24 case WebFallbackThemeEngine::PartScrollbarLeftArrow: 24 case WebFallbackThemeEngine::PartScrollbarLeftArrow:
25 return ui::NativeTheme::kScrollbarLeftArrow; 25 return ui::NativeTheme::kScrollbarLeftArrow;
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
157 break; // Parts that have no extra params get here. 157 break; // Parts that have no extra params get here.
158 } 158 }
159 } 159 }
160 160
161 WebFallbackThemeEngineImpl::WebFallbackThemeEngineImpl() 161 WebFallbackThemeEngineImpl::WebFallbackThemeEngineImpl()
162 : theme_(new ui::FallbackTheme()) { 162 : theme_(new ui::FallbackTheme()) {
163 } 163 }
164 164
165 WebFallbackThemeEngineImpl::~WebFallbackThemeEngineImpl() {} 165 WebFallbackThemeEngineImpl::~WebFallbackThemeEngineImpl() {}
166 166
167 WebKit::WebSize WebFallbackThemeEngineImpl::getSize( 167 blink::WebSize WebFallbackThemeEngineImpl::getSize(
168 WebFallbackThemeEngine::Part part) { 168 WebFallbackThemeEngine::Part part) {
169 ui::NativeTheme::ExtraParams extra; 169 ui::NativeTheme::ExtraParams extra;
170 return theme_->GetPartSize(NativeThemePart(part), 170 return theme_->GetPartSize(NativeThemePart(part),
171 ui::NativeTheme::kNormal, 171 ui::NativeTheme::kNormal,
172 extra); 172 extra);
173 } 173 }
174 174
175 void WebFallbackThemeEngineImpl::paint( 175 void WebFallbackThemeEngineImpl::paint(
176 WebKit::WebCanvas* canvas, 176 blink::WebCanvas* canvas,
177 WebFallbackThemeEngine::Part part, 177 WebFallbackThemeEngine::Part part,
178 WebFallbackThemeEngine::State state, 178 WebFallbackThemeEngine::State state,
179 const WebKit::WebRect& rect, 179 const blink::WebRect& rect,
180 const WebFallbackThemeEngine::ExtraParams* extra_params) { 180 const WebFallbackThemeEngine::ExtraParams* extra_params) {
181 ui::NativeTheme::ExtraParams native_theme_extra_params; 181 ui::NativeTheme::ExtraParams native_theme_extra_params;
182 GetNativeThemeExtraParams( 182 GetNativeThemeExtraParams(
183 part, state, extra_params, &native_theme_extra_params); 183 part, state, extra_params, &native_theme_extra_params);
184 theme_->Paint(canvas, 184 theme_->Paint(canvas,
185 NativeThemePart(part), 185 NativeThemePart(part),
186 NativeThemeState(state), 186 NativeThemeState(state),
187 gfx::Rect(rect), 187 gfx::Rect(rect),
188 native_theme_extra_params); 188 native_theme_extra_params);
189 } 189 }
190 190
191 } // namespace webkit_glue 191 } // namespace webkit_glue
OLDNEW
« no previous file with comments | « webkit/child/webfallbackthemeengine_impl.h ('k') | webkit/child/webkitplatformsupport_child_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698