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

Side by Side Diff: ash/wm/power_button_controller.h

Issue 2190773002: Fix Volume slider is captured in screenshot done in touchview mode (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: several updates included Created 4 years, 4 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 #ifndef ASH_WM_POWER_BUTTON_CONTROLLER_H_ 5 #ifndef ASH_WM_POWER_BUTTON_CONTROLLER_H_
6 #define ASH_WM_POWER_BUTTON_CONTROLLER_H_ 6 #define ASH_WM_POWER_BUTTON_CONTROLLER_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "base/time/time.h" 10 #include "base/time/time.h"
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 private: 80 private:
81 friend class test::PowerButtonControllerTest; 81 friend class test::PowerButtonControllerTest;
82 82
83 // Are the power or lock buttons currently held? 83 // Are the power or lock buttons currently held?
84 bool power_button_down_; 84 bool power_button_down_;
85 bool lock_button_down_; 85 bool lock_button_down_;
86 86
87 // True when the volume down button is being held down. 87 // True when the volume down button is being held down.
88 bool volume_down_pressed_; 88 bool volume_down_pressed_;
89 89
90 #if defined(OS_CHROMEOS)
91 // Volume to be restored after a maximize mode screenshot.
Daniel Erat 2016/08/01 21:10:06 nit: i wouldn't mention maximize mode here (this a
Qiang(Joe) Xu 2016/08/01 22:56:48 Done.
92 int volume_percent_before_screenshot_;
93 #endif
94
90 // Has the screen brightness been reduced to 0%? 95 // Has the screen brightness been reduced to 0%?
91 bool brightness_is_zero_; 96 bool brightness_is_zero_;
92 97
93 // True if an internal display is off while an external display is on (e.g. 98 // True if an internal display is off while an external display is on (e.g.
94 // for Chrome OS's docked mode, where a Chromebook's lid is closed while an 99 // for Chrome OS's docked mode, where a Chromebook's lid is closed while an
95 // external display is connected). 100 // external display is connected).
96 bool internal_display_off_and_external_display_on_; 101 bool internal_display_off_and_external_display_on_;
97 102
98 // Was a command-line switch set telling us that we're running on hardware 103 // Was a command-line switch set telling us that we're running on hardware
99 // that misreports power button releases? 104 // that misreports power button releases?
100 bool has_legacy_power_button_; 105 bool has_legacy_power_button_;
101 106
102 // Enables quick, non-cancellable locking of the screen when in maximize mode. 107 // Enables quick, non-cancellable locking of the screen when in maximize mode.
103 bool enable_quick_lock_; 108 bool enable_quick_lock_;
104 109
105 LockStateController* controller_; // Not owned. 110 LockStateController* controller_; // Not owned.
106 111
107 DISALLOW_COPY_AND_ASSIGN(PowerButtonController); 112 DISALLOW_COPY_AND_ASSIGN(PowerButtonController);
108 }; 113 };
109 114
110 } // namespace ash 115 } // namespace ash
111 116
112 #endif // ASH_WM_POWER_BUTTON_CONTROLLER_H_ 117 #endif // ASH_WM_POWER_BUTTON_CONTROLLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698