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

Side by Side Diff: chromeos/audio/cras_audio_handler.h

Issue 163953007: Refactor the TrayAudio code so that it can be used by other platforms. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix memory leak by using scoped_ptr in TrayAudio Created 6 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 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_ 5 #ifndef CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_
6 #define CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_ 6 #define CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_
7 7
8 #include <queue> 8 #include <queue>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 92
93 // Returns true if audio input is muted. 93 // Returns true if audio input is muted.
94 virtual bool IsInputMuted(); 94 virtual bool IsInputMuted();
95 95
96 // Returns true if audio input is muted for a device. 96 // Returns true if audio input is muted for a device.
97 virtual bool IsInputMutedForDevice(uint64 device_id); 97 virtual bool IsInputMutedForDevice(uint64 device_id);
98 98
99 // Returns true if the output volume is below the default mute volume level. 99 // Returns true if the output volume is below the default mute volume level.
100 virtual bool IsOutputVolumeBelowDefaultMuteLvel(); 100 virtual bool IsOutputVolumeBelowDefaultMuteLvel();
101 101
102 // Returns volume level in 0-100% range at which the volume should be muted.
103 virtual int GetOutputDefaultVolumeMuteThreshold();
104
102 // Gets volume level in 0-100% range (0 being pure silence) for the current 105 // Gets volume level in 0-100% range (0 being pure silence) for the current
103 // active node. 106 // active node.
104 virtual int GetOutputVolumePercent(); 107 virtual int GetOutputVolumePercent();
105 108
106 // Gets volume level in 0-100% range (0 being pure silence) for a device. 109 // Gets volume level in 0-100% range (0 being pure silence) for a device.
107 virtual int GetOutputVolumePercentForDevice(uint64 device_id); 110 virtual int GetOutputVolumePercentForDevice(uint64 device_id);
108 111
109 // Gets gain level in 0-100% range (0 being pure silence) for the current 112 // Gets gain level in 0-100% range (0 being pure silence) for the current
110 // active node. 113 // active node.
111 virtual int GetInputGainPercent(); 114 virtual int GetInputGainPercent();
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
268 271
269 // Failures are not logged at startup, since CRAS may not be running yet. 272 // Failures are not logged at startup, since CRAS may not be running yet.
270 bool log_errors_; 273 bool log_errors_;
271 274
272 DISALLOW_COPY_AND_ASSIGN(CrasAudioHandler); 275 DISALLOW_COPY_AND_ASSIGN(CrasAudioHandler);
273 }; 276 };
274 277
275 } // namespace chromeos 278 } // namespace chromeos
276 279
277 #endif // CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_ 280 #endif // CHROMEOS_AUDIO_CRAS_AUDIO_HANDLER_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/ash/system_tray_delegate_chromeos.cc ('k') | chromeos/audio/cras_audio_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698