Skip to content

Commit

Permalink
Bug 1717178 - part 5: Get rid of nsIHTMLEditor.pasteNoFormatting()
Browse files Browse the repository at this point in the history
…because of unused r=m_kato

Depends on D118800

Differential Revision: https://phabricator.services.mozilla.com/D118801
  • Loading branch information
masayuki-nakano committed Jun 28, 2021
1 parent f45ac00 commit a4eb032
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 19 deletions.
2 changes: 1 addition & 1 deletion editor/libeditor/HTMLEditor.h
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ class HTMLEditor final : public EditorBase,
nsIPrincipal* aPrincipal = nullptr) final;

/**
* PasteNoFormatting() pastes content in clipboard without any style
* PasteNoFormattingAsAction() pastes content in clipboard without any style
* information.
*
* @param aSelectionType nsIClipboard::kGlobalClipboard or
Expand Down
10 changes: 0 additions & 10 deletions editor/libeditor/HTMLEditorDataTransfer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2209,16 +2209,6 @@ nsresult HTMLEditor::PasteTransferableAsAction(nsITransferable* aTransferable,
return EditorBase::ToGenericNSResult(rv);
}

/**
* HTML PasteNoFormatting. Ignore any HTML styles and formating in paste source.
*/
NS_IMETHODIMP HTMLEditor::PasteNoFormatting(int32_t aSelectionType) {
nsresult rv = PasteNoFormattingAsAction(aSelectionType);
NS_WARNING_ASSERTION(NS_SUCCEEDED(rv),
"HTMLEditor::PasteNoFormattingAsAction() failed");
return rv;
}

nsresult HTMLEditor::PasteNoFormattingAsAction(int32_t aSelectionType,
nsIPrincipal* aPrincipal) {
AutoEditActionDataSetter editActionData(*this, EditAction::ePaste,
Expand Down
8 changes: 0 additions & 8 deletions editor/nsIHTMLEditor.idl
Original file line number Diff line number Diff line change
Expand Up @@ -108,14 +108,6 @@ interface nsIHTMLEditor : nsISupports
[can_run_script]
void insertHTML(in AString aInputString);


/**
* Paste the text in the OS clipboard at the cursor position, replacing
* the selected text (if any), but strip out any HTML styles and formatting
*/
[can_run_script]
void pasteNoFormatting(in long aSelectionType);

/**
* Rebuild the entire document from source HTML
* Needed to be able to edit HEAD and other outside-of-BODY content
Expand Down

0 comments on commit a4eb032

Please sign in to comment.