Bug 1259659 - rename from InternalUIEvent.detail to InternalUIEvent.mDetail. r=masayuki
authorTetsuharu OHZEKI <saneyuki.snyk@gmail.com>
Sat, 26 Mar 2016 16:22:27 +0900
changeset 290508 24ac6ea7fdae65b5dd524702237bb59a354f4c29
parent 290507 605b1a8fa215870ea78b60e524750d6877bf1987
child 290509 cdf83aa2b0ba8f1b0b0f2b7402660307abd04b43
push id30123
push userkwierso@gmail.com
push dateMon, 28 Mar 2016 20:04:22 +0000
treeherdermozilla-central@a66bf0a800f3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmasayuki
bugs1259659
milestone48.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1259659 - rename from InternalUIEvent.detail to InternalUIEvent.mDetail. r=masayuki MozReview-Commit-ID: FjqZ5D2NCFb
dom/base/Element.cpp
dom/events/UIEvent.cpp
dom/html/HTMLButtonElement.cpp
dom/html/HTMLInputElement.cpp
dom/smil/TimeEvent.cpp
dom/smil/nsSMILTimedElement.cpp
widget/BasicEvents.h
--- a/dom/base/Element.cpp
+++ b/dom/base/Element.cpp
@@ -3010,17 +3010,17 @@ Element::PostHandleEventForLinks(EventCh
       // The default action is simply to dispatch DOMActivate
       nsCOMPtr<nsIPresShell> shell = aVisitor.mPresContext->GetPresShell();
       if (shell) {
         // single-click
         nsEventStatus status = nsEventStatus_eIgnore;
         // DOMActive event should be trusted since the activation is actually
         // occurred even if the cause is an untrusted click event.
         InternalUIEvent actEvent(true, eLegacyDOMActivate, mouseEvent);
-        actEvent.detail = 1;
+        actEvent.mDetail = 1;
 
         rv = shell->HandleDOMEventWithTarget(this, &actEvent, &status);
         if (NS_SUCCEEDED(rv)) {
           aVisitor.mEventStatus = nsEventStatus_eConsumeNoDefault;
         }
       }
     }
     break;
--- a/dom/events/UIEvent.cpp
+++ b/dom/events/UIEvent.cpp
@@ -45,17 +45,17 @@ UIEvent::UIEvent(EventTarget* aOwner,
     mEvent->time = PR_Now();
   }
   
   // Fill mDetail and mView according to the mEvent (widget-generated
   // event) we've got
   switch(mEvent->mClass) {
     case eUIEventClass:
     {
-      mDetail = mEvent->AsUIEvent()->detail;
+      mDetail = mEvent->AsUIEvent()->mDetail;
       break;
     }
 
     case eScrollPortEventClass:
     {
       InternalScrollPortEvent* scrollEvent = mEvent->AsScrollPortEvent();
       mDetail = (int32_t)scrollEvent->orient;
       break;
--- a/dom/html/HTMLButtonElement.cpp
+++ b/dom/html/HTMLButtonElement.cpp
@@ -248,17 +248,17 @@ HTMLButtonElement::PostHandleEvent(Event
   }
 
   if (aVisitor.mEventStatus != nsEventStatus_eConsumeNoDefault) {
     WidgetMouseEvent* mouseEvent = aVisitor.mEvent->AsMouseEvent();
     if (mouseEvent && mouseEvent->IsLeftClickEvent()) {
       // DOMActive event should be trusted since the activation is actually
       // occurred even if the cause is an untrusted click event.
       InternalUIEvent actEvent(true, eLegacyDOMActivate, mouseEvent);
-      actEvent.detail = 1;
+      actEvent.mDetail = 1;
 
       nsCOMPtr<nsIPresShell> shell = aVisitor.mPresContext->GetPresShell();
       if (shell) {
         nsEventStatus status = nsEventStatus_eIgnore;
         mInInternalActivate = true;
         shell->HandleDOMEventWithTarget(this, &actEvent, &status);
         mInInternalActivate = false;
 
--- a/dom/html/HTMLInputElement.cpp
+++ b/dom/html/HTMLInputElement.cpp
@@ -3776,17 +3776,17 @@ HTMLInputElement::PostHandleEvent(EventC
       !IsSingleLineTextControl(true) &&
       mType != NS_FORM_INPUT_NUMBER) {
     WidgetMouseEvent* mouseEvent = aVisitor.mEvent->AsMouseEvent();
     if (mouseEvent && mouseEvent->IsLeftClickEvent() &&
         !ShouldPreventDOMActivateDispatch(aVisitor.mEvent->originalTarget)) {
       // DOMActive event should be trusted since the activation is actually
       // occurred even if the cause is an untrusted click event.
       InternalUIEvent actEvent(true, eLegacyDOMActivate, mouseEvent);
-      actEvent.detail = 1;
+      actEvent.mDetail = 1;
 
       nsCOMPtr<nsIPresShell> shell = aVisitor.mPresContext->GetPresShell();
       if (shell) {
         nsEventStatus status = nsEventStatus_eIgnore;
         mInInternalActivate = true;
         rv = shell->HandleDOMEventWithTarget(this, &actEvent, &status);
         mInInternalActivate = false;
 
--- a/dom/smil/TimeEvent.cpp
+++ b/dom/smil/TimeEvent.cpp
@@ -14,17 +14,17 @@
 namespace mozilla {
 namespace dom {
 
 TimeEvent::TimeEvent(EventTarget* aOwner,
                      nsPresContext* aPresContext,
                      InternalSMILTimeEvent* aEvent)
   : Event(aOwner, aPresContext,
           aEvent ? aEvent : new InternalSMILTimeEvent(false, eVoidEvent))
-  , mDetail(mEvent->AsSMILTimeEvent()->detail)
+  , mDetail(mEvent->AsSMILTimeEvent()->mDetail)
 {
   if (aEvent) {
     mEventIsInternal = false;
   } else {
     mEventIsInternal = true;
   }
 
   if (mPresContext) {
--- a/dom/smil/nsSMILTimedElement.cpp
+++ b/dom/smil/nsSMILTimedElement.cpp
@@ -92,17 +92,17 @@ namespace
       , mMsg(aMsg)
       , mDetail(aDetail)
     {
     }
 
     NS_IMETHOD Run()
     {
       InternalSMILTimeEvent event(true, mMsg);
-      event.detail = mDetail;
+      event.mDetail = mDetail;
 
       nsPresContext* context = nullptr;
       nsIDocument* doc = mTarget->GetCurrentDoc();
       if (doc) {
         nsCOMPtr<nsIPresShell> shell = doc->GetShell();
         if (shell) {
           context = shell->GetPresContext();
         }
--- a/widget/BasicEvents.h
+++ b/widget/BasicEvents.h
@@ -820,79 +820,79 @@ public:
  *
  * XXX Why this inherits WidgetGUIEvent rather than WidgetEvent?
  ******************************************************************************/
 
 class InternalUIEvent : public WidgetGUIEvent
 {
 protected:
   InternalUIEvent()
-    : detail(0)
+    : mDetail(0)
     , mCausedByUntrustedEvent(false)
   {
   }
 
   InternalUIEvent(bool aIsTrusted, EventMessage aMessage, nsIWidget* aWidget,
                   EventClassID aEventClassID)
     : WidgetGUIEvent(aIsTrusted, aMessage, aWidget, aEventClassID)
-    , detail(0)
+    , mDetail(0)
     , mCausedByUntrustedEvent(false)
   {
   }
 
   InternalUIEvent(bool aIsTrusted, EventMessage aMessage,
                   EventClassID aEventClassID)
     : WidgetGUIEvent(aIsTrusted, aMessage, nullptr, aEventClassID)
-    , detail(0)
+    , mDetail(0)
     , mCausedByUntrustedEvent(false)
   {
   }
 
 public:
   virtual InternalUIEvent* AsUIEvent() override { return this; }
 
   /**
    * If the UIEvent is caused by another event (e.g., click event),
    * aEventCausesThisEvent should be the event.  If there is no such event,
    * this should be nullptr.
    */
   InternalUIEvent(bool aIsTrusted, EventMessage aMessage,
                   const WidgetEvent* aEventCausesThisEvent)
     : WidgetGUIEvent(aIsTrusted, aMessage, nullptr, eUIEventClass)
-    , detail(0)
+    , mDetail(0)
     , mCausedByUntrustedEvent(
         aEventCausesThisEvent && !aEventCausesThisEvent->IsTrusted())
   {
   }
 
   virtual WidgetEvent* Duplicate() const override
   {
     MOZ_ASSERT(mClass == eUIEventClass,
                "Duplicate() must be overridden by sub class");
     InternalUIEvent* result = new InternalUIEvent(false, mMessage, nullptr);
     result->AssignUIEventData(*this, true);
     result->mFlags = mFlags;
     return result;
   }
 
-  int32_t detail;
+  int32_t mDetail;
   // mCausedByUntrustedEvent is true if the event is caused by untrusted event.
   bool mCausedByUntrustedEvent;
 
   // If you check the event is a trusted event and NOT caused by an untrusted
   // event, IsTrustable() returns what you expected.
   bool IsTrustable() const
   {
     return IsTrusted() && !mCausedByUntrustedEvent;
   }
 
   void AssignUIEventData(const InternalUIEvent& aEvent, bool aCopyTargets)
   {
     AssignGUIEventData(aEvent, aCopyTargets);
 
-    detail = aEvent.detail;
+    mDetail = aEvent.mDetail;
     mCausedByUntrustedEvent = aEvent.mCausedByUntrustedEvent;
   }
 };
 
 } // namespace mozilla
 
 #endif // mozilla_BasicEvents_h__