From 25856340db9d48d57fae8e9c36c2b74efab9d746 Mon Sep 17 00:00:00 2001 From: KuoE0 Date: Wed, 10 Jan 2018 11:52:37 +0800 Subject: [PATCH] Bug 1428297 - (Part 3) Disable the assertion that don't allow to call ShowDropDown() in the content process when content-select is enabled. r=mats To prevent the crash when content-select is enabled, I disable this assertion that don't allow to call ShowDropDown() in the content process. MozReview-Commit-ID: F3BelChp1AK --HG-- extra : rebase_source : 2bbec4dceffb7698804609010127b37442a907a7 --- layout/forms/nsComboboxControlFrame.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/layout/forms/nsComboboxControlFrame.cpp b/layout/forms/nsComboboxControlFrame.cpp index 6d5f1d01bf45..ed25c62061ee 100644 --- a/layout/forms/nsComboboxControlFrame.cpp +++ b/layout/forms/nsComboboxControlFrame.cpp @@ -943,7 +943,10 @@ nsComboboxControlFrame::GetFrameName(nsAString& aResult) const void nsComboboxControlFrame::ShowDropDown(bool aDoDropDown) { - MOZ_ASSERT(!XRE_IsContentProcess()); + if (!nsLayoutUtils::IsContentSelectEnabled()) { + // TODO(kuoe0) remove this assertion after content-select is enabled + MOZ_ASSERT(!XRE_IsContentProcess()); + } mDelayedShowDropDown = false; EventStates eventStates = mContent->AsElement()->State(); if (aDoDropDown && eventStates.HasState(NS_EVENT_STATE_DISABLED)) {