Backed out changeset dad95d849302 (bug 1479591) for causing linux debug leaks and security issues.
authorCosmin Sabou <csabou@mozilla.com>
Wed, 15 Aug 2018 04:39:43 +0300
changeset 486697 9e6ef0b94077b72e1b9bb4bb310bfb561cd94f07
parent 486696 a503a6d7177216541902c5a7732f1405708b1aac
child 486698 a699096ae193a22952e1dc33950047c8aad7dc42
push id9719
push userffxbld-merge
push dateFri, 24 Aug 2018 17:49:46 +0000
treeherdermozilla-beta@719ec98fba77 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1479591
milestone63.0a1
backs outdad95d849302c966da9a710e96c80e7882eec5c2
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
Backed out changeset dad95d849302 (bug 1479591) for causing linux debug leaks and security issues.
accessible/base/AccEvent.cpp
accessible/base/AccEvent.h
accessible/base/Platform.h
accessible/base/nsAccessibilityService.h
accessible/generic/Accessible.cpp
accessible/generic/DocAccessible.cpp
accessible/generic/DocAccessible.h
accessible/interfaces/moz.build
accessible/interfaces/nsIAccessibleEvent.idl
accessible/interfaces/nsIAccessibleScrollingEvent.idl
accessible/ipc/DocAccessibleParent.cpp
accessible/ipc/DocAccessibleParent.h
accessible/ipc/other/PDocAccessible.ipdl
accessible/ipc/win/PDocAccessible.ipdl
accessible/other/Platform.cpp
accessible/tests/browser/events.js
accessible/tests/browser/events/browser.ini
accessible/tests/browser/events/browser_test_scrolling.js
accessible/tests/mochitest/common.js
accessible/windows/msaa/nsEventMap.h
accessible/xpcom/AccEvents.conf
--- a/accessible/base/AccEvent.cpp
+++ b/accessible/base/AccEvent.cpp
@@ -271,18 +271,11 @@ a11y::MakeXPCEvent(AccEvent* aEvent)
     xpEvent = new xpcAccObjectAttributeChangedEvent(type,
                                                     ToXPC(acc),
                                                     ToXPCDocument(doc), node,
                                                     fromUser,
                                                     attribute);
     return xpEvent.forget();
   }
 
-  if (eventGroup & (1 << AccEvent::eScrollingEvent)) {
-    AccScrollingEvent* sa = downcast_accEvent(aEvent);
-    xpEvent = new xpcAccScrollingEvent(type, ToXPC(acc), ToXPCDocument(doc), node,
-                                       fromUser, sa->ScrollX(), sa->ScrollY(),
-                                       sa->MaxScrollX(), sa->MaxScrollY());
-  }
-
   xpEvent = new xpcAccEvent(type, ToXPC(acc), ToXPCDocument(doc), node, fromUser);
   return xpEvent.forget();
   }
--- a/accessible/base/AccEvent.h
+++ b/accessible/base/AccEvent.h
@@ -99,18 +99,17 @@ public:
     eReorderEvent,
     eHideEvent,
     eShowEvent,
     eCaretMoveEvent,
     eTextSelChangeEvent,
     eSelectionChangeEvent,
     eTableChangeEvent,
     eVirtualCursorChangeEvent,
-    eObjectAttrChangedEvent,
-    eScrollingEvent,
+    eObjectAttrChangedEvent
   };
 
   static const EventGroup kEventGroup = eGenericEvent;
   virtual unsigned int GetEventGroups() const
   {
     return 1U << eGenericEvent;
   }
 
