Backed out changeset f879b73eb504 (bug 1341230)
authorIris Hsiao <ihsiao@mozilla.com>
Mon, 06 Mar 2017 11:48:52 +0800
changeset 394961 06734b1a543644d34128a5a921179230ea35510b
parent 394960 bbdc5fc3db27ecab0a69bb884cd2cb677aa09fe2
child 394962 95e0ba5f61da61b642f089ae1df84f55e7a52595
push id1468
push userasasaki@mozilla.com
push dateMon, 05 Jun 2017 19:31:07 +0000
treeherdermozilla-release@0641fc6ee9d1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1341230
milestone54.0a1
backs outf879b73eb504400f64b52bb84efdb2b6af8309c7
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 f879b73eb504 (bug 1341230)
dom/base/Element.h
dom/events/EventStates.h
--- a/dom/base/Element.h
+++ b/dom/base/Element.h
@@ -529,30 +529,16 @@ protected:
   virtual void RemoveStates(EventStates aStates)
   {
     NS_PRECONDITION(!aStates.HasAtLeastOneOfStates(INTRINSIC_STATES),
                     "Should only be removing externally-managed states here");
     RemoveStatesSilently(aStates);
     NotifyStateChange(aStates);
   }
 public:
-  // Public methods to manage state bits in MANUALLY_MANAGED_STATES.
-  void AddManuallyManagedStates(EventStates aStates)
-  {
-    MOZ_ASSERT(MANUALLY_MANAGED_STATES.HasAllStates(aStates),
-               "Should only be adding manually-managed states here");
-    AddStates(aStates);
-  }
-  void RemoveManuallyManagedStates(EventStates aStates)
-  {
-    MOZ_ASSERT(MANUALLY_MANAGED_STATES.HasAllStates(aStates),
-               "Should only be removing manually-managed states here");
-    RemoveStates(aStates);
-  }
-
   virtual void UpdateEditableState(bool aNotify) override;
 
   virtual nsresult BindToTree(nsIDocument* aDocument, nsIContent* aParent,
                               nsIContent* aBindingParent,
                               bool aCompileEventHandlers) override;
   virtual void UnbindFromTree(bool aDeep = true,
                               bool aNullParent = true) override;
 
--- a/dom/events/EventStates.h
+++ b/dom/events/EventStates.h
@@ -309,33 +309,21 @@ private:
 #define NS_EVENT_STATE_IGNORE NS_DEFINE_EVENT_STATE_MACRO(63)
 
 /**
  * NOTE: do not go over 63 without updating EventStates::InternalType!
  */
 
 #define DIRECTION_STATES (NS_EVENT_STATE_LTR | NS_EVENT_STATE_RTL)
 
-// Event states that can be added and removed through
-// Element::{Add,Remove}ManuallyManagedStates.
-//
-// Take care when manually managing state bits.  You are responsible for
-// setting or clearing the bit when an Element is added or removed from a
-// document (e.g. in BindToTree and UnbindFromTree), if that is an
-// appropriate thing to do for your state bit.
-#define MANUALLY_MANAGED_STATES (             \
-  mozilla::EventStates() /* none so far */    \
-)
-
 // Event states that are managed externally to an element (by the
 // EventStateManager, or by other code).  As opposed to those in
 // INTRINSIC_STATES, which are are computed by the element itself
 // and returned from Element::IntrinsicState.
 #define EXTERNALLY_MANAGED_STATES (           \
-  MANUALLY_MANAGED_STATES |                   \
   NS_EVENT_STATE_ACTIVE |                     \
   NS_EVENT_STATE_DRAGOVER |                   \
   NS_EVENT_STATE_FOCUS |                      \
   NS_EVENT_STATE_FOCUSRING |                  \
   NS_EVENT_STATE_FOCUS_WITHIN |               \
   NS_EVENT_STATE_FULL_SCREEN |                \
   NS_EVENT_STATE_HOVER |                      \
   NS_EVENT_STATE_UNRESOLVED |                 \