зеркало из https://github.com/mozilla/gecko-dev.git
4cc133b568
Due to the include hell, `EditorBase.h` cannot include `EditorUtils.h`. Therefore we need these 3 methods once. Additionally, `IsModifiableNode()` is really odd method and looks like that it's used for the following 2 purposes: 1. Simply can be editable. 2. Can be removed from parent. For the former case, we should sort out it with `EditorUtils::IsEditableContent()`, but for now, this patch moves it to `HTMLEditUtils::IsSimplyEditable()`. On the other hand, for the latter case, we obviously has a bug. Therefore, this patch creates `HTMLEditUtils::IsRemovableFromParentNode()` and make it check whether the removing node is also editable. Unfortunately, `EditorUtils::IsEditableContent()` needs to take editor type. But it's most callers are in `HTMLEditor` and most of remains are in common methods of `EditorBase`. I guess we could remove this ugly argument in the future. Depends on D70874 Differential Revision: https://phabricator.services.mozilla.com/D70875 --HG-- extra : moz-landing-system : lando |
||
---|---|---|
.. | ||
composer | ||
libeditor | ||
reftests | ||
spellchecker | ||
txmgr | ||
AsyncSpellCheckTestHelper.jsm | ||
moz.build | ||
nsIDocumentStateListener.idl | ||
nsIEditActionListener.idl | ||
nsIEditor.idl | ||
nsIEditorMailSupport.idl | ||
nsIEditorObserver.idl | ||
nsIEditorSpellCheck.idl | ||
nsIEditorStyleSheets.idl | ||
nsIHTMLAbsPosEditor.idl | ||
nsIHTMLEditor.idl | ||
nsIHTMLInlineTableEditor.idl | ||
nsIHTMLObjectResizer.idl | ||
nsITableEditor.idl |