зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1369903 Part 3: Ensure that Loader enables all cloned stylesheets, and checks modified state of all stylesheets, regardless of backend. r=emilio
MozReview-Commit-ID: EEnFeaw2r0u --HG-- extra : rebase_source : 1ff76aee934c6fe191105ce397c0e191e9802acb
This commit is contained in:
Родитель
6aa25ee4e2
Коммит
49ed79f4ce
|
@ -1412,10 +1412,10 @@ Loader::InsertChildSheet(StyleSheet* aSheet,
|
|||
MOZ_ASSERT(aParentSheet, "Need a parent to insert into");
|
||||
MOZ_ASSERT_IF(aSheet->IsGecko(), aGeckoParentRule && !aServoChildSheet);
|
||||
MOZ_ASSERT_IF(aSheet->IsServo(), aServoChildSheet && !aGeckoParentRule);
|
||||
// child sheets should always start out enabled, even if they got
|
||||
// cloned off of top-level sheets which were disabled
|
||||
aSheet->SetEnabled(true);
|
||||
if (aSheet->IsGecko()) {
|
||||
// child sheets should always start out enabled, even if they got
|
||||
// cloned off of top-level sheets which were disabled
|
||||
aSheet->AsGecko()->SetEnabled(true);
|
||||
aGeckoParentRule->SetSheet(aSheet->AsGecko()); // This sets the ownerRule on the sheet
|
||||
} else {
|
||||
if (!aSheet->AsServo()->RawSheet()) {
|
||||
|
@ -1900,8 +1900,7 @@ Loader::DoSheetComplete(SheetLoadData* aLoadData, nsresult aStatus,
|
|||
// If mSheetAlreadyComplete, then the sheet could well be modified between
|
||||
// when we posted the async call to SheetComplete and now, since the sheet
|
||||
// was page-accessible during that whole time.
|
||||
MOZ_ASSERT(!(data->mSheet->IsGecko() &&
|
||||
data->mSheet->AsGecko()->IsModified()),
|
||||
MOZ_ASSERT(!data->mSheet->IsModified(),
|
||||
"should not get marked modified during parsing");
|
||||
data->mSheet->SetComplete();
|
||||
data->ScheduleLoadEventIfNeeded(aStatus);
|
||||
|
|
Загрузка…
Ссылка в новой задаче