#ifndef CC_TREES_SCROLL_NODE_H_
#define CC_TREES_SCROLL_NODE_H_
#include "cc/base/region.h"
#include "cc/cc_export.h"
#include "cc/input/overscroll_behavior.h"
#include "cc/input/scroll_snap_data.h"
#include "cc/paint/element_id.h"
#include "cc/paint/filter_operations.h"
#include "third_party/abseil-cpp/absl/types/optional.h"
#include "ui/gfx/geometry/size.h"
namespace base {
namespace trace_event {
class TracedValue;
}
}
namespace cc {
struct CC_EXPORT ScrollNode {
ScrollNode();
ScrollNode(const ScrollNode& other);
~ScrollNode();
int id;
int parent_id;
uint32_t main_thread_scrolling_reasons;
gfx::Size container_bounds;
gfx::Size bounds;
bool scrollable : 1;
bool max_scroll_offset_affected_by_page_scale : 1;
bool scrolls_inner_viewport : 1;
bool scrolls_outer_viewport : 1;
bool prevent_viewport_scrolling_from_inner : 1;
bool should_flatten : 1;
bool user_scrollable_horizontal : 1;
bool user_scrollable_vertical : 1;
gfx::Vector2dF offset_to_transform_parent;
ElementId element_id;
int transform_id;
OverscrollBehavior overscroll_behavior;
absl::optional<SnapContainerData> snap_container_data;
bool is_composited : 1;
#if DCHECK_IS_ON()
bool operator==(const ScrollNode& other) const;
#endif
void AsValueInto(base::trace_event::TracedValue* value) const;
};
}
#endif