Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(526)

Side by Side Diff: cc/input/main_thread_scrolling_reason.h

Issue 1602773006: blink: Make WebMainThreadScrollingReason wrap the cc enum. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: enumwrap: rebase Created 4 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CC_INPUT_MAIN_THREAD_SCROLLING_REASON_H_ 5 #ifndef CC_INPUT_MAIN_THREAD_SCROLLING_REASON_H_
6 #define CC_INPUT_MAIN_THREAD_SCROLLING_REASON_H_ 6 #define CC_INPUT_MAIN_THREAD_SCROLLING_REASON_H_
7 7
8 namespace cc { 8 namespace cc {
9 9
10 // Ensure this stays in sync with MainThreadScrollingReason in histograms.xml, 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 { 11 struct MainThreadScrollingReason {
16 // Non-transient scrolling reasons. 12 // Non-transient scrolling reasons.
17 enum : uint32_t { kNotScrollingOnMain = 0 }; 13 enum : uint32_t { kNotScrollingOnMain = 0 };
18 enum : uint32_t { kHasBackgroundAttachmentFixedObjects = 1 << 0 }; 14 enum : uint32_t { kHasBackgroundAttachmentFixedObjects = 1 << 0 };
19 enum : uint32_t { kHasNonLayerViewportConstrainedObjects = 1 << 1 }; 15 enum : uint32_t { kHasNonLayerViewportConstrainedObjects = 1 << 1 };
20 enum : uint32_t { kThreadedScrollingDisabled = 1 << 2 }; 16 enum : uint32_t { kThreadedScrollingDisabled = 1 << 2 };
21 enum : uint32_t { kScrollbarScrolling = 1 << 3 }; 17 enum : uint32_t { kScrollbarScrolling = 1 << 3 };
22 enum : uint32_t { kPageOverlay = 1 << 4 }; 18 enum : uint32_t { kPageOverlay = 1 << 4 };
23 enum : uint32_t { kMaxNonTransientScrollingReason = kPageOverlay }; 19 enum : uint32_t { kMaxNonTransientScrollingReason = kPageOverlay };
24 20
25 // Transient scrolling reasons. 21 // Transient scrolling reasons. These are computed for each scroll begin.
26 enum : uint32_t { kNonFastScrollableRegion = 1 << 5 }; 22 enum : uint32_t { kNonFastScrollableRegion = 1 << 5 };
27 enum : uint32_t { kEventHandlers = 1 << 6 }; 23 enum : uint32_t { kEventHandlers = 1 << 6 };
28 enum : uint32_t { kFailedHitTest = 1 << 7 }; 24 enum : uint32_t { kFailedHitTest = 1 << 7 };
29 enum : uint32_t { kNoScrollingLayer = 1 << 8 }; 25 enum : uint32_t { kNoScrollingLayer = 1 << 8 };
30 enum : uint32_t { kNotScrollable = 1 << 9 }; 26 enum : uint32_t { kNotScrollable = 1 << 9 };
31 enum : uint32_t { kContinuingMainThreadScroll = 1 << 10 }; 27 enum : uint32_t { kContinuingMainThreadScroll = 1 << 10 };
32 enum : uint32_t { kNonInvertibleTransform = 1 << 11 }; 28 enum : uint32_t { kNonInvertibleTransform = 1 << 11 };
33 enum : uint32_t { kPageBasedScrolling = 1 << 12 }; 29 enum : uint32_t { kPageBasedScrolling = 1 << 12 };
34 30
35 // The number of flags in this struct (excluding itself). 31 // The number of flags in this struct (excluding itself).
36 enum : uint32_t { kMainThreadScrollingReasonCount = 14 }; 32 enum : uint32_t { kMainThreadScrollingReasonCount = 14 };
37 }; 33 };
38 34
39 } // namespace cc 35 } // namespace cc
40 36
41 #endif // CC_INPUT_MAIN_THREAD_SCROLLING_REASON_H_ 37 #endif // CC_INPUT_MAIN_THREAD_SCROLLING_REASON_H_
OLDNEW
« no previous file with comments | « cc/blink/web_layer_impl.cc ('k') | third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698