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

Unified Diff: base/message_loop/message_pump_mac.h

Issue 17567007: Made MessagePump a non-thread safe class. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 7 years, 5 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: base/message_loop/message_pump_mac.h
diff --git a/base/message_loop/message_pump_mac.h b/base/message_loop/message_pump_mac.h
index 68c2a3d839395196b645fe9c18be5f257e481f7b..3dbeb3da60a7b922a576ec6b0c5eceacca4d947b 100644
--- a/base/message_loop/message_pump_mac.h
+++ b/base/message_loop/message_pump_mac.h
@@ -63,6 +63,7 @@ class MessagePumpCFRunLoopBase : public MessagePump {
friend class MessagePumpScopedAutoreleasePool;
public:
MessagePumpCFRunLoopBase();
+ virtual ~MessagePumpCFRunLoopBase();
// Subclasses should implement the work they need to do in MessagePump::Run
// in the DoRun method. MessagePumpCFRunLoopBase::Run calls DoRun directly.
@@ -75,8 +76,6 @@ class MessagePumpCFRunLoopBase : public MessagePump {
virtual void ScheduleDelayedWork(const TimeTicks& delayed_work_time) OVERRIDE;
protected:
- virtual ~MessagePumpCFRunLoopBase();
-
// Accessors for private data members to be used by subclasses.
CFRunLoopRef run_loop() const { return run_loop_; }
int nesting_level() const { return nesting_level_; }
@@ -199,13 +198,11 @@ class MessagePumpCFRunLoopBase : public MessagePump {
class MessagePumpCFRunLoop : public MessagePumpCFRunLoopBase {
public:
MessagePumpCFRunLoop();
+ virtual ~MessagePumpCFRunLoop();
virtual void DoRun(Delegate* delegate) OVERRIDE;
virtual void Quit() OVERRIDE;
- protected:
- virtual ~MessagePumpCFRunLoop();
-
private:
virtual void EnterExitRunLoop(CFRunLoopActivity activity) OVERRIDE;
@@ -220,13 +217,11 @@ class MessagePumpCFRunLoop : public MessagePumpCFRunLoopBase {
class MessagePumpNSRunLoop : public MessagePumpCFRunLoopBase {
public:
BASE_EXPORT MessagePumpNSRunLoop();
+ virtual ~MessagePumpNSRunLoop();
virtual void DoRun(Delegate* delegate) OVERRIDE;
virtual void Quit() OVERRIDE;
- protected:
- virtual ~MessagePumpNSRunLoop();
-
private:
// A source that doesn't do anything but provide something signalable
// attached to the run loop. This source will be signalled when Quit
@@ -246,6 +241,7 @@ class MessagePumpNSRunLoop : public MessagePumpCFRunLoopBase {
class MessagePumpUIApplication : public MessagePumpCFRunLoopBase {
public:
MessagePumpUIApplication();
+ virtual ~MessagePumpUIApplication();
virtual void DoRun(Delegate* delegate) OVERRIDE;
virtual void Quit() OVERRIDE;
@@ -253,9 +249,6 @@ class MessagePumpUIApplication : public MessagePumpCFRunLoopBase {
// call |Attach()| to set up a delegate. It is an error to call |Run()|.
virtual void Attach(Delegate* delegate);
- protected:
- virtual ~MessagePumpUIApplication();
-
private:
RunLoop* run_loop_;
@@ -267,13 +260,11 @@ class MessagePumpUIApplication : public MessagePumpCFRunLoopBase {
class MessagePumpNSApplication : public MessagePumpCFRunLoopBase {
public:
MessagePumpNSApplication();
+ virtual ~MessagePumpNSApplication();
virtual void DoRun(Delegate* delegate) OVERRIDE;
virtual void Quit() OVERRIDE;
- protected:
- virtual ~MessagePumpNSApplication();
-
private:
// False after Quit is called.
bool keep_running_;
@@ -290,10 +281,9 @@ class MessagePumpNSApplication : public MessagePumpCFRunLoopBase {
class MessagePumpCrApplication : public MessagePumpNSApplication {
public:
MessagePumpCrApplication();
+ virtual ~MessagePumpCrApplication();
protected:
- virtual ~MessagePumpCrApplication() {}
-
// Returns nil if NSApp is currently in the middle of calling
// -sendEvent. Requires NSApp implementing CrAppProtocol.
virtual NSAutoreleasePool* CreateAutoreleasePool() OVERRIDE;

Powered by Google App Engine
This is Rietveld 408576698