mirror of
https://github.com/encounter/engine.git
synced 2026-03-30 11:09:55 -07:00
Add elevation and thickness to SemanticsNode (#7282)
This commit is contained in:
committed by
GitHub
parent
25c1c0ce43
commit
6c29fb4d5e
@@ -607,6 +607,14 @@ class SemanticsUpdateBuilder extends NativeFieldWrapperClass2 {
|
||||
///
|
||||
/// The `transform` is a matrix that maps this node's coordinate system into
|
||||
/// its parent's coordinate system.
|
||||
///
|
||||
/// The `elevation` describes the distance in z-direction between this node
|
||||
/// and the `elevation` of the parent.
|
||||
///
|
||||
/// The `thickness` describes how much space this node occupies in the
|
||||
/// z-direction starting at `elevation`. Basically, in the z-direction the
|
||||
/// node starts at `elevation` above the parent and ends at `elevation` +
|
||||
/// `thickness` above the parent.
|
||||
void updateNode({
|
||||
int id,
|
||||
int flags,
|
||||
@@ -618,6 +626,8 @@ class SemanticsUpdateBuilder extends NativeFieldWrapperClass2 {
|
||||
double scrollPosition,
|
||||
double scrollExtentMax,
|
||||
double scrollExtentMin,
|
||||
double elevation,
|
||||
double thickness,
|
||||
Rect rect,
|
||||
String label,
|
||||
String hint,
|
||||
@@ -647,6 +657,8 @@ class SemanticsUpdateBuilder extends NativeFieldWrapperClass2 {
|
||||
rect.top,
|
||||
rect.right,
|
||||
rect.bottom,
|
||||
elevation,
|
||||
thickness,
|
||||
label,
|
||||
hint,
|
||||
value,
|
||||
@@ -674,6 +686,8 @@ class SemanticsUpdateBuilder extends NativeFieldWrapperClass2 {
|
||||
double top,
|
||||
double right,
|
||||
double bottom,
|
||||
double elevation,
|
||||
double thickness,
|
||||
String label,
|
||||
String hint,
|
||||
String value,
|
||||
|
||||
@@ -87,6 +87,8 @@ struct SemanticsNode {
|
||||
double scrollPosition = std::nan("");
|
||||
double scrollExtentMax = std::nan("");
|
||||
double scrollExtentMin = std::nan("");
|
||||
double elevation = 0.0;
|
||||
double thickness = 0.0;
|
||||
std::string label;
|
||||
std::string hint;
|
||||
std::string value;
|
||||
|
||||
@@ -50,6 +50,8 @@ void SemanticsUpdateBuilder::updateNode(
|
||||
double top,
|
||||
double right,
|
||||
double bottom,
|
||||
double elevation,
|
||||
double thickness,
|
||||
std::string label,
|
||||
std::string hint,
|
||||
std::string value,
|
||||
@@ -72,6 +74,8 @@ void SemanticsUpdateBuilder::updateNode(
|
||||
node.scrollExtentMax = scrollExtentMax;
|
||||
node.scrollExtentMin = scrollExtentMin;
|
||||
node.rect = SkRect::MakeLTRB(left, top, right, bottom);
|
||||
node.elevation = elevation;
|
||||
node.thickness = thickness;
|
||||
node.label = label;
|
||||
node.hint = hint;
|
||||
node.value = value;
|
||||
|
||||
@@ -38,6 +38,8 @@ class SemanticsUpdateBuilder
|
||||
double top,
|
||||
double right,
|
||||
double bottom,
|
||||
double elevation,
|
||||
double thickness,
|
||||
std::string label,
|
||||
std::string hint,
|
||||
std::string value,
|
||||
|
||||
Reference in New Issue
Block a user