OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #ifndef CC_INPUT_MAIN_THREAD_SCROLLING_REASON_H_ | |
6 #define CC_INPUT_MAIN_THREAD_SCROLLING_REASON_H_ | |
7 | |
8 namespace cc { | |
9 | |
10 // Ensure this stays in sync with MainThreadScrollingReason in histograms.xml, | |
11 // and that this extends ScrollingCoordinator::MainThreadScrollingReason. | |
12 // ScrollingCoordinator::MainThreadScrollingReason contains the flags | |
13 // which are associated with a layer. The flags only contained in | |
14 // MainThreadScrollingReason are computed for each scroll begin. | |
15 struct MainThreadScrollingReason { | |
16 // Non-transient scrolling reasons. | |
17 enum : uint32_t { kNotScrollingOnMain = 0 }; | |
18 enum : uint32_t { kHasBackgroundAttachmentFixedObjects = 1 << 0 }; | |
19 // TODO(tdresser): Unused. Remove? | |
20 enum : uint32_t { kHasNonLayerViewportConstrainedObjects = 1 << 1 }; | |
21 // TODO(tdresser): Unused. Remove? | |
22 enum : uint32_t { kThreadedScrollingDisabled = 1 << 2 }; | |
23 enum : uint32_t { kScrollbarScrolling = 1 << 3 }; | |
24 // TODO(tdresser): Unused. Remove? | |
25 enum : uint32_t { kPageOverlay = 1 << 4 }; | |
26 enum : uint32_t { kMaxNonTransientScrollingReason = kPageOverlay }; | |
tdresser
2016/01/20 15:17:27
These will be used after your other change.
See h
danakj
2016/01/20 21:00:01
Done.
| |
27 | |
28 // Transcient scrolling reasons. | |
tdresser
2016/01/20 15:17:27
Can you fix my spelling here too?
"Transient"
Tha
danakj
2016/01/20 21:00:01
Done.
| |
29 enum : uint32_t { kNonFastScrollableRegion = 1 << 5 }; | |
30 enum : uint32_t { kEventHandlers = 1 << 6 }; | |
31 enum : uint32_t { kFailedHitTest = 1 << 7 }; | |
32 enum : uint32_t { kNoScrollingLayer = 1 << 8 }; | |
33 enum : uint32_t { kNotScrollable = 1 << 9 }; | |
34 enum : uint32_t { kContinuingMainThreadScroll = 1 << 10 }; | |
35 enum : uint32_t { kNonInvertibleTransform = 1 << 11 }; | |
36 | |
37 // The number of flags in this struct (excluding itself). | |
38 enum : uint32_t { kMainThreadScrollingReasonCount = 13 }; | |
39 }; | |
40 | |
41 } // namespace cc | |
42 | |
43 #endif // CC_INPUT_MAIN_THREAD_SCROLLING_REASON_H_ | |
OLD | NEW |