@@ -544,56 +543,16 @@ public:
 
 private:
   RefPtr<nsAtom> mAttribute;
 
   virtual ~AccObjectAttrChangedEvent() { }
 };
 
 /**
- * Accessible scroll event.
- */
-class AccScrollingEvent : public AccEvent
-{
-public:
-  AccScrollingEvent(uint32_t aEventType, Accessible* aAccessible,
-                    uint32_t aScrollX, uint32_t aScrollY,
-                    uint32_t aMaxScrollX, uint32_t aMaxScrollY) :
-    AccEvent(aEventType, aAccessible),
-    mScrollX(aScrollX),
-    mScrollY(aScrollY),
-    mMaxScrollX(aMaxScrollX),
-    mMaxScrollY(aMaxScrollY) { }
-
-  virtual ~AccScrollingEvent() { }
-
-  // AccEvent
-  static const EventGroup kEventGroup = eScrollingEvent;
-  virtual unsigned int GetEventGroups() const override
-  {
-    return AccEvent::GetEventGroups() | (1U << eScrollingEvent);
-  }
-
-  // The X scrolling offset of the container when the event was fired.
-  uint32_t ScrollX() { return mScrollX; }
-  // The Y scrolling offset of the container when the event was fired.
-  uint32_t ScrollY() { return mScrollY; }
-  // The max X offset of the container.
-  uint32_t MaxScrollX() { return mMaxScrollX; }
-  // The max Y offset of the container.
-  uint32_t MaxScrollY() { return mMaxScrollY; }
-
-private:
-  uint32_t mScrollX;
-  uint32_t mScrollY;
-  uint32_t mMaxScrollX;
-  uint32_t mMaxScrollY;
-};
-
-/**
  * Downcast the generic accessible event object to derived type.
  */
 class downcast_accEvent
 {
 public:
   explicit downcast_accEvent(AccEvent* e) : mRawPtr(e) { }
 
   template<class Destination>
--- a/accessible/base/Platform.h
+++ b/accessible/base/Platform.h
@@ -108,17 +108,13 @@ void ProxyVirtualCursorChangeEvent(Proxy
                                    ProxyAccessible* aOldPosition,
                                    int32_t aOldStartOffset,
                                    int32_t aOldEndOffset,
                                    ProxyAccessible* aNewPosition,
                                    int32_t aNewStartOffset,
                                    int32_t aNewEndOffset,
                                    int16_t aReason, int16_t aBoundaryType,
                                    bool aFromUser);
-
-void ProxyScrollingEvent(ProxyAccessible* aTarget,
-                         uint32_t aScrollX, uint32_t aScrollY,
-                         uint32_t aMaxScrollX, uint32_t aMaxScrollY);
 #endif
 } // namespace a11y
 } // namespace mozilla
 
 #endif // mozilla_a11y_Platform_h
--- a/accessible/base/nsAccessibilityService.h
+++ b/accessible/base/nsAccessibilityService.h
@@ -468,12 +468,11 @@ static const char kEventTypeNames[][40] 
   "hypertext link activated",                // EVENT_HYPERTEXT_LINK_ACTIVATED
   "hypertext link selected",                 // EVENT_HYPERTEXT_LINK_SELECTED
   "hyperlink start index changed",           // EVENT_HYPERLINK_START_INDEX_CHANGED
   "hypertext changed",                       // EVENT_HYPERTEXT_CHANGED
   "hypertext links count changed",           // EVENT_HYPERTEXT_NLINKS_CHANGED
   "object attribute changed",                // EVENT_OBJECT_ATTRIBUTE_CHANGED
   "virtual cursor changed",                   // EVENT_VIRTUALCURSOR_CHANGED
   "text value change",                       // EVENT_TEXT_VALUE_CHANGE
-  "scrolling",                               // EVENT_SCROLLING
 };
 
 #endif
--- a/accessible/generic/Accessible.cpp
+++ b/accessible/generic/Accessible.cpp
@@ -947,24 +947,16 @@ Accessible::HandleAccEvent(AccEvent* aEv
           break;
         }
 #if defined(XP_WIN)
         case nsIAccessibleEvent::EVENT_FOCUS: {
           ipcDoc->SendFocusEvent(id);
           break;
         }
 #endif
