summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--base/message_loop.cc3
-rw-r--r--base/message_pump_win.cc3
2 files changed, 5 insertions, 1 deletions
diff --git a/base/message_loop.cc b/base/message_loop.cc
index f91a6c9..b920167 100644
--- a/base/message_loop.cc
+++ b/base/message_loop.cc
@@ -406,6 +406,8 @@ void MessageLoop::DidChangeNextTimerExpiry() {
bool MessageLoop::DoWork() {
if (ProcessNextDeferredTask()) {
+ // TODO(darin): Temporarily moved into MessagePumpWin::HandleWorkMessage.
+#if 0
// Let the MessagePump know that we may have more work to do. It is
// tempting to only call this function if our work queue is not empty, but
// doing so is insufficient. The issue is that ReloadWorkQueue does not
@@ -414,6 +416,7 @@ bool MessageLoop::DoWork() {
// very low cost (in the case where it is redundant), so we don't worry
// about optimizing away spurious ScheduleWork calls.
pump_->ScheduleWork();
+#endif
return true;
}
return false;
diff --git a/base/message_pump_win.cc b/base/message_pump_win.cc
index 29e7ba4..6be4e0f 100644
--- a/base/message_pump_win.cc
+++ b/base/message_pump_win.cc
@@ -236,7 +236,8 @@ void MessagePumpWin::HandleWorkMessage() {
// Now give the delegate a chance to do some work. He'll let us know if he
// needs to do more work.
- state_->delegate->DoWork();
+ if (state_->delegate->DoWork())
+ ScheduleWork();
}
void MessagePumpWin::HandleTimerMessage() {