Bug 1446527 part 2. Remove nsIDOMUIEvent::GetDetail. r=qdot

MozReview-Commit-ID: GlTgti53Akj
This commit is contained in:
Boris Zbarsky 2018-03-26 14:53:02 -04:00
Родитель f0bc98f232
Коммит 35a72f73ba
3 изменённых файлов: 3 добавлений и 15 удалений

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

@ -144,13 +144,6 @@ UIEvent::GetView(mozIDOMWindowProxy** aView)
return NS_OK;
}
NS_IMETHODIMP
UIEvent::GetDetail(int32_t* aDetail)
{
*aDetail = mDetail;
return NS_OK;
}
void
UIEvent::InitUIEvent(const nsAString& typeArg,
bool canBubbleArg,
@ -369,9 +362,7 @@ UIEvent::Serialize(IPC::Message* aMsg, bool aSerializeInterfaceType)
Event::Serialize(aMsg, false);
int32_t detail = 0;
GetDetail(&detail);
IPC::WriteParam(aMsg, detail);
IPC::WriteParam(aMsg, Detail());
}
NS_IMETHODIMP_(bool)

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

@ -31,7 +31,6 @@ class Event;
interface nsIDOMUIEvent : nsISupports
{
readonly attribute mozIDOMWindowProxy view;
readonly attribute long detail;
void initUIEvent(in DOMString typeArg,
in boolean canBubbleArg,
in boolean cancelableArg,

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

@ -99,9 +99,7 @@ HTMLEditorEventListener::MouseDown(MouseEvent* aMouseEvent)
bool isContextClick = buttonNumber == 2;
int32_t clickCount;
nsresult rv = aMouseEvent->GetDetail(&clickCount);
NS_ENSURE_SUCCESS(rv, rv);
int32_t clickCount = aMouseEvent->Detail();
nsCOMPtr<nsIDOMEventTarget> target = aMouseEvent->GetExplicitOriginalTarget();
NS_ENSURE_TRUE(target, NS_ERROR_NULL_POINTER);
@ -148,7 +146,7 @@ HTMLEditorEventListener::MouseDown(MouseEvent* aMouseEvent)
} else {
// Get enclosing link if in text so we can select the link
nsCOMPtr<nsIDOMElement> linkElement;
rv = htmlEditor->GetElementOrParentByTagName(
nsresult rv = htmlEditor->GetElementOrParentByTagName(
NS_LITERAL_STRING("href"), node,
getter_AddRefs(linkElement));
NS_ENSURE_SUCCESS(rv, rv);