Bug 1343037 part 3. Get rid of nsIDOMHTMLTextareaElement's selectionStart and selectionEnd accessors. r=ehsan

MozReview-Commit-ID: Ca95YfRaq9r
This commit is contained in:
Boris Zbarsky 2017-03-09 14:44:04 -05:00
Родитель 03aa46332c
Коммит 7f964a7045
2 изменённых файлов: 0 добавлений и 50 удалений

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

@ -690,21 +690,6 @@ HTMLTextAreaElement::GetTextLength(int32_t *aTextLength)
return NS_OK;
}
NS_IMETHODIMP
HTMLTextAreaElement::GetSelectionStart(int32_t *aSelectionStart)
{
NS_ENSURE_ARG_POINTER(aSelectionStart);
ErrorResult error;
Nullable<uint32_t> selStart(GetSelectionStart(error));
if (error.Failed()) {
return error.StealNSResult();
}
*aSelectionStart = int32_t(selStart.Value());
return error.StealNSResult();
}
Nullable<uint32_t>
HTMLTextAreaElement::GetSelectionStart(ErrorResult& aError)
{
@ -720,15 +705,6 @@ HTMLTextAreaElement::GetSelectionStart(ErrorResult& aError)
return Nullable<uint32_t>(selStart);
}
NS_IMETHODIMP
HTMLTextAreaElement::SetSelectionStart(int32_t aSelectionStart)
{
ErrorResult error;
Nullable<uint32_t> selStart(aSelectionStart);
SetSelectionStart(selStart, error);
return error.StealNSResult();
}
void
HTMLTextAreaElement::SetSelectionStart(const Nullable<uint32_t>& aSelectionStart,
ErrorResult& aError)
@ -765,21 +741,6 @@ HTMLTextAreaElement::SetSelectionStart(const Nullable<uint32_t>& aSelectionStart
}
}
NS_IMETHODIMP
HTMLTextAreaElement::GetSelectionEnd(int32_t *aSelectionEnd)
{
NS_ENSURE_ARG_POINTER(aSelectionEnd);
ErrorResult error;
Nullable<uint32_t> selEnd(GetSelectionEnd(error));
if (error.Failed()) {
return error.StealNSResult();
}
*aSelectionEnd = int32_t(selEnd.Value());
return NS_OK;
}
Nullable<uint32_t>
HTMLTextAreaElement::GetSelectionEnd(ErrorResult& aError)
{
@ -795,15 +756,6 @@ HTMLTextAreaElement::GetSelectionEnd(ErrorResult& aError)
return Nullable<uint32_t>(selEnd);
}
NS_IMETHODIMP
HTMLTextAreaElement::SetSelectionEnd(int32_t aSelectionEnd)
{
ErrorResult error;
Nullable<uint32_t> selEnd(aSelectionEnd);
SetSelectionEnd(selEnd, error);
return error.StealNSResult();
}
void
HTMLTextAreaElement::SetSelectionEnd(const Nullable<uint32_t>& aSelectionEnd,
ErrorResult& aError)

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

@ -54,8 +54,6 @@ interface nsIDOMHTMLTextAreaElement : nsISupports
void setCustomValidity(in DOMString error);
void select();
attribute long selectionStart;
attribute long selectionEnd;
void setSelectionRange(in long selectionStart, in long selectionEnd, [optional] in DOMString direction);
attribute DOMString selectionDirection;