-        case nsIAccessibleEvent::EVENT_SCROLLING_END:
-        case nsIAccessibleEvent::EVENT_SCROLLING: {
-          AccScrollingEvent* scrollingEvent = downcast_accEvent(aEvent);
-          ipcDoc->SendScrollingEvent(id, aEvent->GetEventType(),
-            scrollingEvent->ScrollX(), scrollingEvent->ScrollY(),
-            scrollingEvent->MaxScrollX(), scrollingEvent->MaxScrollY());
-          break;
-        }
         default:
           ipcDoc->SendEvent(id, aEvent->GetEventType());
       }
     }
   }
 
   if (nsCoreUtils::AccEventObserversExist()) {
     nsCoreUtils::DispatchAccEvent(MakeXPCEvent(aEvent));
--- a/accessible/generic/DocAccessible.cpp
+++ b/accessible/generic/DocAccessible.cpp
@@ -605,57 +605,57 @@ DocAccessible::RemoveEventListeners()
   return NS_OK;
 }
 
 void
 DocAccessible::ScrollTimerCallback(nsITimer* aTimer, void* aClosure)
 {
   DocAccessible* docAcc = reinterpret_cast<DocAccessible*>(aClosure);
 
-  if (docAcc) {
-    docAcc->DispatchScrollingEvent(nsIAccessibleEvent::EVENT_SCROLLING_END);
+  if (docAcc && docAcc->mScrollPositionChangedTicks &&
+      ++docAcc->mScrollPositionChangedTicks > 2) {
+    // Whenever scroll position changes, mScrollPositionChangeTicks gets reset to 1
+    // We only want to fire accessibilty scroll event when scrolling stops or pauses
+    // Therefore, we wait for no scroll events to occur between 2 ticks of this timer
+    // That indicates a pause in scrolling, so we fire the accessibilty scroll event
+    nsEventShell::FireEvent(nsIAccessibleEvent::EVENT_SCROLLING_END, docAcc);
 
+    docAcc->mScrollPositionChangedTicks = 0;
     if (docAcc->mScrollWatchTimer) {
+      docAcc->mScrollWatchTimer->Cancel();
       docAcc->mScrollWatchTimer = nullptr;
       NS_RELEASE(docAcc); // Release kung fu death grip
     }
   }
 }
 
 ////////////////////////////////////////////////////////////////////////////////
 // nsIScrollPositionListener
 
 void
 DocAccessible::ScrollPositionDidChange(nscoord aX, nscoord aY)
 {
-  const uint32_t kScrollEventInterval = 100;
-  TimeStamp timestamp = TimeStamp::Now();
-  if (mLastScrollingDispatch.IsNull() ||
-      (timestamp - mLastScrollingDispatch).ToMilliseconds() >= kScrollEventInterval) {
-    DispatchScrollingEvent(nsIAccessibleEvent::EVENT_SCROLLING);
-    mLastScrollingDispatch = timestamp;
-  }
-
-  // If timer callback is still pending, push it 100ms into the future.
-  // When scrolling ends and we don't fire this callback anymore, the
-  // timer callback will fire and dispatch an EVENT_SCROLLING_END.
+  // Start new timer, if the timer cycles at least 1 full cycle without more scroll position changes,
+  // then the ::Notify() method will fire the accessibility event for scroll position changes
+  const uint32_t kScrollPosCheckWait = 50;
   if (mScrollWatchTimer) {
-    mScrollWatchTimer->SetDelay(kScrollEventInterval);
+    mScrollWatchTimer->SetDelay(kScrollPosCheckWait);  // Create new timer, to avoid leaks
   }
   else {
     NS_NewTimerWithFuncCallback(getter_AddRefs(mScrollWatchTimer),
                                 ScrollTimerCallback,
                                 this,
-                                kScrollEventInterval,
-                                nsITimer::TYPE_ONE_SHOT,
+                                kScrollPosCheckWait,
+                                nsITimer::TYPE_REPEATING_SLACK,
                                 "a11y::DocAccessible::ScrollPositionDidChange");
     if (mScrollWatchTimer) {
       NS_ADDREF_THIS(); // Kung fu death grip
     }
   }
+  mScrollPositionChangedTicks = 1;
 }
 
 ////////////////////////////////////////////////////////////////////////////////
 // nsIObserver
 
 NS_IMETHODIMP
 DocAccessible::Observe(nsISupports* aSubject, const char* aTopic,
                        const char16_t* aData)
@@ -2438,29 +2438,8 @@ DocAccessible::IsLoadEventTarget() const
     // while there's no parent document yet).
     DocAccessible* parentDoc = ParentDocument();
     return parentDoc && parentDoc->HasLoadState(eCompletelyLoaded);
   }
 
   // It's content (not chrome) root document.
   return (treeItem->ItemType() == nsIDocShellTreeItem::typeContent);
 }
