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

Side by Side Diff: ui/native_theme/native_theme_aura.cc

Issue 2806263005: Convert the overlay scrollbar flag to use FeatureList (Closed)
Patch Set: add disable overlay scrollbar back to site_per_process_browsertest.cc 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
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 "ui/native_theme/native_theme_aura.h" 5 #include "ui/native_theme/native_theme_aura.h"
6 6
7 #include <limits> 7 #include <limits>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
11 #include "base/trace_event/trace_event.h" 11 #include "base/trace_event/trace_event.h"
12 #include "build/build_config.h" 12 #include "build/build_config.h"
13 #include "cc/paint/paint_canvas.h" 13 #include "cc/paint/paint_canvas.h"
14 #include "cc/paint/paint_flags.h" 14 #include "cc/paint/paint_flags.h"
15 #include "ui/base/layout.h" 15 #include "ui/base/layout.h"
16 #include "ui/base/material_design/material_design_controller.h" 16 #include "ui/base/material_design/material_design_controller.h"
17 #include "ui/gfx/animation/tween.h" 17 #include "ui/gfx/animation/tween.h"
18 #include "ui/gfx/canvas.h" 18 #include "ui/gfx/canvas.h"
19 #include "ui/gfx/color_palette.h" 19 #include "ui/gfx/color_palette.h"
20 #include "ui/gfx/geometry/insets.h" 20 #include "ui/gfx/geometry/insets.h"
21 #include "ui/gfx/geometry/rect.h" 21 #include "ui/gfx/geometry/rect.h"
22 #include "ui/gfx/geometry/size.h" 22 #include "ui/gfx/geometry/size.h"
23 #include "ui/gfx/image/image_skia.h" 23 #include "ui/gfx/image/image_skia.h"
24 #include "ui/gfx/path.h" 24 #include "ui/gfx/path.h"
25 #include "ui/gfx/skia_util.h" 25 #include "ui/gfx/skia_util.h"
26 #include "ui/native_theme/common_theme.h" 26 #include "ui/native_theme/common_theme.h"
27 #include "ui/native_theme/native_theme_switches.h" 27 #include "ui/native_theme/native_theme_features.h"
28 #include "ui/native_theme/overlay_scrollbar_constants_aura.h" 28 #include "ui/native_theme/overlay_scrollbar_constants_aura.h"
29 29
30 namespace ui { 30 namespace ui {
31 31
32 namespace { 32 namespace {
33 33
34 // Constants for painting overlay scrollbars. Other properties needed outside 34 // Constants for painting overlay scrollbars. Other properties needed outside
35 // this painting code are defined in overlay_scrollbar_constants_aura.h. 35 // this painting code are defined in overlay_scrollbar_constants_aura.h.
36 constexpr int kOverlayScrollbarStrokeWidth = 1; 36 constexpr int kOverlayScrollbarStrokeWidth = 1;
37 constexpr int kOverlayScrollbarMinimumLength = 32; 37 constexpr int kOverlayScrollbarMinimumLength = 32;
(...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after
350 350
351 gfx::Rect NativeThemeAura::GetNinePatchAperture(Part part) const { 351 gfx::Rect NativeThemeAura::GetNinePatchAperture(Part part) const {
352 DCHECK(SupportsNinePatch(part)); 352 DCHECK(SupportsNinePatch(part));
353 353
354 return gfx::Rect( 354 return gfx::Rect(
355 kOverlayScrollbarBorderPatchWidth, kOverlayScrollbarBorderPatchWidth, 355 kOverlayScrollbarBorderPatchWidth, kOverlayScrollbarBorderPatchWidth,
356 kOverlayScrollbarCenterPatchSize, kOverlayScrollbarCenterPatchSize); 356 kOverlayScrollbarCenterPatchSize, kOverlayScrollbarCenterPatchSize);
357 } 357 }
358 358
359 } // namespace ui 359 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698