From 5ea352697965d7f31a1263e4ba76fcdfdc05fc87 Mon Sep 17 00:00:00 2001 From: Timothy Nikkel Date: Tue, 22 Feb 2011 13:44:30 -0600 Subject: [PATCH] Backout 273cb783edac (bug 627628) for causing bug 635465. a=backout --- widget/src/windows/nsWindow.cpp | 9 +++------ widget/src/windows/nsWindow.h | 7 ------- widget/src/windows/nsWindowGfx.cpp | 1 - 3 files changed, 3 insertions(+), 14 deletions(-) diff --git a/widget/src/windows/nsWindow.cpp b/widget/src/windows/nsWindow.cpp index 78c9a93a6df9..57bdd461bb8e 100644 --- a/widget/src/windows/nsWindow.cpp +++ b/widget/src/windows/nsWindow.cpp @@ -3945,12 +3945,9 @@ void nsWindow::DispatchPendingEvents() --recursionBlocker; } - // Quickly check to see if there are any paint events pending, - // but only dispatch them if it has been long enough since the - // last paint completed. - if (::GetQueueStatus(QS_PAINT) && - (mLastPaintEndTime.IsNull() || - (TimeStamp::Now() - mLastPaintEndTime).ToMilliseconds() >= 50)) { + // Quickly check to see if there are any + // paint events pending. + if (::GetQueueStatus(QS_PAINT)) { // Find the top level window. HWND topWnd = GetTopLevelHWND(mWnd); diff --git a/widget/src/windows/nsWindow.h b/widget/src/windows/nsWindow.h index 60556b363656..5225d5e04cbb 100644 --- a/widget/src/windows/nsWindow.h +++ b/widget/src/windows/nsWindow.h @@ -61,8 +61,6 @@ #include "nsWindowDbg.h" #include "cairo.h" #include "nsITimer.h" -#include "mozilla/TimeStamp.h" - #ifdef CAIRO_HAS_D2D_SURFACE #include "gfxD2DSurface.h" #endif @@ -101,7 +99,6 @@ class imgIContainer; class nsWindow : public nsBaseWidget { - typedef mozilla::TimeStamp TimeStamp; typedef mozilla::widget::WindowHook WindowHook; #if MOZ_WINSDK_TARGETVER >= MOZ_NTDDI_WIN7 typedef mozilla::widget::TaskbarWindowPreview TaskbarWindowPreview; @@ -626,10 +623,6 @@ protected: PRBool mHasTaskbarIconBeenCreated; #endif - // The point in time at which the last paint completed. We use this to avoid - // painting too rapidly in response to frequent input events. - TimeStamp mLastPaintEndTime; - #if defined(WINCE_HAVE_SOFTKB) static PRBool sSoftKeyboardState; #endif // defined(WINCE_HAVE_SOFTKB) diff --git a/widget/src/windows/nsWindowGfx.cpp b/widget/src/windows/nsWindowGfx.cpp index e0782d4554e3..a909f2db1d68 100644 --- a/widget/src/windows/nsWindowGfx.cpp +++ b/widget/src/windows/nsWindowGfx.cpp @@ -642,7 +642,6 @@ PRBool nsWindow::OnPaint(HDC aDC, PRUint32 aNestingLevel) } mPaintDC = nsnull; - mLastPaintEndTime = TimeStamp::Now(); #if defined(WIDGET_DEBUG_OUTPUT) && !defined(WINCE) if (debug_WantPaintFlashing())