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

Unified Diff: media/audio/audio_output_controller.h

Issue 8371013: Harden audio output controller making it safe to call Pause() before (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Created 9 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | media/audio/audio_output_controller.cc » ('j') | media/audio/audio_output_controller.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/audio/audio_output_controller.h
===================================================================
--- media/audio/audio_output_controller.h (revision 106670)
+++ media/audio/audio_output_controller.h (working copy)
@@ -55,16 +55,6 @@
: public base::RefCountedThreadSafe<AudioOutputController>,
public AudioOutputStream::AudioSourceCallback {
public:
- // Internal state of the source.
- enum State {
- kEmpty,
- kCreated,
- kPlaying,
- kPaused,
- kClosed,
- kError,
- };
-
// Value sent by the controller to the renderer in low-latency mode
// indicating that the stream is paused.
static const int kPauseMark;
@@ -169,6 +159,18 @@
uint32 max_size, AudioBuffersState buffers_state);
virtual void OnError(AudioOutputStream* stream, int code);
+ protected:
+ // Internal state of the source.
+ enum State {
+ kEmpty,
+ kCreated,
+ kPlaying,
+ kStarting,
+ kPaused,
+ kClosed,
+ kError,
+ };
+
private:
// We are polling sync reader if data became available.
static const int kPollNumAttempts;
« no previous file with comments | « no previous file | media/audio/audio_output_controller.cc » ('j') | media/audio/audio_output_controller.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698