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: chrome/browser/renderer_host/audio_renderer_host.h

Issue 342090: Use ChromeThread::DeleteOnIOThread in a few places where an object must be de... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 1 month 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 | chrome/browser/renderer_host/audio_renderer_host.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/renderer_host/audio_renderer_host.h
===================================================================
--- chrome/browser/renderer_host/audio_renderer_host.h (revision 30863)
+++ chrome/browser/renderer_host/audio_renderer_host.h (working copy)
@@ -74,6 +74,7 @@
#include "base/ref_counted.h"
#include "base/shared_memory.h"
#include "base/waitable_event.h"
+#include "chrome/browser/chrome_thread.h"
#include "ipc/ipc_message.h"
#include "media/audio/audio_output.h"
#include "media/audio/simple_sources.h"
@@ -82,15 +83,16 @@
class AudioManager;
struct ViewHostMsg_Audio_CreateStream;
-class AudioRendererHost : public base::RefCountedThreadSafe<AudioRendererHost> {
+class AudioRendererHost
+ : public base::RefCountedThreadSafe<
+ AudioRendererHost, ChromeThread::DeleteOnIOThread> {
private:
class IPCAudioSource;
public:
// Called from UI thread from the owner of this object.
AudioRendererHost();
- // Destruction can happen on either UI thread or IO thread, but at destruction
- // all associated sources are destroyed and streams are closed.
+ // Destruction always happens on the IO thread (see DeleteOnIOThread above).
virtual ~AudioRendererHost();
// Called from UI thread from the owner of this object to kick start
@@ -315,9 +317,6 @@
void OnNotifyPacketReady(const IPC::Message& msg, int stream_id,
size_t packet_size);
- // Called on IO thread when this object is created and initialized.
- void OnInitialized();
-
// Called on IO thread when this object needs to be destroyed and after
// Destroy() is called from owner of this class in UI thread.
void OnDestroyed();
« no previous file with comments | « no previous file | chrome/browser/renderer_host/audio_renderer_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698