Bug 1190172 part 4 - Remove unused nsHTMLEditor::HasAttr; r=ehsan

This commit is contained in:
Aryeh Gregor 2016-05-01 16:12:04 +03:00
Родитель e3e1997c88
Коммит 8aec477e68
2 изменённых файлов: 0 добавлений и 21 удалений

Просмотреть файл

@ -678,7 +678,6 @@ protected:
const nsAString* aAttribute);
bool NodeIsProperty(nsIDOMNode *aNode);
bool HasAttr(nsIDOMNode *aNode, const nsAString *aAttribute);
bool IsAtFrontOfNode(nsIDOMNode *aNode, int32_t aOffset);
bool IsAtEndOfNode(nsIDOMNode *aNode, int32_t aOffset);
bool IsOnlyAttribute(const nsIContent* aElement, const nsAString& aAttribute);

Просмотреть файл

@ -848,26 +848,6 @@ nsHTMLEditor::IsOnlyAttribute(const nsIContent* aContent,
return true;
}
bool nsHTMLEditor::HasAttr(nsIDOMNode* aNode,
const nsAString* aAttribute)
{
NS_ENSURE_TRUE(aNode, false);
if (!aAttribute || aAttribute->IsEmpty()) {
// everybody has the 'null' attribute
return true;
}
// get element
nsCOMPtr<dom::Element> element = do_QueryInterface(aNode);
NS_ENSURE_TRUE(element, false);
nsCOMPtr<nsIAtom> atom = NS_Atomize(*aAttribute);
NS_ENSURE_TRUE(atom, false);
return element->HasAttr(kNameSpaceID_None, atom);
}
nsresult
nsHTMLEditor::PromoteRangeIfStartsOrEndsInNamedAnchor(nsRange* inRange)
{