mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
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:
parent
d8ff7b62b9
commit
db7ef51c94
@ -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);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user