From 34af0e1d923163191682a3d8a8c69448927a61d5 Mon Sep 17 00:00:00 2001 From: "troy%netscape.com" Date: Thu, 23 Jul 1998 23:28:03 +0000 Subject: [PATCH] Tweaked the repaint code in Reflow() to make sure the entire frame is repainted for a resize reflow --- layout/html/base/src/nsRootPart.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/layout/html/base/src/nsRootPart.cpp b/layout/html/base/src/nsRootPart.cpp index 1c9822e763a5..12aa5c5958b9 100644 --- a/layout/html/base/src/nsRootPart.cpp +++ b/layout/html/base/src/nsRootPart.cpp @@ -443,10 +443,13 @@ NS_METHOD RootContentFrame::Reflow(nsIPresContext& aPresContext, nsRect rect(0, 0, aDesiredSize.width, aDesiredSize.height); mFirstChild->SetRect(rect); - // For initial reflow and resize reflow repaint the entire visible area - if ((eReflowReason_Initial == reflowReason) || - (eReflowReason_Resize == aReflowState.reason)) { + // Do the necessary repainting + if (eReflowReason_Initial == reflowReason) { + // Repaint the visible area Invalidate(nsRect(0, 0, aReflowState.maxSize.width, aReflowState.maxSize.height)); + } else if (eReflowReason_Resize == aReflowState.reason) { + // Repaint the entire frame + Invalidate(nsRect(0, 0, aReflowState.maxSize.width, aDesiredSize.height)); } } }