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

Unified Diff: Source/modules/mediastream/RTCPeerConnection.h

Issue 27571005: Replace Timers used in ActiveDOMObject with AsyncMethodRunner (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 7 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 | « Source/modules/mediasource/SourceBuffer.cpp ('k') | Source/modules/mediastream/RTCPeerConnection.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/mediastream/RTCPeerConnection.h
diff --git a/Source/modules/mediastream/RTCPeerConnection.h b/Source/modules/mediastream/RTCPeerConnection.h
index c00323bcb8ef442c4967136fd3ee663f3a71c2aa..2cf1a119714e2a5e0206d99f6f4adfd3a755c3f5 100644
--- a/Source/modules/mediastream/RTCPeerConnection.h
+++ b/Source/modules/mediastream/RTCPeerConnection.h
@@ -39,7 +39,7 @@
#include "core/platform/mediastream/RTCPeerConnectionHandlerClient.h"
#include "modules/mediastream/MediaStream.h"
#include "modules/mediastream/RTCIceCandidate.h"
-#include "platform/Timer.h"
+#include "platform/AsyncMethodRunner.h"
#include "wtf/RefCounted.h"
namespace WebCore {
@@ -126,6 +126,8 @@ public:
virtual ExecutionContext* executionContext() const OVERRIDE;
// ActiveDOMObject
+ virtual void suspend() OVERRIDE;
+ virtual void resume() OVERRIDE;
virtual void stop() OVERRIDE;
virtual bool hasPendingActivity() const OVERRIDE { return !m_stopped; }
@@ -134,7 +136,7 @@ private:
static PassRefPtr<RTCConfiguration> parseConfiguration(const Dictionary& configuration, ExceptionState&);
void scheduleDispatchEvent(PassRefPtr<Event>);
- void scheduledEventTimerFired(Timer<RTCPeerConnection>*);
+ void dispatchScheduledEvent();
bool hasLocalStreamWithTrackId(const String& trackId);
void changeSignalingState(SignalingState);
@@ -152,7 +154,7 @@ private:
OwnPtr<RTCPeerConnectionHandler> m_peerHandler;
- Timer<RTCPeerConnection> m_scheduledEventTimer;
+ AsyncMethodRunner<RTCPeerConnection> m_dispatchScheduledEventRunner;
Vector<RefPtr<Event> > m_scheduledEvents;
bool m_stopped;
« no previous file with comments | « Source/modules/mediasource/SourceBuffer.cpp ('k') | Source/modules/mediastream/RTCPeerConnection.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698