-
-void
-DocAccessible::DispatchScrollingEvent(uint32_t aEventType)
-{
-  nsIScrollableFrame* sf = mPresShell->GetRootScrollFrameAsScrollable();
-
-  int32_t appUnitsPerDevPixel = mPresShell->GetPresContext()->AppUnitsPerDevPixel();
-  LayoutDevicePoint scrollPoint = LayoutDevicePoint::FromAppUnits(
-    sf->GetScrollPosition(), appUnitsPerDevPixel) * mPresShell->GetResolution();
-
-  LayoutDeviceRect scrollRange = LayoutDeviceRect::FromAppUnits(
-    sf->GetScrollRange(), appUnitsPerDevPixel);
-  scrollRange.ScaleRoundOut(mPresShell->GetResolution());
-
-  RefPtr<AccEvent> event = new AccScrollingEvent(aEventType, this,
-                                                 scrollPoint.x, scrollPoint.y,
-                                                 scrollRange.width,
-                                                 scrollRange.height);
-
-  nsEventShell::FireEvent(event);
-}
--- a/accessible/generic/DocAccessible.h
+++ b/accessible/generic/DocAccessible.h
@@ -577,18 +577,16 @@ protected:
   /**
    * Used to fire scrolling end event after page scroll.
    *
    * @param aTimer    [in] the timer object
    * @param aClosure  [in] the document accessible where scrolling happens
    */
   static void ScrollTimerCallback(nsITimer* aTimer, void* aClosure);
 
-  void DispatchScrollingEvent(uint32_t aEventType);
-
 protected:
 
   /**
    * State and property flags, kept by mDocFlags.
    */
   enum {
     // Whether scroll listeners were added.
     eScrollInitialized = 1 << 0,
@@ -600,19 +598,18 @@ protected:
   /**
    * Cache of accessibles within this document accessible.
    */
   AccessibleHashtable mAccessibleCache;
   nsDataHashtable<nsPtrHashKey<const nsINode>, Accessible*>
     mNodeToAccessibleMap;
 
   nsIDocument* mDocumentNode;
-  nsCOMPtr<nsITimer> mScrollWatchTimer;
-  uint16_t mScrollPositionChangedTicks; // Used for tracking scroll events
-  TimeStamp mLastScrollingDispatch;
+    nsCOMPtr<nsITimer> mScrollWatchTimer;
+    uint16_t mScrollPositionChangedTicks; // Used for tracking scroll events
 
   /**
    * Bit mask of document load states (@see LoadState).
    */
   uint32_t mLoadState : 3;
 
   /**
    * Bit mask of other states and props.
--- a/accessible/interfaces/moz.build
+++ b/accessible/interfaces/moz.build
@@ -18,17 +18,16 @@ XPIDL_SOURCES += [
     'nsIAccessibleHideEvent.idl',
     'nsIAccessibleHyperLink.idl',
     'nsIAccessibleHyperText.idl',
     'nsIAccessibleImage.idl',
     'nsIAccessibleObjectAttributeChangedEvent.idl',
     'nsIAccessiblePivot.idl',
     'nsIAccessibleRelation.idl',
     'nsIAccessibleRole.idl',
-    'nsIAccessibleScrollingEvent.idl',
     'nsIAccessibleSelectable.idl',
     'nsIAccessibleStateChangeEvent.idl',
     'nsIAccessibleStates.idl',
     'nsIAccessibleTable.idl',
     'nsIAccessibleTableChangeEvent.idl',
     'nsIAccessibleText.idl',
     'nsIAccessibleTextChangeEvent.idl',
     'nsIAccessibleTextRange.idl',
--- a/accessible/interfaces/nsIAccessibleEvent.idl
+++ b/accessible/interfaces/nsIAccessibleEvent.idl
@@ -414,24 +414,19 @@ interface nsIAccessibleEvent : nsISuppor
   const unsigned long EVENT_VIRTUALCURSOR_CHANGED = 0x0056;
 
   /**
    * An object's text Value has changed.
    */
   const unsigned long EVENT_TEXT_VALUE_CHANGE = 0x0057;
 
   /**
-   * An accessible's viewport is scrolling.
-   */
-  const unsigned long EVENT_SCROLLING = 0x0058;
-
-  /**
    * Help make sure event map does not get out-of-line.
    */
-  const unsigned long EVENT_LAST_ENTRY = 0x0059;
+  const unsigned long EVENT_LAST_ENTRY = 0x0058;
 
   /**
    * The type of event, based on the enumerated event values
    * defined in this interface.
    */
   readonly attribute unsigned long eventType;
   
   /**
deleted file mode 100644
--- a/accessible/interfaces/nsIAccessibleScrollingEvent.idl
+++ /dev/null
@@ -1,34 +0,0 @@
-/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-#include "nsIAccessibleEvent.idl"
-
-/*
- * An interface scroll events.
- * Stores new scroll position and max scroll position.
- */
-[scriptable, builtinclass, uuid(f75f0b32-5342-4d60-b1a5-b7bd6888eef5)]
-interface nsIAccessibleScrollingEvent : nsIAccessibleEvent
-{
-  /**
-   * New X scroll position within a scrollable container in device pixels.
-   */
-  readonly attribute unsigned long scrollX;
-
-  /**
-   * New Y scroll position within a scrollable container in device pixels.
-   */
-  readonly attribute unsigned long scrollY;
-
-  /**
-  * Max X scroll position within a scrollable container in device pixels.
-   */
-  readonly attribute unsigned long maxScrollX;
-
-  /**
-   * Max Y scroll position within a scrollable container in device pixels.
-   */
-  readonly attribute unsigned long maxScrollY;
-};
--- a/accessible/ipc/DocAccessibleParent.cpp
+++ b/accessible/ipc/DocAccessibleParent.cpp
@@ -422,42 +422,16 @@ DocAccessibleParent::RecvVirtualCursorCh
                                        aNewStartOffset, aNewEndOffset,
                                        aBoundaryType, aReason);
   nsCoreUtils::DispatchAccEvent(std::move(event));
 
   return IPC_OK();
 }
 
 mozilla::ipc::IPCResult
