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
97eaf58b
Unverified
Commit
97eaf58b
authored
Nov 02, 2020
by
Anas35
Committed by
GitHub
Nov 02, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
AnimatedPositioned (#69513)
parent
2f18e0b2
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
38 additions
and
0 deletions
+38
-0
implicit_animations.dart
packages/flutter/lib/src/widgets/implicit_animations.dart
+38
-0
No files found.
packages/flutter/lib/src/widgets/implicit_animations.dart
View file @
97eaf58b
...
...
@@ -1058,6 +1058,44 @@ class _AnimatedAlignState extends AnimatedWidgetBaseState<AnimatedAlign> {
/// it also requires more development overhead as you have to manually manage
/// the lifecycle of the underlying [AnimationController].
///
/// {@tool dartpad --template=stateful_widget_scaffold}
///
/// The following example transitions an AnimatedPositioned
/// between two states. It adjusts the `height`, `width`, and
/// [Positioned] properties when tapped.
///
/// ```dart
/// bool selected = false;
///
/// @override
/// Widget build(BuildContext context) {
/// return Stack(
/// children: [
/// AnimatedPositioned(
/// width: selected ? 200.0 : 50.0,
/// height: selected ? 50.0 : 200.0,
/// top: selected ? 50.0 : 150.0,
/// right: 150.0,
/// duration: Duration(seconds: 2),
/// curve: Curves.fastOutSlowIn,
/// child: GestureDetector(
/// onTap: () {
/// setState(() {
/// selected = !selected;
/// });
/// },
/// child: Container(
/// color: Colors.blue,
/// child: Text('Tap me to start the animated transition'),
/// ),
/// ),
/// ),
/// ],
/// );
/// }
///```
/// {@end-tool}
///
/// See also:
///
/// * [AnimatedPositionedDirectional], which adapts to the ambient
...
...
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