Bug 391494: full page zoom causes scrollbars to be cut off. r+sr+a=roc

This commit is contained in:
sharparrow1@yahoo.com 2007-08-24 10:46:59 -07:00
Родитель bc5544c036
Коммит 511ac7eb40
2 изменённых файлов: 7 добавлений и 3 удалений

Просмотреть файл

@ -798,6 +798,8 @@ nsPresContext::Init(nsIDeviceContext* aDeviceContext)
mDeviceContext = aDeviceContext;
NS_ADDREF(mDeviceContext);
mCurAppUnitsPerDevPixel = AppUnitsPerDevPixel();
if (!mImageLoaders.Init())
return NS_ERROR_OUT_OF_MEMORY;
@ -1145,8 +1147,8 @@ nsPresContext::GetDefaultFontExternal(PRUint8 aFontID) const
void
nsPresContext::SetFullZoom(float aZoom)
{
float oldWidth = mVisibleArea.width * mFullZoom;
float oldHeight = mVisibleArea.height * mFullZoom;
float oldWidth = mVisibleArea.width / float(mCurAppUnitsPerDevPixel);
float oldHeight = mVisibleArea.height / float(mCurAppUnitsPerDevPixel);
if (!mShell) {
return;
}
@ -1155,9 +1157,10 @@ nsPresContext::SetFullZoom(float aZoom)
}
if (mFullZoom != aZoom) {
mFullZoom = aZoom;
GetViewManager()->SetWindowDimensions(oldWidth / aZoom, oldHeight / aZoom);
GetViewManager()->SetWindowDimensions(oldWidth * AppUnitsPerDevPixel(), oldHeight * AppUnitsPerDevPixel());
ClearStyleDataAndReflow();
}
mCurAppUnitsPerDevPixel = AppUnitsPerDevPixel();
}
imgIRequest*

Просмотреть файл

@ -773,6 +773,7 @@ protected:
float mTextZoom; // Text zoom, defaults to 1.0
float mFullZoom; // Page zoom, defaults to 1.0
PRInt32 mCurAppUnitsPerDevPixel;
PRInt32 mAutoQualityMinFontSizePixelsPref;
#ifdef IBMBIDI