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

Side by Side Diff: base/message_pump_win.cc

Issue 6688056: Updating DCHECK() to DCHECK_GE() in base/ dir (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Updating license header Created 9 years, 8 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/mach_ipc_mac.mm ('k') | base/path_service.cc » ('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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "base/message_pump_win.h" 5 #include "base/message_pump_win.h"
6 6
7 #include <math.h> 7 #include <math.h>
8 8
9 #include "base/metrics/histogram.h" 9 #include "base/metrics/histogram.h"
10 #include "base/win/wrapped_window_proc.h" 10 #include "base/win/wrapped_window_proc.h"
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 // run loop itself. 115 // run loop itself.
116 // 116 //
117 // We use a single SetTimer corresponding to the timer that will expire 117 // We use a single SetTimer corresponding to the timer that will expire
118 // soonest. As new timers are created and destroyed, we update SetTimer. 118 // soonest. As new timers are created and destroyed, we update SetTimer.
119 // Getting a spurrious SetTimer event firing is benign, as we'll just be 119 // Getting a spurrious SetTimer event firing is benign, as we'll just be
120 // processing an empty timer queue. 120 // processing an empty timer queue.
121 // 121 //
122 delayed_work_time_ = delayed_work_time; 122 delayed_work_time_ = delayed_work_time;
123 123
124 int delay_msec = GetCurrentDelay(); 124 int delay_msec = GetCurrentDelay();
125 DCHECK(delay_msec >= 0); 125 DCHECK_GE(delay_msec, 0);
126 if (delay_msec < USER_TIMER_MINIMUM) 126 if (delay_msec < USER_TIMER_MINIMUM)
127 delay_msec = USER_TIMER_MINIMUM; 127 delay_msec = USER_TIMER_MINIMUM;
128 128
129 // Create a WM_TIMER event that will wake us up to check for any pending 129 // Create a WM_TIMER event that will wake us up to check for any pending
130 // timers (in case we are running within a nested, external sub-pump). 130 // timers (in case we are running within a nested, external sub-pump).
131 SetTimer(message_hwnd_, reinterpret_cast<UINT_PTR>(this), delay_msec, NULL); 131 SetTimer(message_hwnd_, reinterpret_cast<UINT_PTR>(this), delay_msec, NULL);
132 } 132 }
133 133
134 void MessagePumpForUI::PumpOutPendingPaintMessages() { 134 void MessagePumpForUI::PumpOutPendingPaintMessages() {
135 // If we are being called outside of the context of Run, then don't try to do 135 // If we are being called outside of the context of Run, then don't try to do
(...skipping 426 matching lines...) Expand 10 before | Expand all | Expand 10 after
562 562
563 void MessagePumpForIO::WillProcessIOEvent() { 563 void MessagePumpForIO::WillProcessIOEvent() {
564 FOR_EACH_OBSERVER(IOObserver, io_observers_, WillProcessIOEvent()); 564 FOR_EACH_OBSERVER(IOObserver, io_observers_, WillProcessIOEvent());
565 } 565 }
566 566
567 void MessagePumpForIO::DidProcessIOEvent() { 567 void MessagePumpForIO::DidProcessIOEvent() {
568 FOR_EACH_OBSERVER(IOObserver, io_observers_, DidProcessIOEvent()); 568 FOR_EACH_OBSERVER(IOObserver, io_observers_, DidProcessIOEvent());
569 } 569 }
570 570
571 } // namespace base 571 } // namespace base
OLDNEW
« no previous file with comments | « base/mach_ipc_mac.mm ('k') | base/path_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698