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

Unified Diff: media/audio/audio_manager_base.h

Issue 14265014: Refactor android specific code in AudioManagerBase class. (Closed) Base URL: https://src.chromium.org/svn/trunk/src/
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
Index: media/audio/audio_manager_base.h
===================================================================
--- media/audio/audio_manager_base.h (revision 194203)
+++ media/audio/audio_manager_base.h (working copy)
@@ -20,10 +20,6 @@
#include "base/win/scoped_com_initializer.h"
#endif
-#if defined(OS_ANDROID)
-#include "base/android/jni_android.h"
-#endif
-
namespace base {
class Thread;
}
@@ -97,10 +93,6 @@
virtual AudioParameters GetInputStreamParameters(
const std::string& device_id) OVERRIDE;
-#if defined(OS_ANDROID)
- static bool RegisterAudioManager(JNIEnv* env);
-#endif
-
protected:
AudioManagerBase();
@@ -136,16 +128,14 @@
// from the audio thread (no locking).
AudioOutputDispatchersMap output_dispatchers_;
+ // Get number of input or output streams.
+ int GetNumInputStreams();
DaleCurtis 2013/04/15 21:02:30 Since these aren't virtual you can just hacker_sty
leozwang1 2013/04/15 21:12:15 Done.
+ int GetNumOutputStreams();
+
private:
// Called by Shutdown().
void ShutdownOnAudioThread();
-#if defined(OS_ANDROID)
- void SetAudioMode(int mode);
- void RegisterHeadsetReceiver();
- void UnregisterHeadsetReceiver();
-#endif
-
// Counts the number of active input streams to find out if something else
// is currently recording in Chrome.
base::AtomicRefCount num_active_input_streams_;
@@ -175,11 +165,6 @@
// and GetMessageLoop() starts returning NULL.
scoped_refptr<base::MessageLoopProxy> message_loop_;
-#if defined(OS_ANDROID)
- // Java AudioManager instance.
- base::android::ScopedJavaGlobalRef<jobject> j_audio_manager_;
-#endif
-
DISALLOW_COPY_AND_ASSIGN(AudioManagerBase);
};

Powered by Google App Engine
This is Rietveld 408576698