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
411db2d5
Commit
411db2d5
authored
Sep 09, 2016
by
Ian Hickson
Committed by
GitHub
Sep 09, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Tabs occasionally tried to setState after dispose (#5784)
Fixes
https://github.com/flutter/flutter/issues/5776
parent
e7601e3f
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
9 deletions
+10
-9
README.md
dev/benchmarks/microbenchmarks/README.md
+4
-4
layout_bench.dart
dev/benchmarks/microbenchmarks/lib/stocks/layout_bench.dart
+0
-1
tabs.dart
packages/flutter/lib/src/material/tabs.dart
+6
-4
No files found.
dev/benchmarks/microbenchmarks/README.md
View file @
411db2d5
...
...
@@ -3,10 +3,10 @@
To run these benchmarks on a device:
```
flutter run --release
-t
lib/gestures/velocity_tracker_data.dart
flutter run --release
-t
lib/stocks/animation_bench.dart
flutter run --release
-t
lib/stocks/build_bench.dart
flutter run --release
-t
lib/stocks/layout_bench.dart
flutter run --release lib/gestures/velocity_tracker_data.dart
flutter run --release lib/stocks/animation_bench.dart
flutter run --release lib/stocks/build_bench.dart
flutter run --release lib/stocks/layout_bench.dart
```
The results should be in the device logs.
dev/benchmarks/microbenchmarks/lib/stocks/layout_bench.dart
View file @
411db2d5
...
...
@@ -11,7 +11,6 @@ const Duration kBenchmarkTime = const Duration(seconds: 15);
Future
<
Null
>
main
()
async
{
assert
(
false
);
// don't run this in checked mode! Use --release.
stock_data
.
StockDataFetcher
.
actuallyFetchData
=
false
;
final
Stopwatch
watch
=
new
Stopwatch
();
...
...
packages/flutter/lib/src/material/tabs.dart
View file @
411db2d5
...
...
@@ -977,10 +977,12 @@ class _TabBarState<T> extends ScrollableState<TabBar<T>> implements TabBarSelect
_indicatorRect
=
_selection
!=
null
?
_tabIndicatorRect
(
_selection
.
index
)
:
Rect
.
zero
;
_updateScrollBehavior
();
SchedulerBinding
.
instance
.
addPostFrameCallback
((
Duration
timeStamp
)
{
setState
(()
{
// the changes were made at layout time
// TODO(ianh): remove this setState: https://github.com/flutter/flutter/issues/5749
});
if
(
mounted
)
{
setState
(()
{
// the changes were made at layout time
// TODO(ianh): remove this setState: https://github.com/flutter/flutter/issues/5749
});
}
});
}
...
...
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