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

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

Issue 2758023002: Enable overlay scrollbars on ChromeOS (Closed)
Patch Set: Created 3 years, 9 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 | « no previous file | 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "base/command_line.h" 5 #include "base/command_line.h"
6 #include "ui/native_theme/native_theme_switches.h" 6 #include "ui/native_theme/native_theme_switches.h"
7 7
8 namespace switches { 8 namespace switches {
9 9
10 // Enables or disables overlay scrollbars in Blink (i.e. web content) on Aura 10 // Enables or disables overlay scrollbars in Blink (i.e. web content) on Aura
11 // or Linux. The status of native UI overlay scrollbars are determined in 11 // or Linux. The status of native UI overlay scrollbars are determined in
12 // PlatformStyle::CreateScrollBar. Does nothing on Mac. 12 // PlatformStyle::CreateScrollBar. Does nothing on Mac.
13 const char kEnableOverlayScrollbar[] = "enable-overlay-scrollbar"; 13 const char kEnableOverlayScrollbar[] = "enable-overlay-scrollbar";
14 const char kDisableOverlayScrollbar[] = "disable-overlay-scrollbar"; 14 const char kDisableOverlayScrollbar[] = "disable-overlay-scrollbar";
15 15
16 } // namespace switches 16 } // namespace switches
17 17
18 namespace ui { 18 namespace ui {
19 19
20 bool IsOverlayScrollbarEnabled() { 20 bool IsOverlayScrollbarEnabled() {
21 const base::CommandLine& command_line = 21 const base::CommandLine& command_line =
22 *base::CommandLine::ForCurrentProcess(); 22 *base::CommandLine::ForCurrentProcess();
23 23
24 if (command_line.HasSwitch(switches::kDisableOverlayScrollbar)) 24 if (command_line.HasSwitch(switches::kDisableOverlayScrollbar))
25 return false; 25 return false;
26 26
27 #if defined(OS_CHROMEOS)
28 return true;
29 #else
27 return command_line.HasSwitch(switches::kEnableOverlayScrollbar); 30 return command_line.HasSwitch(switches::kEnableOverlayScrollbar);
31 #endif
28 } 32 }
29 33
30 } // namespace ui 34 } // namespace ui
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698