-DocAccessibleParent::RecvScrollingEvent(const uint64_t& aID,
-                                        const uint64_t& aType,
-                                        const uint32_t& aScrollX,
-                                        const uint32_t& aScrollY,
-                                        const uint32_t& aMaxScrollX,
-                                        const uint32_t& aMaxScrollY)
-{
-  ProxyAccessible* target = GetAccessible(aID);
-
-#if defined(ANDROID)
-  ProxyScrollingEvent(target, aScrollX, aScrollY, aMaxScrollX, aMaxScrollY);
-#endif
-
-  xpcAccessibleGeneric* xpcAcc = GetXPCAccessible(target);
-  xpcAccessibleDocument* doc = GetAccService()->GetXPCDocument(this);
-  nsINode* node = nullptr;
-  bool fromUser = true; // XXX: Determine if this was from user input.
-  RefPtr<xpcAccScrollingEvent> event =
-    new xpcAccScrollingEvent(aType, xpcAcc, doc, node, fromUser, aScrollX,
-                             aScrollY, aMaxScrollX, aMaxScrollY);
-  nsCoreUtils::DispatchAccEvent(std::move(event));
-
-  return IPC_OK();
-}
-
-mozilla::ipc::IPCResult
 DocAccessibleParent::RecvRoleChangedEvent(const a11y::role& aRole)
 {
   if (mShutdown) {
     return IPC_OK();
   }
 
   mRole = aRole;
   return IPC_OK();
--- a/accessible/ipc/DocAccessibleParent.h
+++ b/accessible/ipc/DocAccessibleParent.h
@@ -112,23 +112,16 @@ public:
                                                                const int32_t& aOldEndOffset,
                                                                const uint64_t& aNewPositionID,
                                                                const int32_t& aNewStartOffset,
                                                                const int32_t& aNewEndOffset,
                                                                const int16_t& aReason,
                                                                const int16_t& aBoundaryType,
                                                                const bool& aFromUser) override;
 
