Skip to content

Commit dd11761

Browse files
committed
release 0.0.3
1 parent 4dc905c commit dd11761

File tree

4 files changed

+12
-15
lines changed

4 files changed

+12
-15
lines changed

Diff for: CHANGELOG.md

+4
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
## [0.0.3] - 2020/09/24.
2+
3+
* Fix bugs in nested page view.
4+
15
## [0.0.2] - 2020/09/23.
26

37
* Support nested page view.

Diff for: README.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@ class _MyPageViewState extends State<MyPageView> {
171171
title: Text('MyPageView'),
172172
),
173173
// Wrap PageView
174-
body: PageViewLifecycleWrapper(
174+
body: ParentPageLifecycleWrapper(
175175
controller: _pageController,
176176
onLifecycleEvent: (event) { // optional.
177177
print('MyPageView#${event.toString()}');
@@ -180,15 +180,15 @@ class _MyPageViewState extends State<MyPageView> {
180180
controller: _pageController,
181181
children: [
182182
// Wrap child of PageView
183-
PageLifecycleWrapper(
183+
ChildPageLifecycleWrapper(
184184
index: 0,
185185
wantKeepAlive: true,
186186
onLifecycleEvent: (event) {
187187
print('Page@0#${event.toString()}');
188188
},
189189
child: Container(),
190190
),
191-
PageLifecycleWrapper(
191+
ChildPageLifecycleWrapper(
192192
index: 1,
193193
wantKeepAlive: true,
194194
onLifecycleEvent: (event) {

Diff for: example/lib/nested_pageview.dart

+4-11
Original file line numberDiff line numberDiff line change
@@ -50,17 +50,10 @@ class _NestedPageViewState extends State<NestedPageView> with SingleTickerProvid
5050
child: TabBarView(
5151
controller: _tabController,
5252
children: <Widget>[
53-
ChildPageLifecycleWrapper(
54-
index: 0,
55-
wantKeepAlive: true,
56-
onLifecycleEvent: (event) {
57-
log.add('OuterPage@0#${event.toString()}');
58-
},
59-
child: Center(
60-
child: Text(
61-
'This is the first tab',
62-
style: const TextStyle(fontSize: 20),
63-
),
53+
Center(
54+
child: Text(
55+
'This is the first tab',
56+
style: const TextStyle(fontSize: 20),
6457
),
6558
),
6659
ChildPageLifecycleWrapper(

Diff for: pubspec.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: lifecycle
22
description: Lifecycle support for Flutter widgets.
3-
version: 0.0.2
3+
version: 0.0.3
44
homepage: https://github.com/chenenyu/lifecycle
55
publish_to: https://pub.dev
66

0 commit comments

Comments
 (0)