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

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

Issue 407073004: Revert of High resolution timer fix for Windows (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « base/message_loop/message_loop_unittest.cc ('k') | base/pending_task.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_PUMP_H_ 5 #ifndef BASE_MESSAGE_LOOP_MESSAGE_PUMP_H_
6 #define BASE_MESSAGE_LOOP_MESSAGE_PUMP_H_ 6 #define BASE_MESSAGE_LOOP_MESSAGE_PUMP_H_
7 7
8 #include "base/base_export.h" 8 #include "base/base_export.h"
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/message_loop/timer_slack.h" 10 #include "base/message_loop/timer_slack.h"
(...skipping 21 matching lines...) Expand all
32 // message pump would otherwise sleep waiting for more work. Returns true 32 // message pump would otherwise sleep waiting for more work. Returns true
33 // to indicate that delayed work was done. DoIdleWork will not be called 33 // to indicate that delayed work was done. DoIdleWork will not be called
34 // if DoDelayedWork returns true. Upon return |next_delayed_work_time| 34 // if DoDelayedWork returns true. Upon return |next_delayed_work_time|
35 // indicates the time when DoDelayedWork should be called again. If 35 // indicates the time when DoDelayedWork should be called again. If
36 // |next_delayed_work_time| is null (per Time::is_null), then the queue of 36 // |next_delayed_work_time| is null (per Time::is_null), then the queue of
37 // future delayed work (timer events) is currently empty, and no additional 37 // future delayed work (timer events) is currently empty, and no additional
38 // calls to this function need to be scheduled. 38 // calls to this function need to be scheduled.
39 virtual bool DoDelayedWork(TimeTicks* next_delayed_work_time) = 0; 39 virtual bool DoDelayedWork(TimeTicks* next_delayed_work_time) = 0;
40 40
41 // Called from within Run just before the message pump goes to sleep. 41 // Called from within Run just before the message pump goes to sleep.
42 // Returns true to indicate that idle work was done. Returning false means 42 // Returns true to indicate that idle work was done.
43 // the pump will now wait.
44 virtual bool DoIdleWork() = 0; 43 virtual bool DoIdleWork() = 0;
45 }; 44 };
46 45
47 MessagePump(); 46 MessagePump();
48 virtual ~MessagePump(); 47 virtual ~MessagePump();
49 48
50 // The Run method is called to enter the message pump's run loop. 49 // The Run method is called to enter the message pump's run loop.
51 // 50 //
52 // Within the method, the message pump is responsible for processing native 51 // Within the method, the message pump is responsible for processing native
53 // messages as well as for giving cycles to the delegate periodically. The 52 // messages as well as for giving cycles to the delegate periodically. The
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 // used on the thread that called Run. 122 // used on the thread that called Run.
124 virtual void ScheduleDelayedWork(const TimeTicks& delayed_work_time) = 0; 123 virtual void ScheduleDelayedWork(const TimeTicks& delayed_work_time) = 0;
125 124
126 // Sets the timer slack to the specified value. 125 // Sets the timer slack to the specified value.
127 virtual void SetTimerSlack(TimerSlack timer_slack); 126 virtual void SetTimerSlack(TimerSlack timer_slack);
128 }; 127 };
129 128
130 } // namespace base 129 } // namespace base
131 130
132 #endif // BASE_MESSAGE_LOOP_MESSAGE_PUMP_H_ 131 #endif // BASE_MESSAGE_LOOP_MESSAGE_PUMP_H_
OLDNEW
« no previous file with comments | « base/message_loop/message_loop_unittest.cc ('k') | base/pending_task.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698