summaryrefslogtreecommitdiffstats
path: root/base/message_loop.cc
diff options
context:
space:
mode:
authorsky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-18 21:12:34 +0000
committersky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-18 21:12:34 +0000
commitfaabcf4802395d91b82dd671422b78bfb46b1bef (patch)
treefa4e91ece94e10ef536ceb78b2a87572716bae81 /base/message_loop.cc
parent41062d78a4152732437192f7131c58d5fa66516d (diff)
downloadchromium_src-faabcf4802395d91b82dd671422b78bfb46b1bef.zip
chromium_src-faabcf4802395d91b82dd671422b78bfb46b1bef.tar.gz
chromium_src-faabcf4802395d91b82dd671422b78bfb46b1bef.tar.bz2
Promotes Add/RemoveObserver to MessageLoop for linux. Because
message_loop.h now includes message_pump_glib.h I needed to update the dependencies of a couple of projects. BUG=none TEST=none Review URL: http://codereview.chromium.org/112032 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@16317 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/message_loop.cc')
-rw-r--r--base/message_loop.cc20
1 files changed, 12 insertions, 8 deletions
diff --git a/base/message_loop.cc b/base/message_loop.cc
index 4f9dc0b..e010c73 100644
--- a/base/message_loop.cc
+++ b/base/message_loop.cc
@@ -565,6 +565,18 @@ const LinearHistogram::DescriptionPair MessageLoop::event_descriptions_[] = {
//------------------------------------------------------------------------------
// MessageLoopForUI
+#if defined(OS_LINUX) || defined(OS_WIN)
+
+void MessageLoopForUI::AddObserver(Observer* observer) {
+ pump_ui()->AddObserver(observer);
+}
+
+void MessageLoopForUI::RemoveObserver(Observer* observer) {
+ pump_ui()->RemoveObserver(observer);
+}
+
+#endif
+
#if defined(OS_WIN)
void MessageLoopForUI::Run(Dispatcher* dispatcher) {
@@ -573,14 +585,6 @@ void MessageLoopForUI::Run(Dispatcher* dispatcher) {
RunHandler();
}
-void MessageLoopForUI::AddObserver(Observer* observer) {
- pump_win()->AddObserver(observer);
-}
-
-void MessageLoopForUI::RemoveObserver(Observer* observer) {
- pump_win()->RemoveObserver(observer);
-}
-
void MessageLoopForUI::WillProcessMessage(const MSG& message) {
pump_win()->WillProcessMessage(message);
}