diff --git a/view/src/nsScrollingView.cpp b/view/src/nsScrollingView.cpp index 01730e9f3104..1c4230aa349d 100644 --- a/view/src/nsScrollingView.cpp +++ b/view/src/nsScrollingView.cpp @@ -1043,14 +1043,7 @@ NS_IMETHODIMP nsScrollingView :: ComputeContainerSize() mViewManager->GetDeviceContext(px); px->GetAppUnitsToDevUnits(scale); -#if 0 - ComputeScrollArea(scrolledView, area, 0, 0); - - mSizeY = area.YMost(); - mSizeX = area.XMost(); -#else scrolledView->GetDimensions(&mSizeX, &mSizeY); -#endif if (nsnull != mHScrollBarView) { @@ -1437,33 +1430,3 @@ NS_IMETHODIMP nsScrollingView :: GetScrollPosition(nscoord &aX, nscoord &aY) return NS_OK; } -void nsScrollingView :: ComputeScrollArea(nsIView *aView, nsRect &aRect, - nscoord aOffX, nscoord aOffY) -{ - nsRect trect, vrect; - - aView->GetBounds(vrect); - - aOffX += vrect.x; - aOffY += vrect.y; - - trect.x = aOffX; - trect.y = aOffY; - trect.width = vrect.width; - trect.height = vrect.height; - - if (aRect.IsEmpty() == PR_TRUE) - aRect = trect; - else - aRect.UnionRect(aRect, trect); - - PRInt32 numkids; - aView->GetChildCount(numkids); - - for (PRInt32 cnt = 0; cnt < numkids; cnt++) - { - nsIView *view; - aView->GetChild(cnt, view); - ComputeScrollArea(view, aRect, aOffX, aOffY); - } -} diff --git a/view/src/nsScrollingView.h b/view/src/nsScrollingView.h index 2e8c18bf71f2..febf5c14b77b 100644 --- a/view/src/nsScrollingView.h +++ b/view/src/nsScrollingView.h @@ -70,7 +70,6 @@ public: NS_IMETHOD GetClipSize(nscoord *aX, nscoord *aY); //private - void ComputeScrollArea(nsIView *aView, nsRect &aRect, nscoord aOffX, nscoord aOffY); virtual void HandleScrollEvent(nsGUIEvent *aEvent, PRUint32 aEventFlags); virtual void AdjustChildWidgets(nsScrollingView *aScrolling, nsIView *aView, nscoord aDx, nscoord aDy, float aScale);