bug 8801; temporary fix for bad performance problem with font prefs;

r=troy
This commit is contained in:
erik%netscape.com 2000-02-05 03:32:53 +00:00
Родитель 678a48909b
Коммит 25a1d1ac60
1 изменённых файлов: 6 добавлений и 2 удалений

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

@ -239,11 +239,13 @@ NS_IMETHODIMP DeviceContextImpl::GetMetricsFor(const nsFont& aFont,
aMetrics = nsnull;
return rv;
}
// XXX temporary fix for performance problem -- erik
mWestern = getter_AddRefs(NS_NewAtom("x-western"));
}
// XXX figure out why aLangGroup is NULL sometimes
if (!aLangGroup) {
aLangGroup = NS_NewAtom("x-western");
aLangGroup = mWestern;
}
return mFontCache->GetMetricsFor(aFont, aLangGroup, aMetrics);
@ -257,8 +259,10 @@ NS_IMETHODIMP DeviceContextImpl::GetMetricsFor(const nsFont& aFont, nsIFontMetri
aMetrics = nsnull;
return rv;
}
// XXX temporary fix for performance problem -- erik
mWestern = getter_AddRefs(NS_NewAtom("x-western"));
}
return mFontCache->GetMetricsFor(aFont, nsnull, aMetrics);
return mFontCache->GetMetricsFor(aFont, mWestern, aMetrics);
}
NS_IMETHODIMP DeviceContextImpl :: SetZoom(float aZoom)