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

Unified Diff: base/message_loop/message_loop.cc

Issue 2884353004: fuchsia: base_unittests (mostly) compiling (Closed)
Patch Set: rebase Created 3 years, 7 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 | « base/files/file_util_posix.cc ('k') | base/process/process_metrics.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/message_loop/message_loop.cc
diff --git a/base/message_loop/message_loop.cc b/base/message_loop/message_loop.cc
index e078b1f5730af42f96c736ab5888c52608b0f045..d72602babf6e8cad133a4492663c6fb0a41e3665 100644
--- a/base/message_loop/message_loop.cc
+++ b/base/message_loop/message_loop.cc
@@ -46,13 +46,13 @@ MessageLoop::MessagePumpFactory* message_pump_for_ui_factory_ = NULL;
#if defined(OS_IOS)
typedef MessagePumpIOSForIO MessagePumpForIO;
-#elif defined(OS_NACL_SFI)
+#elif defined(OS_NACL_SFI) || defined(OS_FUCHSIA)
typedef MessagePumpDefault MessagePumpForIO;
#elif defined(OS_POSIX)
typedef MessagePumpLibevent MessagePumpForIO;
#endif
-#if !defined(OS_NACL_SFI)
+#if !defined(OS_NACL_SFI) && !defined(OS_FUCHSIA)
MessagePumpForIO* ToPumpIO(MessagePump* pump) {
return static_cast<MessagePumpForIO*>(pump);
}
@@ -170,9 +170,11 @@ std::unique_ptr<MessagePump> MessageLoop::CreateMessagePumpForType(Type type) {
#if defined(OS_IOS) || defined(OS_MACOSX)
#define MESSAGE_PUMP_UI std::unique_ptr<MessagePump>(MessagePumpMac::Create())
-#elif defined(OS_NACL) || defined(OS_AIX)
-// Currently NaCl doesn't have a UI MessageLoop.
+#elif defined(OS_NACL) || defined(OS_AIX) || defined(OS_FUCHSIA)
+// Currently NaCl and AIX don't have a UI MessageLoop.
// TODO(abarth): Figure out if we need this.
+// TODO(fuchsia): Fuchsia may require one once more UI-level things have been
+// ported. See https://crbug.com/706592.
#define MESSAGE_PUMP_UI std::unique_ptr<MessagePump>()
#else
#define MESSAGE_PUMP_UI std::unique_ptr<MessagePump>(new MessagePumpForUI())
@@ -634,7 +636,7 @@ bool MessageLoopForIO::RegisterJobObject(HANDLE job, IOHandler* handler) {
bool MessageLoopForIO::WaitForIOCompletion(DWORD timeout, IOHandler* filter) {
return ToPumpIO(pump_.get())->WaitForIOCompletion(timeout, filter);
}
-#elif defined(OS_POSIX)
+#elif defined(OS_POSIX) && !defined(OS_FUCHSIA)
bool MessageLoopForIO::WatchFileDescriptor(int fd,
bool persistent,
Mode mode,
« no previous file with comments | « base/files/file_util_posix.cc ('k') | base/process/process_metrics.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698