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

Side by Side Diff: base/message_loop/message_loop.h

Issue 110283005: Make aura_demo work on Mac (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix resolve Created 6 years, 11 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | base/run_loop.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef BASE_MESSAGE_LOOP_MESSAGE_LOOP_H_ 5 #ifndef BASE_MESSAGE_LOOP_MESSAGE_LOOP_H_
6 #define BASE_MESSAGE_LOOP_MESSAGE_LOOP_H_ 6 #define BASE_MESSAGE_LOOP_MESSAGE_LOOP_H_
7 7
8 #include <queue> 8 #include <queue>
9 #include <string> 9 #include <string>
10 10
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 // hr = DoDragDrop(...); // Implicitly runs a modal message loop. 89 // hr = DoDragDrop(...); // Implicitly runs a modal message loop.
90 // } 90 // }
91 // // Process |hr| (the result returned by DoDragDrop()). 91 // // Process |hr| (the result returned by DoDragDrop()).
92 // 92 //
93 // Please be SURE your task is reentrant (nestable) and all global variables 93 // Please be SURE your task is reentrant (nestable) and all global variables
94 // are stable and accessible before calling SetNestableTasksAllowed(true). 94 // are stable and accessible before calling SetNestableTasksAllowed(true).
95 // 95 //
96 class BASE_EXPORT MessageLoop : public MessagePump::Delegate { 96 class BASE_EXPORT MessageLoop : public MessagePump::Delegate {
97 public: 97 public:
98 98
99 #if defined(USE_GTK_MESSAGE_PUMP) 99 #if defined(USE_AURA)
100 typedef MessagePumpGdkObserver Observer;
101 #elif !defined(OS_MACOSX) && !defined(OS_ANDROID)
102 typedef MessagePumpDispatcher Dispatcher; 100 typedef MessagePumpDispatcher Dispatcher;
103 typedef MessagePumpObserver Observer; 101 typedef MessagePumpObserver Observer;
102 #elif defined(USE_GTK_MESSAGE_PUMP)
103 typedef MessagePumpGdkObserver Observer;
104 #endif 104 #endif
105 105
106 // A MessageLoop has a particular type, which indicates the set of 106 // A MessageLoop has a particular type, which indicates the set of
107 // asynchronous events it may process in addition to tasks and timers. 107 // asynchronous events it may process in addition to tasks and timers.
108 // 108 //
109 // TYPE_DEFAULT 109 // TYPE_DEFAULT
110 // This type of ML only supports tasks and timers. 110 // This type of ML only supports tasks and timers.
111 // 111 //
112 // TYPE_UI 112 // TYPE_UI
113 // This type of ML also supports native UI events (e.g., Windows messages). 113 // This type of ML also supports native UI events (e.g., Windows messages).
(...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after
713 713
714 // Do not add any member variables to MessageLoopForIO! This is important b/c 714 // Do not add any member variables to MessageLoopForIO! This is important b/c
715 // MessageLoopForIO is often allocated via MessageLoop(TYPE_IO). Any extra 715 // MessageLoopForIO is often allocated via MessageLoop(TYPE_IO). Any extra
716 // data that you need should be stored on the MessageLoop's pump_ instance. 716 // data that you need should be stored on the MessageLoop's pump_ instance.
717 COMPILE_ASSERT(sizeof(MessageLoop) == sizeof(MessageLoopForIO), 717 COMPILE_ASSERT(sizeof(MessageLoop) == sizeof(MessageLoopForIO),
718 MessageLoopForIO_should_not_have_extra_member_variables); 718 MessageLoopForIO_should_not_have_extra_member_variables);
719 719
720 } // namespace base 720 } // namespace base
721 721
722 #endif // BASE_MESSAGE_LOOP_MESSAGE_LOOP_H_ 722 #endif // BASE_MESSAGE_LOOP_MESSAGE_LOOP_H_
OLDNEW
« no previous file with comments | « no previous file | base/run_loop.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698