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

Side by Side Diff: Source/core/layout/LayoutThemeChromiumSkia.cpp

Issue 894393003: Constify and use reference for RenderStyle in LayoutTheme (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 10 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2007 Apple Inc. 2 * Copyright (C) 2007 Apple Inc.
3 * Copyright (C) 2007 Alp Toker <alp@atoker.com> 3 * Copyright (C) 2007 Alp Toker <alp@atoker.com>
4 * Copyright (C) 2008 Collabora Ltd. 4 * Copyright (C) 2008 Collabora Ltd.
5 * Copyright (C) 2008, 2009 Google Inc. 5 * Copyright (C) 2008, 2009 Google Inc.
6 * 6 *
7 * This library is free software; you can redistribute it and/or 7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Library General Public 8 * modify it under the terms of the GNU Library General Public
9 * License as published by the Free Software Foundation; either 9 * License as published by the Free Software Foundation; either
10 * version 2 of the License, or (at your option) any later version. 10 * version 2 of the License, or (at your option) any later version.
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 loadResourceAsASCIIString("themeWin.css") + 73 loadResourceAsASCIIString("themeWin.css") +
74 loadResourceAsASCIIString("themeChromiumSkia.css") + 74 loadResourceAsASCIIString("themeChromiumSkia.css") +
75 loadResourceAsASCIIString("themeChromium.css"); 75 loadResourceAsASCIIString("themeChromium.css");
76 } 76 }
77 77
78 String LayoutThemeChromiumSkia::extraQuirksStyleSheet() 78 String LayoutThemeChromiumSkia::extraQuirksStyleSheet()
79 { 79 {
80 return loadResourceAsASCIIString("themeWinQuirks.css"); 80 return loadResourceAsASCIIString("themeWinQuirks.css");
81 } 81 }
82 82
83 bool LayoutThemeChromiumSkia::supportsHover(const RenderStyle* style) const 83 bool LayoutThemeChromiumSkia::supportsHover(const RenderStyle& style) const
84 { 84 {
85 return true; 85 return true;
86 } 86 }
87 87
88 bool LayoutThemeChromiumSkia::supportsFocusRing(const RenderStyle* style) const 88 bool LayoutThemeChromiumSkia::supportsFocusRing(const RenderStyle& style) const
89 { 89 {
90 // This causes WebKit to draw the focus rings for us. 90 // This causes WebKit to draw the focus rings for us.
91 return false; 91 return false;
92 } 92 }
93 93
94 Color LayoutThemeChromiumSkia::platformActiveSelectionBackgroundColor() const 94 Color LayoutThemeChromiumSkia::platformActiveSelectionBackgroundColor() const
95 { 95 {
96 return Color(0x1e, 0x90, 0xff); 96 return Color(0x1e, 0x90, 0xff);
97 } 97 }
98 98
(...skipping 26 matching lines...) Expand all
125 return 0; 125 return 0;
126 126
127 return caretBlinkIntervalInternal(); 127 return caretBlinkIntervalInternal();
128 } 128 }
129 129
130 void LayoutThemeChromiumSkia::systemFont(CSSValueID systemFontID, FontStyle& fon tStyle, FontWeight& fontWeight, float& fontSize, AtomicString& fontFamily) const 130 void LayoutThemeChromiumSkia::systemFont(CSSValueID systemFontID, FontStyle& fon tStyle, FontWeight& fontWeight, float& fontSize, AtomicString& fontFamily) const
131 { 131 {
132 LayoutThemeChromiumFontProvider::systemFont(systemFontID, fontStyle, fontWei ght, fontSize, fontFamily); 132 LayoutThemeChromiumFontProvider::systemFont(systemFontID, fontStyle, fontWei ght, fontSize, fontFamily);
133 } 133 }
134 134
135 int LayoutThemeChromiumSkia::minimumMenuListSize(RenderStyle* style) const 135 int LayoutThemeChromiumSkia::minimumMenuListSize(const RenderStyle& style) const
136 { 136 {
137 return 0; 137 return 0;
138 } 138 }
139 139
140 // These are the default dimensions of radio buttons and checkboxes. 140 // These are the default dimensions of radio buttons and checkboxes.
141 static const int widgetStandardWidth = 13; 141 static const int widgetStandardWidth = 13;
142 static const int widgetStandardHeight = 13; 142 static const int widgetStandardHeight = 13;
143 143
144 // Return a rectangle that has the same center point as |original|, but with a 144 // Return a rectangle that has the same center point as |original|, but with a
145 // size capped at |width| by |height|. 145 // size capped at |width| by |height|.
146 IntRect center(const IntRect& original, int width, int height) 146 IntRect center(const IntRect& original, int width, int height)
147 { 147 {
148 width = std::min(original.width(), width); 148 width = std::min(original.width(), width);
149 height = std::min(original.height(), height); 149 height = std::min(original.height(), height);
150 int x = original.x() + (original.width() - width) / 2; 150 int x = original.x() + (original.width() - width) / 2;
151 int y = original.y() + (original.height() - height) / 2; 151 int y = original.y() + (original.height() - height) / 2;
152 152
153 return IntRect(x, y, width, height); 153 return IntRect(x, y, width, height);
154 } 154 }
155 155
156 void LayoutThemeChromiumSkia::setCheckboxSize(RenderStyle* style) const 156 void LayoutThemeChromiumSkia::setCheckboxSize(RenderStyle& style) const
157 { 157 {
158 // If the width and height are both specified, then we have nothing to do. 158 // If the width and height are both specified, then we have nothing to do.
159 if (!style->width().isIntrinsicOrAuto() && !style->height().isAuto()) 159 if (!style.width().isIntrinsicOrAuto() && !style.height().isAuto())
160 return; 160 return;
161 161
162 // FIXME: A hard-coded size of 13 is used. This is wrong but necessary 162 // FIXME: A hard-coded size of 13 is used. This is wrong but necessary
163 // for now. It matches Firefox. At different DPI settings on Windows, 163 // for now. It matches Firefox. At different DPI settings on Windows,
164 // querying the theme gives you a larger size that accounts for the higher 164 // querying the theme gives you a larger size that accounts for the higher
165 // DPI. Until our entire engine honors a DPI setting other than 96, we 165 // DPI. Until our entire engine honors a DPI setting other than 96, we
166 // can't rely on the theme's metrics. 166 // can't rely on the theme's metrics.
167 const IntSize size(widgetStandardWidth, widgetStandardHeight); 167 const IntSize size(widgetStandardWidth, widgetStandardHeight);
168 setSizeIfAuto(style, size); 168 setSizeIfAuto(style, size);
169 } 169 }
170 170
171 void LayoutThemeChromiumSkia::setRadioSize(RenderStyle* style) const 171 void LayoutThemeChromiumSkia::setRadioSize(RenderStyle& style) const
172 { 172 {
173 // Use same sizing for radio box as checkbox. 173 // Use same sizing for radio box as checkbox.
174 setCheckboxSize(style); 174 setCheckboxSize(style);
175 } 175 }
176 176
177 void LayoutThemeChromiumSkia::adjustButtonStyle(RenderStyle* style, Element*) co nst 177 void LayoutThemeChromiumSkia::adjustButtonStyle(RenderStyle& style, Element*) co nst
178 { 178 {
179 if (style->appearance() == PushButtonPart) { 179 if (style.appearance() == PushButtonPart) {
180 // Ignore line-height. 180 // Ignore line-height.
181 style->setLineHeight(RenderStyle::initialLineHeight()); 181 style.setLineHeight(RenderStyle::initialLineHeight());
182 } 182 }
183 } 183 }
184 184
185 bool LayoutThemeChromiumSkia::paintTextArea(RenderObject* o, const PaintInfo& i, const IntRect& r) 185 bool LayoutThemeChromiumSkia::paintTextArea(RenderObject* o, const PaintInfo& i, const IntRect& r)
186 { 186 {
187 return paintTextField(o, i, r); 187 return paintTextField(o, i, r);
188 } 188 }
189 189
190 void LayoutThemeChromiumSkia::adjustSearchFieldStyle(RenderStyle* style, Element *) const 190 void LayoutThemeChromiumSkia::adjustSearchFieldStyle(RenderStyle& style, Element *) const
191 { 191 {
192 // Ignore line-height. 192 // Ignore line-height.
193 style->setLineHeight(RenderStyle::initialLineHeight()); 193 style.setLineHeight(RenderStyle::initialLineHeight());
194 } 194 }
195 195
196 bool LayoutThemeChromiumSkia::paintSearchField(RenderObject* o, const PaintInfo& i, const IntRect& r) 196 bool LayoutThemeChromiumSkia::paintSearchField(RenderObject* o, const PaintInfo& i, const IntRect& r)
197 { 197 {
198 return paintTextField(o, i, r); 198 return paintTextField(o, i, r);
199 } 199 }
200 200
201 void LayoutThemeChromiumSkia::adjustSearchFieldCancelButtonStyle(RenderStyle* st yle, Element*) const 201 void LayoutThemeChromiumSkia::adjustSearchFieldCancelButtonStyle(RenderStyle& st yle, Element*) const
202 { 202 {
203 // Scale the button size based on the font size 203 // Scale the button size based on the font size
204 float fontScale = style->fontSize() / defaultControlFontPixelSize; 204 float fontScale = style.fontSize() / defaultControlFontPixelSize;
205 int cancelButtonSize = lroundf(std::min(std::max(minCancelButtonSize, defaul tCancelButtonSize * fontScale), maxCancelButtonSize)); 205 int cancelButtonSize = lroundf(std::min(std::max(minCancelButtonSize, defaul tCancelButtonSize * fontScale), maxCancelButtonSize));
206 style->setWidth(Length(cancelButtonSize, Fixed)); 206 style.setWidth(Length(cancelButtonSize, Fixed));
207 style->setHeight(Length(cancelButtonSize, Fixed)); 207 style.setHeight(Length(cancelButtonSize, Fixed));
208 } 208 }
209 209
210 IntRect LayoutThemeChromiumSkia::convertToPaintingRect(RenderObject* inputRender er, const RenderObject* partRenderer, LayoutRect partRect, const IntRect& localO ffset) const 210 IntRect LayoutThemeChromiumSkia::convertToPaintingRect(RenderObject* inputRender er, const RenderObject* partRenderer, LayoutRect partRect, const IntRect& localO ffset) const
211 { 211 {
212 // Compute an offset between the part renderer and the input renderer. 212 // Compute an offset between the part renderer and the input renderer.
213 LayoutSize offsetFromInputRenderer = -partRenderer->offsetFromAncestorContai ner(inputRenderer); 213 LayoutSize offsetFromInputRenderer = -partRenderer->offsetFromAncestorContai ner(inputRenderer);
214 // Move the rect into partRenderer's coords. 214 // Move the rect into partRenderer's coords.
215 partRect.move(offsetFromInputRenderer); 215 partRect.move(offsetFromInputRenderer);
216 // Account for the local drawing offset. 216 // Account for the local drawing offset.
217 partRect.move(localOffset.x(), localOffset.y()); 217 partRect.move(localOffset.x(), localOffset.y());
(...skipping 22 matching lines...) Expand all
240 inputContentBox.y() + (inputContentBox.height() - cancelButtonSize + 1) / 2, 240 inputContentBox.y() + (inputContentBox.height() - cancelButtonSize + 1) / 2,
241 cancelButtonSize, cancelButtonSize); 241 cancelButtonSize, cancelButtonSize);
242 IntRect paintingRect = convertToPaintingRect(inputRenderBox, cancelButtonObj ect, cancelButtonRect, r); 242 IntRect paintingRect = convertToPaintingRect(inputRenderBox, cancelButtonObj ect, cancelButtonRect, r);
243 243
244 DEFINE_STATIC_REF(Image, cancelImage, (Image::loadPlatformResource("searchCa ncel"))); 244 DEFINE_STATIC_REF(Image, cancelImage, (Image::loadPlatformResource("searchCa ncel")));
245 DEFINE_STATIC_REF(Image, cancelPressedImage, (Image::loadPlatformResource("s earchCancelPressed"))); 245 DEFINE_STATIC_REF(Image, cancelPressedImage, (Image::loadPlatformResource("s earchCancelPressed")));
246 paintInfo.context->drawImage(isPressed(cancelButtonObject) ? cancelPressedIm age : cancelImage, paintingRect); 246 paintInfo.context->drawImage(isPressed(cancelButtonObject) ? cancelPressedIm age : cancelImage, paintingRect);
247 return false; 247 return false;
248 } 248 }
249 249
250 void LayoutThemeChromiumSkia::adjustSearchFieldDecorationStyle(RenderStyle* styl e, Element*) const 250 void LayoutThemeChromiumSkia::adjustSearchFieldDecorationStyle(RenderStyle& styl e, Element*) const
251 { 251 {
252 IntSize emptySize(1, 11); 252 IntSize emptySize(1, 11);
253 style->setWidth(Length(emptySize.width(), Fixed)); 253 style.setWidth(Length(emptySize.width(), Fixed));
254 style->setHeight(Length(emptySize.height(), Fixed)); 254 style.setHeight(Length(emptySize.height(), Fixed));
255 } 255 }
256 256
257 void LayoutThemeChromiumSkia::adjustSearchFieldResultsDecorationStyle(RenderStyl e* style, Element*) const 257 void LayoutThemeChromiumSkia::adjustSearchFieldResultsDecorationStyle(RenderStyl e& style, Element*) const
258 { 258 {
259 // Scale the decoration size based on the font size 259 // Scale the decoration size based on the font size
260 float fontScale = style->fontSize() / defaultControlFontPixelSize; 260 float fontScale = style.fontSize() / defaultControlFontPixelSize;
261 int magnifierSize = lroundf(std::min(std::max(minSearchFieldResultsDecoratio nSize, defaultSearchFieldResultsDecorationSize * fontScale), 261 int magnifierSize = lroundf(std::min(std::max(minSearchFieldResultsDecoratio nSize, defaultSearchFieldResultsDecorationSize * fontScale),
262 maxSearchFieldResultsDecorationSize)); 262 maxSearchFieldResultsDecorationSize));
263 style->setWidth(Length(magnifierSize, Fixed)); 263 style.setWidth(Length(magnifierSize, Fixed));
264 style->setHeight(Length(magnifierSize, Fixed)); 264 style.setHeight(Length(magnifierSize, Fixed));
265 } 265 }
266 266
267 bool LayoutThemeChromiumSkia::paintSearchFieldResultsDecoration(RenderObject* ma gnifierObject, const PaintInfo& paintInfo, const IntRect& r) 267 bool LayoutThemeChromiumSkia::paintSearchFieldResultsDecoration(RenderObject* ma gnifierObject, const PaintInfo& paintInfo, const IntRect& r)
268 { 268 {
269 // Get the renderer of <input> element. 269 // Get the renderer of <input> element.
270 if (!magnifierObject->node()) 270 if (!magnifierObject->node())
271 return false; 271 return false;
272 Node* input = magnifierObject->node()->shadowHost(); 272 Node* input = magnifierObject->node()->shadowHost();
273 RenderObject* baseRenderer = input ? input->renderer() : magnifierObject; 273 RenderObject* baseRenderer = input ? input->renderer() : magnifierObject;
274 if (!baseRenderer->isBox()) 274 if (!baseRenderer->isBox())
(...skipping 19 matching lines...) Expand all
294 bool LayoutThemeChromiumSkia::paintMediaSliderTrack(RenderObject* object, const PaintInfo& paintInfo, const IntRect& rect) 294 bool LayoutThemeChromiumSkia::paintMediaSliderTrack(RenderObject* object, const PaintInfo& paintInfo, const IntRect& rect)
295 { 295 {
296 return RenderMediaControls::paintMediaControlsPart(MediaSlider, object, pain tInfo, rect); 296 return RenderMediaControls::paintMediaControlsPart(MediaSlider, object, pain tInfo, rect);
297 } 297 }
298 298
299 bool LayoutThemeChromiumSkia::paintMediaVolumeSliderTrack(RenderObject* object, const PaintInfo& paintInfo, const IntRect& rect) 299 bool LayoutThemeChromiumSkia::paintMediaVolumeSliderTrack(RenderObject* object, const PaintInfo& paintInfo, const IntRect& rect)
300 { 300 {
301 return RenderMediaControls::paintMediaControlsPart(MediaVolumeSlider, object , paintInfo, rect); 301 return RenderMediaControls::paintMediaControlsPart(MediaVolumeSlider, object , paintInfo, rect);
302 } 302 }
303 303
304 void LayoutThemeChromiumSkia::adjustSliderThumbSize(RenderStyle* style, Element* ) const 304 void LayoutThemeChromiumSkia::adjustSliderThumbSize(RenderStyle& style, Element* ) const
305 { 305 {
306 RenderMediaControls::adjustMediaSliderThumbSize(style); 306 RenderMediaControls::adjustMediaSliderThumbSize(style);
307 } 307 }
308 308
309 bool LayoutThemeChromiumSkia::paintMediaSliderThumb(RenderObject* object, const PaintInfo& paintInfo, const IntRect& rect) 309 bool LayoutThemeChromiumSkia::paintMediaSliderThumb(RenderObject* object, const PaintInfo& paintInfo, const IntRect& rect)
310 { 310 {
311 return RenderMediaControls::paintMediaControlsPart(MediaSliderThumb, object, paintInfo, rect); 311 return RenderMediaControls::paintMediaControlsPart(MediaSliderThumb, object, paintInfo, rect);
312 } 312 }
313 313
314 bool LayoutThemeChromiumSkia::paintMediaToggleClosedCaptionsButton(RenderObject* o, const PaintInfo& paintInfo, const IntRect& r) 314 bool LayoutThemeChromiumSkia::paintMediaToggleClosedCaptionsButton(RenderObject* o, const PaintInfo& paintInfo, const IntRect& r)
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
349 String LayoutThemeChromiumSkia::formatMediaControlsCurrentTime(float currentTime , float duration) const 349 String LayoutThemeChromiumSkia::formatMediaControlsCurrentTime(float currentTime , float duration) const
350 { 350 {
351 return RenderMediaControls::formatMediaControlsCurrentTime(currentTime, dura tion); 351 return RenderMediaControls::formatMediaControlsCurrentTime(currentTime, dura tion);
352 } 352 }
353 353
354 bool LayoutThemeChromiumSkia::paintMediaFullscreenButton(RenderObject* object, c onst PaintInfo& paintInfo, const IntRect& rect) 354 bool LayoutThemeChromiumSkia::paintMediaFullscreenButton(RenderObject* object, c onst PaintInfo& paintInfo, const IntRect& rect)
355 { 355 {
356 return RenderMediaControls::paintMediaControlsPart(MediaEnterFullscreenButto n, object, paintInfo, rect); 356 return RenderMediaControls::paintMediaControlsPart(MediaEnterFullscreenButto n, object, paintInfo, rect);
357 } 357 }
358 358
359 void LayoutThemeChromiumSkia::adjustMenuListStyle(RenderStyle* style, Element*) const 359 void LayoutThemeChromiumSkia::adjustMenuListStyle(RenderStyle& style, Element*) const
360 { 360 {
361 // Height is locked to auto on all browsers. 361 // Height is locked to auto on all browsers.
362 style->setLineHeight(RenderStyle::initialLineHeight()); 362 style.setLineHeight(RenderStyle::initialLineHeight());
363 } 363 }
364 364
365 void LayoutThemeChromiumSkia::adjustMenuListButtonStyle(RenderStyle* style, Elem ent* e) const 365 void LayoutThemeChromiumSkia::adjustMenuListButtonStyle(RenderStyle& style, Elem ent* e) const
366 { 366 {
367 adjustMenuListStyle(style, e); 367 adjustMenuListStyle(style, e);
368 } 368 }
369 369
370 // Used to paint styled menulists (i.e. with a non-default border) 370 // Used to paint styled menulists (i.e. with a non-default border)
371 bool LayoutThemeChromiumSkia::paintMenuListButton(RenderObject* o, const PaintIn fo& i, const IntRect& rect) 371 bool LayoutThemeChromiumSkia::paintMenuListButton(RenderObject* o, const PaintIn fo& i, const IntRect& rect)
372 { 372 {
373 return paintMenuList(o, i, rect); 373 return paintMenuList(o, i, rect);
374 } 374 }
375 375
376 int LayoutThemeChromiumSkia::popupInternalPaddingLeft(RenderStyle* style) const 376 int LayoutThemeChromiumSkia::popupInternalPaddingLeft(const RenderStyle& style) const
377 { 377 {
378 return menuListInternalPadding(style, LeftPadding); 378 return menuListInternalPadding(style, LeftPadding);
379 } 379 }
380 380
381 int LayoutThemeChromiumSkia::popupInternalPaddingRight(RenderStyle* style) const 381 int LayoutThemeChromiumSkia::popupInternalPaddingRight(const RenderStyle& style) const
382 { 382 {
383 return menuListInternalPadding(style, RightPadding); 383 return menuListInternalPadding(style, RightPadding);
384 } 384 }
385 385
386 int LayoutThemeChromiumSkia::popupInternalPaddingTop(RenderStyle* style) const 386 int LayoutThemeChromiumSkia::popupInternalPaddingTop(const RenderStyle& style) c onst
387 { 387 {
388 return menuListInternalPadding(style, TopPadding); 388 return menuListInternalPadding(style, TopPadding);
389 } 389 }
390 390
391 int LayoutThemeChromiumSkia::popupInternalPaddingBottom(RenderStyle* style) cons t 391 int LayoutThemeChromiumSkia::popupInternalPaddingBottom(const RenderStyle& style ) const
392 { 392 {
393 return menuListInternalPadding(style, BottomPadding); 393 return menuListInternalPadding(style, BottomPadding);
394 } 394 }
395 395
396 // static 396 // static
397 void LayoutThemeChromiumSkia::setDefaultFontSize(int fontSize) 397 void LayoutThemeChromiumSkia::setDefaultFontSize(int fontSize)
398 { 398 {
399 LayoutThemeChromiumFontProvider::setDefaultFontSize(fontSize); 399 LayoutThemeChromiumFontProvider::setDefaultFontSize(fontSize);
400 } 400 }
401 401
402 double LayoutThemeChromiumSkia::caretBlinkIntervalInternal() const 402 double LayoutThemeChromiumSkia::caretBlinkIntervalInternal() const
403 { 403 {
404 return LayoutTheme::caretBlinkInterval(); 404 return LayoutTheme::caretBlinkInterval();
405 } 405 }
406 406
407 int LayoutThemeChromiumSkia::menuListArrowPadding() const 407 int LayoutThemeChromiumSkia::menuListArrowPadding() const
408 { 408 {
409 return ScrollbarTheme::theme()->scrollbarThickness(); 409 return ScrollbarTheme::theme()->scrollbarThickness();
410 } 410 }
411 411
412 int LayoutThemeChromiumSkia::menuListInternalPadding(RenderStyle* style, int pad dingType) const 412 int LayoutThemeChromiumSkia::menuListInternalPadding(const RenderStyle& style, i nt paddingType) const
413 { 413 {
414 // This internal padding is in addition to the user-supplied padding. 414 // This internal padding is in addition to the user-supplied padding.
415 // Matches the FF behavior. 415 // Matches the FF behavior.
416 int padding = styledMenuListInternalPadding[paddingType]; 416 int padding = styledMenuListInternalPadding[paddingType];
417 417
418 // Reserve the space for right arrow here. The rest of the padding is 418 // Reserve the space for right arrow here. The rest of the padding is
419 // set by adjustMenuListStyle, since PopMenuWin.cpp uses the padding from 419 // set by adjustMenuListStyle, since PopMenuWin.cpp uses the padding from
420 // RenderMenuList to lay out the individual items in the popup. 420 // RenderMenuList to lay out the individual items in the popup.
421 // If the MenuList actually has appearance "NoAppearance", then that means 421 // If the MenuList actually has appearance "NoAppearance", then that means
422 // we don't draw a button, so don't reserve space for it. 422 // we don't draw a button, so don't reserve space for it.
423 const int barType = style->direction() == LTR ? RightPadding : LeftPadding; 423 const int barType = style.direction() == LTR ? RightPadding : LeftPadding;
424 if (paddingType == barType && style->appearance() != NoControlPart) 424 if (paddingType == barType && style.appearance() != NoControlPart)
425 padding += menuListArrowPadding(); 425 padding += menuListArrowPadding();
426 426
427 return padding; 427 return padding;
428 } 428 }
429 429
430 bool LayoutThemeChromiumSkia::shouldShowPlaceholderWhenFocused() const 430 bool LayoutThemeChromiumSkia::shouldShowPlaceholderWhenFocused() const
431 { 431 {
432 return true; 432 return true;
433 } 433 }
434 434
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
486 } 486 }
487 487
488 LayoutThemeChromiumSkia::DirectionFlippingScope::~DirectionFlippingScope() 488 LayoutThemeChromiumSkia::DirectionFlippingScope::~DirectionFlippingScope()
489 { 489 {
490 if (!m_needsFlipping) 490 if (!m_needsFlipping)
491 return; 491 return;
492 m_paintInfo.context->restore(); 492 m_paintInfo.context->restore();
493 } 493 }
494 494
495 } // namespace blink 495 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698