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
434a36be
Commit
434a36be
authored
Oct 01, 2015
by
Ian Hickson
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1438 from Hixie/state_route
Rename RouteState to StateRoute
parents
eda87925
927edaac
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
7 additions
and
7 deletions
+7
-7
drawer.dart
packages/flutter/lib/src/widgets/drawer.dart
+2
-2
navigator.dart
packages/flutter/lib/src/widgets/navigator.dart
+5
-5
No files found.
packages/flutter/lib/src/widgets/drawer.dart
View file @
434a36be
...
...
@@ -123,8 +123,8 @@ class DrawerState extends State<Drawer> {
void
_handleDismissed
()
{
if
(
config
.
navigator
!=
null
&&
config
.
navigator
.
currentRoute
is
RouteSta
te
&&
(
config
.
navigator
.
currentRoute
as
RouteSta
te
).
owner
==
this
)
// TODO(ianh): remove cast once analyzer is cleverer
config
.
navigator
.
currentRoute
is
StateRou
te
&&
(
config
.
navigator
.
currentRoute
as
StateRou
te
).
owner
==
this
)
// TODO(ianh): remove cast once analyzer is cleverer
config
.
navigator
.
pop
();
if
(
config
.
onDismissed
!=
null
)
config
.
onDismissed
();
...
...
packages/flutter/lib/src/widgets/navigator.dart
View file @
434a36be
...
...
@@ -10,7 +10,7 @@ import 'package:sky/src/widgets/transitions.dart';
typedef
Widget
RouteBuilder
(
NavigatorState
navigator
,
Route
route
);
typedef
RouteBuilder
RouteGenerator
(
String
name
);
typedef
void
RouteStateCallback
(
RouteSta
te
route
);
typedef
void
StateRouteCallback
(
StateRou
te
route
);
typedef
void
NotificationCallback
(
);
class
Navigator
extends
StatefulComponent
{
...
...
@@ -48,7 +48,7 @@ class NavigatorState extends State<Navigator> {
}
void
pushState
(
State
owner
,
Function
callback
)
{
push
(
new
RouteSta
te
(
push
(
new
StateRou
te
(
route:
currentRoute
,
owner:
owner
,
callback:
callback
...
...
@@ -275,12 +275,12 @@ class PageRoute extends Route {
}
}
class
RouteSta
te
extends
Route
{
RouteSta
te
({
this
.
route
,
this
.
owner
,
this
.
callback
});
class
StateRou
te
extends
Route
{
StateRou
te
({
this
.
route
,
this
.
owner
,
this
.
callback
});
Route
route
;
State
owner
;
RouteSta
teCallback
callback
;
StateRou
teCallback
callback
;
bool
get
hasContent
=>
false
;
bool
get
modal
=>
false
;
...
...
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