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
dfcc0c71
Commit
dfcc0c71
authored
Jan 07, 2016
by
Adam Barth
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1110 from abarth/widgets_back
Move default back behavior to FlutterWidgetBinding
parents
c44f0a57
e3d587ea
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
4 deletions
+5
-4
material_app.dart
packages/flutter/lib/src/material/material_app.dart
+3
-3
binding.dart
packages/flutter/lib/src/widgets/binding.dart
+2
-1
No files found.
packages/flutter/lib/src/material/material_app.dart
View file @
dfcc0c71
...
...
@@ -86,11 +86,11 @@ class _MaterialAppState extends State<MaterialApp> implements BindingObserver {
assert
(
mounted
);
NavigatorState
navigator
=
_navigator
.
currentState
;
assert
(
navigator
!=
null
);
bool
result
=
false
;
navigator
.
openTransaction
((
NavigatorTransaction
transaction
)
{
if
(!
transaction
.
pop
())
activity
.
finishCurrentActivity
();
result
=
transaction
.
pop
();
});
return
true
;
return
result
;
}
void
didChangeSize
(
Size
size
)
=>
setState
(()
{
_size
=
size
;
});
...
...
packages/flutter/lib/src/widgets/binding.dart
View file @
dfcc0c71
...
...
@@ -77,8 +77,9 @@ class WidgetFlutterBinding extends BindingBase with Scheduler, Gesturer, Rendere
void
handlePopRoute
()
{
for
(
BindingObserver
observer
in
_observers
)
{
if
(
observer
.
didPopRoute
())
break
;
return
;
}
activity
.
finishCurrentActivity
();
}
void
handleAppLifecycleStateChanged
(
ui
.
AppLifecycleState
state
)
{
...
...
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