Bug 1259671 part.3 Rename InternalScrollPortEvent::horizontal to InternalScrollPortEvent::eHorizontal r?smaug draft
authorMasayuki Nakano <masayuki@d-toybox.com>
Wed, 30 Mar 2016 17:33:16 +0900
changeset 346176 d200e9972499079e630cac6de5e52a744dadfc23
parent 346175 589960063b62c39d7c5afe39434e95476bc3e00b
child 346177 d041969bb0ebf90835399df69827361b80a14ebf
push id14266
push usermasayuki@d-toybox.com
push dateThu, 31 Mar 2016 06:03:50 +0000
reviewerssmaug
bugs1259671
milestone48.0a1
Bug 1259671 part.3 Rename InternalScrollPortEvent::horizontal to InternalScrollPortEvent::eHorizontal r?smaug MozReview-Commit-ID: JkT44G2FpUH
layout/generic/nsGfxScrollFrame.cpp
layout/xul/tree/nsTreeBodyFrame.cpp
widget/ContentEvents.h
--- a/layout/generic/nsGfxScrollFrame.cpp
+++ b/layout/generic/nsGfxScrollFrame.cpp
@@ -4131,23 +4131,23 @@ ScrollFrameHelper::FireScrollPortEvent()
     if (horizChanged) {
       // We need to dispatch a separate horizontal DOM event. Do that the next
       // time around since dispatching the vertical DOM event might destroy
       // the frame.
       PostOverflowEvent();
     }
   }
   else {
-    orient = InternalScrollPortEvent::horizontal;
+    orient = InternalScrollPortEvent::eHorizontal;
     mHorizontalOverflow = newHorizontalOverflow;
   }
 
   InternalScrollPortEvent event(true,
-    (orient == InternalScrollPortEvent::horizontal ? mHorizontalOverflow :
-                                                     mVerticalOverflow) ?
+    (orient == InternalScrollPortEvent::eHorizontal ? mHorizontalOverflow :
+                                                      mVerticalOverflow) ?
     eScrollPortOverflow : eScrollPortUnderflow, nullptr);
   event.orient = orient;
   return EventDispatcher::Dispatch(mOuter->GetContent(),
                                    mOuter->PresContext(), &event);
 }
 
 void
 ScrollFrameHelper::ReloadChildFrames()
--- a/layout/xul/tree/nsTreeBodyFrame.cpp
+++ b/layout/xul/tree/nsTreeBodyFrame.cpp
@@ -922,17 +922,17 @@ nsTreeBodyFrame::CheckOverflow(const Scr
     event.orient = InternalScrollPortEvent::eVertical;
     EventDispatcher::Dispatch(content, presContext, &event);
   }
 
   if (horizontalOverflowChanged) {
     InternalScrollPortEvent event(true,
       mHorizontalOverflow ? eScrollPortOverflow : eScrollPortUnderflow,
       nullptr);
-    event.orient = InternalScrollPortEvent::horizontal;
+    event.orient = InternalScrollPortEvent::eHorizontal;
     EventDispatcher::Dispatch(content, presContext, &event);
   }
 
   // The synchronous event dispatch above can trigger reflow notifications.
   // Flush those explicitly now, so that we can guard against potential infinite
   // recursion. See bug 905909.
   if (!weakFrame.IsAlive()) {
     return;
--- a/widget/ContentEvents.h
+++ b/widget/ContentEvents.h
@@ -29,17 +29,17 @@ public:
   virtual InternalScrollPortEvent* AsScrollPortEvent() override
   {
     return this;
   }
 
   enum OrientType
   {
     eVertical,
-    horizontal = 1,
+    eHorizontal,
     both       = 2
   };
 
   InternalScrollPortEvent(bool aIsTrusted, EventMessage aMessage,
                           nsIWidget* aWidget)
     : WidgetGUIEvent(aIsTrusted, aMessage, aWidget, eScrollPortEventClass)
     , orient(eVertical)
   {