-  virtual mozilla::ipc::IPCResult RecvScrollingEvent(const uint64_t& aID,
-                                                     const uint64_t& aType,
-                                                     const uint32_t& aScrollX,
-                                                     const uint32_t& aScrollY,
-                                                     const uint32_t& aMaxScrollX,
-                                                     const uint32_t& aMaxScrollY) override;
-
   mozilla::ipc::IPCResult RecvRoleChangedEvent(const a11y::role& aRole) final;
 
   virtual mozilla::ipc::IPCResult RecvBindChildDoc(PDocAccessibleParent* aChildDoc, const uint64_t& aID) override;
 
   void Unbind()
   {
     if (DocAccessibleParent* parent = ParentDoc()) {
       parent->RemoveChildDoc(this);
--- a/accessible/ipc/other/PDocAccessible.ipdl
+++ b/accessible/ipc/other/PDocAccessible.ipdl
@@ -67,19 +67,16 @@ parent:
   async RoleChangedEvent(role aRole);
   async VirtualCursorChangeEvent(uint64_t aID,
                                  uint64_t aOldPosition,
                                  int32_t aOldStartOffset, int32_t aOldEndOffset,
                                  uint64_t aPosition,
                                  int32_t aStartOffset, int32_t aEndOffset,
                                  int16_t aReason, int16_t aBoundaryType,
                                  bool aFromUservcEvent);
-  async ScrollingEvent(uint64_t aID, uint64_t aType,
-                       uint32_t aScrollX, uint32_t aScrollY,
-                       uint32_t aMaxScrollX, uint32_t aMaxScrollY);
 
   /*
    * Tell the parent document to bind the existing document as a new child
    * document.
    */
   async BindChildDoc(PDocAccessible aChildDoc, uint64_t aID);
 
 child:
--- a/accessible/ipc/win/PDocAccessible.ipdl
+++ b/accessible/ipc/win/PDocAccessible.ipdl
@@ -65,19 +65,16 @@ parent:
   async FocusEvent(uint64_t aID, LayoutDeviceIntRect aCaretRect);
   async VirtualCursorChangeEvent(uint64_t aID,
                                  uint64_t aOldPosition,
                                  int32_t aOldStartOffset, int32_t aOldEndOffset,
                                  uint64_t aPosition,
                                  int32_t aStartOffset, int32_t aEndOffset,
                                  int16_t aReason, int16_t aBoundaryType,
                                  bool aFromUservcEvent);
-  async ScrollingEvent(uint64_t aID, uint64_t aType,
-                       uint32_t aScrollX, uint32_t aScrollY,
-                       uint32_t aMaxScrollX, uint32_t aMaxScrollY);
 
   /*
    * Tell the parent document to bind the existing document as a new child
    * document.
    */
   async BindChildDoc(PDocAccessible aChildDoc, uint64_t aID);
 
   sync GetWindowedPluginIAccessible(WindowsHandle aHwnd)
--- a/accessible/other/Platform.cpp
+++ b/accessible/other/Platform.cpp
@@ -62,14 +62,9 @@ a11y::ProxySelectionEvent(ProxyAccessibl
 
 #if defined(ANDROID)
 void
 a11y::ProxyVirtualCursorChangeEvent(ProxyAccessible*, ProxyAccessible*,
                                     int32_t, int32_t, ProxyAccessible*,
                                     int32_t, int32_t, int16_t, int16_t, bool)
 {
 }
-
-void
-a11y::ProxyScrollingEvent(ProxyAccessible*, uint32_t, uint32_t, uint32_t, uint32_t)
-{
-}
 #endif
--- a/accessible/tests/browser/events.js
+++ b/accessible/tests/browser/events.js
@@ -4,30 +4,27 @@
 
 "use strict";
 
 // This is loaded by head.js, so has the same globals, hence we import the
 // globals from there.
 /* import-globals-from shared-head.js */
 /* import-globals-from ../mochitest/common.js */
 
-/* exported EVENT_REORDER, EVENT_SCROLLING, EVENT_SCROLLING_END, EVENT_SHOW,
-            EVENT_TEXT_INSERTED, EVENT_TEXT_REMOVED,
+/* exported EVENT_REORDER, EVENT_SHOW, EVENT_TEXT_INSERTED, EVENT_TEXT_REMOVED,
             EVENT_DOCUMENT_LOAD_COMPLETE, EVENT_HIDE, EVENT_TEXT_CARET_MOVED,
             EVENT_DESCRIPTION_CHANGE, EVENT_NAME_CHANGE, EVENT_STATE_CHANGE,
             EVENT_VALUE_CHANGE, EVENT_TEXT_VALUE_CHANGE, EVENT_FOCUS,
             EVENT_DOCUMENT_RELOAD, EVENT_VIRTUALCURSOR_CHANGED,
             UnexpectedEvents, contentSpawnMutation, waitForEvent, waitForEvents,
             waitForOrderedEvents */
 
 const EVENT_DOCUMENT_LOAD_COMPLETE = nsIAccessibleEvent.EVENT_DOCUMENT_LOAD_COMPLETE;
 const EVENT_HIDE = nsIAccessibleEvent.EVENT_HIDE;
 const EVENT_REORDER = nsIAccessibleEvent.EVENT_REORDER;
-const EVENT_SCROLLING = nsIAccessibleEvent.EVENT_SCROLLING;
-const EVENT_SCROLLING_END = nsIAccessibleEvent.EVENT_SCROLLING_END;
 const EVENT_SHOW = nsIAccessibleEvent.EVENT_SHOW;
 const EVENT_STATE_CHANGE = nsIAccessibleEvent.EVENT_STATE_CHANGE;
 const EVENT_TEXT_CARET_MOVED = nsIAccessibleEvent.EVENT_TEXT_CARET_MOVED;
 const EVENT_TEXT_INSERTED = nsIAccessibleEvent.EVENT_TEXT_INSERTED;
 const EVENT_TEXT_REMOVED = nsIAccessibleEvent.EVENT_TEXT_REMOVED;
 const EVENT_DESCRIPTION_CHANGE = nsIAccessibleEvent.EVENT_DESCRIPTION_CHANGE;
 const EVENT_NAME_CHANGE = nsIAccessibleEvent.EVENT_NAME_CHANGE;
 const EVENT_VALUE_CHANGE = nsIAccessibleEvent.EVENT_VALUE_CHANGE;
--- a/accessible/tests/browser/events/browser.ini
+++ b/accessible/tests/browser/events/browser.ini
@@ -2,12 +2,11 @@
 support-files =
   head.js
   !/accessible/tests/browser/events.js
   !/accessible/tests/browser/shared-head.js
   !/accessible/tests/mochitest/*.js
 
 [browser_test_docload.js]
 skip-if = e10s
-[browser_test_scrolling.js]
 [browser_test_textcaret.js]
 [browser_test_focus_browserui.js]
 [browser_test_focus_dialog.js]
deleted file mode 100644
--- a/accessible/tests/browser/events/browser_test_scrolling.js
+++ /dev/null
@@ -1,50 +0,0 @@
-/* This Source Code Form is subject to the terms of the Mozilla Public
- * License, v. 2.0. If a copy of the MPL was not distributed with this
- * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
-
-"use strict";
-
-addAccessibleTask(`
-    <div style="height: 100vh" id="one">one</div>
-    <div style="height: 100vh" id="two">two</div>
-    <div style="height: 100vh; width: 200vw" id="three">three</div>`,
-  async function(browser, accDoc) {
-    let onScrolling = waitForEvents([
-      [EVENT_SCROLLING, accDoc], [EVENT_SCROLLING_END, accDoc]]);
-    await ContentTask.spawn(browser, null, () => {
-      content.location.hash = "#two";
-    });
-    let [scrollEvent1, scrollEndEvent1] = await onScrolling;
-    scrollEvent1.QueryInterface(nsIAccessibleScrollingEvent);
-    ok(scrollEvent1.maxScrollY >= scrollEvent1.scrollY, "scrollY is within max");
-    scrollEndEvent1.QueryInterface(nsIAccessibleScrollingEvent);
-    ok(scrollEndEvent1.maxScrollY >= scrollEndEvent1.scrollY,
-      "scrollY is within max");
-
-    onScrolling = waitForEvents([
-      [EVENT_SCROLLING, accDoc], [EVENT_SCROLLING_END, accDoc]]);
-    await ContentTask.spawn(browser, null, () => {
-      content.location.hash = "#three";
-    });
-    let [scrollEvent2, scrollEndEvent2] = await onScrolling;
-    scrollEvent2.QueryInterface(nsIAccessibleScrollingEvent);
-    ok(scrollEvent2.scrollY > scrollEvent1.scrollY,
-      `${scrollEvent2.scrollY} > ${scrollEvent1.scrollY}`);
-    scrollEndEvent2.QueryInterface(nsIAccessibleScrollingEvent);
-    ok(scrollEndEvent2.maxScrollY >= scrollEndEvent2.scrollY,
-      "scrollY is within max");
-
-    onScrolling = waitForEvents([
-      [EVENT_SCROLLING, accDoc], [EVENT_SCROLLING_END, accDoc]]);
-    await ContentTask.spawn(browser, null, () => {
-      content.scrollTo(10, 0);
-    });
-    let [scrollEvent3, scrollEndEvent3] = await onScrolling;
-    scrollEvent3.QueryInterface(nsIAccessibleScrollingEvent);
-    ok(scrollEvent3.maxScrollX >= scrollEvent3.scrollX, "scrollX is within max");
-    scrollEndEvent3.QueryInterface(nsIAccessibleScrollingEvent);
-    ok(scrollEndEvent3.maxScrollX >= scrollEndEvent3.scrollX,
-      "scrollY is within max");
-    ok(scrollEvent3.scrollX > scrollEvent2.scrollX,
-      `${scrollEvent3.scrollX} > ${scrollEvent2.scrollX}`);
-  });
--- a/accessible/tests/mochitest/common.js
+++ b/accessible/tests/mochitest/common.js
@@ -3,18 +3,16 @@
 
 const nsIAccessibilityService = Ci.nsIAccessibilityService;
 
 const nsIAccessibleEvent = Ci.nsIAccessibleEvent;
 const nsIAccessibleStateChangeEvent =
   Ci.nsIAccessibleStateChangeEvent;
 const nsIAccessibleCaretMoveEvent =
   Ci.nsIAccessibleCaretMoveEvent;
-const nsIAccessibleScrollingEvent =
-  Ci.nsIAccessibleScrollingEvent;
 const nsIAccessibleTextChangeEvent =
   Ci.nsIAccessibleTextChangeEvent;
 const nsIAccessibleVirtualCursorChangeEvent =
   Ci.nsIAccessibleVirtualCursorChangeEvent;
 const nsIAccessibleObjectAttributeChangedEvent =
   Ci.nsIAccessibleObjectAttributeChangedEvent;
 
 const nsIAccessibleStates = Ci.nsIAccessibleStates;
--- a/accessible/windows/msaa/nsEventMap.h
+++ b/accessible/windows/msaa/nsEventMap.h
@@ -93,11 +93,11 @@ static const uint32_t gWinEventMap[] = {
   IA2_EVENT_HYPERLINK_SELECTED_LINK_CHANGED,         // nsIAccessibleEvent::EVENT_HYPERLINK_SELECTED_LINK_CHANGED
   IA2_EVENT_HYPERTEXT_LINK_ACTIVATED,                // nsIAccessibleEvent::EVENT_HYPERTEXT_LINK_ACTIVATED
   IA2_EVENT_HYPERTEXT_LINK_SELECTED,                 // nsIAccessibleEvent::EVENT_HYPERTEXT_LINK_SELECTED
   IA2_EVENT_HYPERLINK_START_INDEX_CHANGED,           // nsIAccessibleEvent::EVENT_HYPERLINK_START_INDEX_CHANGED
   IA2_EVENT_HYPERTEXT_CHANGED,                       // nsIAccessibleEvent::EVENT_HYPERTEXT_CHANGED
   IA2_EVENT_HYPERTEXT_NLINKS_CHANGED,                // nsIAccessibleEvent::EVENT_HYPERTEXT_NLINKS_CHANGED
   IA2_EVENT_OBJECT_ATTRIBUTE_CHANGED,                // nsIAccessibleEvent::EVENT_OBJECT_ATTRIBUTE_CHANGED
   kEVENT_WIN_UNKNOWN,                                 // nsIAccessibleEvent::EVENT_VIRTUALCURSOR_CHANGED
-  EVENT_OBJECT_VALUECHANGE,                          // nsIAccessibleEvent::EVENT_TEXT_VALUE_CHANGE
-  kEVENT_WIN_UNKNOWN,                                // nsIAccessibleEvent::EVENT_SCROLLING
+  EVENT_OBJECT_VALUECHANGE                          // nsIAccessibleEvent::EVENT_TEXT_VALUE_CHANGE
 };
+
--- a/accessible/xpcom/AccEvents.conf
+++ b/accessible/xpcom/AccEvents.conf
@@ -9,11 +9,10 @@
 simple_events = [
     'Event',
     'StateChangeEvent',
     'TextChangeEvent',
     'HideEvent',
     'CaretMoveEvent',
     'ObjectAttributeChangedEvent',
     'TableChangeEvent',
-    'VirtualCursorChangeEvent',
-    'ScrollingEvent'
+    'VirtualCursorChangeEvent'
   ]