From 41afd1bff762c2eed30f4ef207038847e39013f5 Mon Sep 17 00:00:00 2001 From: Botond Ballo Date: Fri, 5 Oct 2018 20:52:48 +0000 Subject: [PATCH] Bug 1496830 - Annotate CompositorHitTestFlags enumerators with the value they contribute to an EnumSet. r=kats Differential Revision: https://phabricator.services.mozilla.com/D7920 --HG-- extra : moz-landing-system : lando --- gfx/src/CompositorHitTestInfo.h | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/gfx/src/CompositorHitTestInfo.h b/gfx/src/CompositorHitTestInfo.h index 267cae144574..68ee17688888 100644 --- a/gfx/src/CompositorHitTestInfo.h +++ b/gfx/src/CompositorHitTestInfo.h @@ -18,35 +18,37 @@ namespace gfx { // intentionally set up so that if all of them are 0 the item is effectively // invisible to hit-testing, and no information for this frame needs to be // sent to the compositor. +// Each enumerator is annotated with the value it contributes to an +// EnumSet (2 ^ ), in hexadecimal. enum class CompositorHitTestFlags : uint8_t { // The frame participates in hit-testing - eVisibleToHitTest = 0, + eVisibleToHitTest = 0, // 0x001 // The frame requires main-thread handling for events - eDispatchToContent, + eDispatchToContent, // 0x002 // The touch action flags are set up so that the default of // touch-action:auto on an element leaves all the flags as 0. - eTouchActionPanXDisabled, - eTouchActionPanYDisabled, - eTouchActionPinchZoomDisabled, - eTouchActionDoubleTapZoomDisabled, + eTouchActionPanXDisabled, // 0x004 + eTouchActionPanYDisabled, // 0x008 + eTouchActionPinchZoomDisabled, // 0x010 + eTouchActionDoubleTapZoomDisabled, // 0x020 // The frame is a scrollbar or a subframe inside a scrollbar (including // scroll thumbs) - eScrollbar, + eScrollbar, // 0x040 // The frame is a scrollthumb. If this is set then eScrollbar will also be // set, unless gecko somehow generates a scroll thumb without a containing // scrollbar. - eScrollbarThumb, + eScrollbarThumb, // 0x080 // If eScrollbar is set, this flag indicates if the scrollbar is a vertical // one (if set) or a horizontal one (if not set) - eScrollbarVertical, + eScrollbarVertical, // 0x100 // Events targeting this frame should only be processed if a target // confirmation is received from the main thread. If no such confirmation // is received within a timeout period, the event may be dropped. // Only meaningful in combination with eDispatchToContent. - eRequiresTargetConfirmation, + eRequiresTargetConfirmation, // 0x200 }; using CompositorHitTestInfo = EnumSet;