mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-17 07:15:46 +00:00
Bug 1439937 - For font-matching reftests that test localized names, force the font-name loader to run eagerly so that we aren't dependent on how long the browser has been running. r=jrmuizel
This commit is contained in:
parent
49f4a46acf
commit
2c5f2dc22f
@ -367,7 +367,14 @@ gfxPlatformFontList::InitOtherFamilyNames(bool aDeferOtherFamilyNamesLoading)
|
||||
return;
|
||||
}
|
||||
|
||||
if (aDeferOtherFamilyNamesLoading) {
|
||||
// If the font loader delay has been set to zero, we don't defer loading
|
||||
// additional family names (regardless of the aDefer... parameter), as we
|
||||
// take this to mean availability of font info is to be prioritized over
|
||||
// potential startup perf or main-thread jank.
|
||||
// (This is used so we can reliably run reftests that depend on localized
|
||||
// font-family names being available.)
|
||||
if (aDeferOtherFamilyNamesLoading &&
|
||||
Preferences::GetUint(FONT_LOADER_DELAY_PREF) > 0) {
|
||||
if (!mPendingOtherFamilyNameTask) {
|
||||
RefPtr<mozilla::CancelableRunnable> task = new InitOtherFamilyNamesRunnable();
|
||||
mPendingOtherFamilyNameTask = task;
|
||||
|
@ -1,3 +1,9 @@
|
||||
# Run the font loader eagerly: this also ensures we will eagerly load localized
|
||||
# family names when looking up a requested font-family. Otherwise, tests here
|
||||
# may fail if they're running too soon after browser startup, and localized
|
||||
# names have not yet been read. (See bug 1439937.)
|
||||
default-preferences pref(gfx.font_loader.delay,0)
|
||||
|
||||
== CSS21-t1502-no-inherited-font-family.xhtml CSS21-t1502-no-inherited-font-family-ref.xhtml
|
||||
|
||||
# tests for bug 1394311 (case-insensitive lang tag processing)
|
||||
@ -145,3 +151,6 @@ skip-if(gtkWidget||/^Windows\x20NT\x206\.1/.test(http.oscpu)) == emoji-fallback-
|
||||
# and are not expected to pass on platforms that don't have those same fonts.
|
||||
skip-if(!cocoaWidget) == legacy-family-names-1.html legacy-family-names-1-ref.html
|
||||
skip-if(!winWidget) == legacy-family-names-2.html legacy-family-names-2-ref.html
|
||||
|
||||
# Reset default prefs.
|
||||
default-preferences
|
||||
|
Loading…
Reference in New Issue
Block a user