Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
80fffe5a
Unverified
Commit
80fffe5a
authored
Oct 25, 2018
by
Jonah Williams
Committed by
GitHub
Oct 25, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Follow up scroll semantics update with documentation fixes (#23444)
parent
883e2dc2
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
34 additions
and
16 deletions
+34
-16
scroll_view.dart
packages/flutter/lib/src/widgets/scroll_view.dart
+12
-6
sliver.dart
packages/flutter/lib/src/widgets/sliver.dart
+22
-10
No files found.
packages/flutter/lib/src/widgets/scroll_view.dart
View file @
80fffe5a
...
...
@@ -715,8 +715,10 @@ class ListView extends BoxScrollView {
/// The `addAutomaticKeepAlives` argument corresponds to the
/// [SliverChildListDelegate.addAutomaticKeepAlives] property. The
/// `addRepaintBoundaries` argument corresponds to the
/// [SliverChildListDelegate.addRepaintBoundaries] property. Both must not be
/// null.
/// [SliverChildListDelegate.addRepaintBoundaries] property. The
/// `addSemanticIndexes` argument corresponds to the
/// [SliverChildListDelegate.addSemanticIndexes] property. None
/// may be null.
ListView
({
Key
key
,
Axis
scrollDirection
=
Axis
.
vertical
,
...
...
@@ -773,8 +775,10 @@ class ListView extends BoxScrollView {
/// The `addAutomaticKeepAlives` argument corresponds to the
/// [SliverChildBuilderDelegate.addAutomaticKeepAlives] property. The
/// `addRepaintBoundaries` argument corresponds to the
/// [SliverChildBuilderDelegate.addRepaintBoundaries] property. Both must not
/// be null.
/// [SliverChildBuilderDelegate.addRepaintBoundaries] property. The
/// `addSemanticIndexes` argument corresponds to the
/// [SliverChildBuilderDelegate.addSemanticIndexes] property. None may be
/// null.
ListView
.
builder
({
Key
key
,
Axis
scrollDirection
=
Axis
.
vertical
,
...
...
@@ -853,8 +857,10 @@ class ListView extends BoxScrollView {
/// The `addAutomaticKeepAlives` argument corresponds to the
/// [SliverChildBuilderDelegate.addAutomaticKeepAlives] property. The
/// `addRepaintBoundaries` argument corresponds to the
/// [SliverChildBuilderDelegate.addRepaintBoundaries] property. Both must not
/// be null.
/// [SliverChildBuilderDelegate.addRepaintBoundaries] property. The
/// `addSemanticIndexes` argument corresponds to the
/// [SliverChildBuilderDelegate.addSemanticIndexes] property. None may be
/// null.
ListView
.
separated
({
Key
key
,
Axis
scrollDirection
=
Axis
.
vertical
,
...
...
packages/flutter/lib/src/widgets/sliver.dart
View file @
80fffe5a
...
...
@@ -301,8 +301,9 @@ class SliverChildBuilderDelegate extends SliverChildDelegate {
/// Creates a delegate that supplies children for slivers using the given
/// builder callback.
///
/// The [builder], [addAutomaticKeepAlives], and [addRepaintBoundaries]
/// arguments must not be null.
/// The [builder], [addAutomaticKeepAlives], [addRepaintBoundaries],
/// [addSemanticIndexes], and [semanticIndexCallback] arguments must not be
/// null.
const
SliverChildBuilderDelegate
(
this
.
builder
,
{
this
.
childCount
,
...
...
@@ -313,7 +314,9 @@ class SliverChildBuilderDelegate extends SliverChildDelegate {
this
.
semanticIndexOffset
=
0
,
})
:
assert
(
builder
!=
null
),
assert
(
addAutomaticKeepAlives
!=
null
),
assert
(
addRepaintBoundaries
!=
null
);
assert
(
addRepaintBoundaries
!=
null
),
assert
(
addSemanticIndexes
!=
null
),
assert
(
semanticIndexCallback
!=
null
);
/// Called to build children for the sliver.
///
...
...
@@ -363,10 +366,13 @@ class SliverChildBuilderDelegate extends SliverChildDelegate {
/// Typically, children in a scrolling container must be annotated with a
/// semantic index in order to generate the correct accessibility
/// announcements. This should only be set to false if the indexes have
/// already been provided by wrapping the correct child widgets in an
/// indexed child semantics widget.
/// already been provided by an [IndexedChildSemantics] widget.
///
/// Defaults to true.
///
/// See also:
/// * [IndexedChildSemantics], for an explanation of how to manually
/// provide semantic indexes.
final
bool
addSemanticIndexes
;
/// An initial offset to add to the semantic indexes generated by this widget.
...
...
@@ -461,8 +467,9 @@ class SliverChildListDelegate extends SliverChildDelegate {
/// Creates a delegate that supplies children for slivers using the given
/// list.
///
/// The [children], [addAutomaticKeepAlives], and [addRepaintBoundaries]
/// arguments must not be null.
/// The [children], [addAutomaticKeepAlives], [addRepaintBoundaries],
/// [addSemanticIndexes], and [semanticIndexCallback] arguments must not be
/// null.
const
SliverChildListDelegate
(
this
.
children
,
{
this
.
addAutomaticKeepAlives
=
true
,
...
...
@@ -472,7 +479,9 @@ class SliverChildListDelegate extends SliverChildDelegate {
this
.
semanticIndexOffset
=
0
,
})
:
assert
(
children
!=
null
),
assert
(
addAutomaticKeepAlives
!=
null
),
assert
(
addRepaintBoundaries
!=
null
);
assert
(
addRepaintBoundaries
!=
null
),
assert
(
addSemanticIndexes
!=
null
),
assert
(
semanticIndexCallback
!=
null
);
/// Whether to wrap each child in an [AutomaticKeepAlive].
///
...
...
@@ -504,10 +513,13 @@ class SliverChildListDelegate extends SliverChildDelegate {
/// Typically, children in a scrolling container must be annotated with a
/// semantic index in order to generate the correct accessibility
/// announcements. This should only be set to false if the indexes have
/// already been provided by wrapping the correct child widgets in an
/// indexed child semantics widget.
/// already been provided by an [IndexedChildSemantics] widget.
///
/// Defaults to true.
///
/// See also:
/// * [IndexedChildSemantics], for an explanation of how to manually
/// provide semantic indexes.
final
bool
addSemanticIndexes
;
/// An initial offset to add to the semantic indexes generated by this widget.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment