зеркало из https://github.com/mozilla/pjs.git
Bug 664095 - Remove the override stylesheets when the editor is detached from the document as opposed to when it's destroyed for compatibility with the expected behavior from Composer; r=ehsan
This commit is contained in:
Родитель
0a4e1c65d1
Коммит
79de56f93d
|
@ -168,11 +168,6 @@ nsHTMLEditor::~nsHTMLEditor()
|
|||
// free any default style propItems
|
||||
RemoveAllDefaultProperties();
|
||||
|
||||
while (mStyleSheetURLs.Length())
|
||||
{
|
||||
RemoveOverrideStyleSheet(mStyleSheetURLs[0]);
|
||||
}
|
||||
|
||||
if (mLinkHandler && mDocWeak)
|
||||
{
|
||||
nsCOMPtr<nsIPresShell> ps = GetPresShell();
|
||||
|
@ -359,6 +354,11 @@ nsHTMLEditor::PreDestroy(PRBool aDestroyingFrames)
|
|||
document->RemoveMutationObserver(this);
|
||||
}
|
||||
|
||||
while (mStyleSheetURLs.Length())
|
||||
{
|
||||
RemoveOverrideStyleSheet(mStyleSheetURLs[0]);
|
||||
}
|
||||
|
||||
return nsPlaintextEditor::PreDestroy(aDestroyingFrames);
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче