Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(57)

Unified Diff: sky/sdk/lib/widgets/navigator.dart

Issue 1226113007: Add @override annotation to known overriden methods (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sky/sdk/lib/widgets/modal_overlay.dart ('k') | sky/sdk/lib/widgets/popup_menu.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/sdk/lib/widgets/navigator.dart
diff --git a/sky/sdk/lib/widgets/navigator.dart b/sky/sdk/lib/widgets/navigator.dart
index dbb150660ae3d19d90a4a21a361d3ec5fb8fba76..37dc9b53a98ab86848eed7245b538831def3e5be 100644
--- a/sky/sdk/lib/widgets/navigator.dart
+++ b/sky/sdk/lib/widgets/navigator.dart
@@ -16,6 +16,8 @@ abstract class RouteBase {
class Route extends RouteBase {
Route({ String name, this.builder }) : super(name: name);
final Builder builder;
+
+ @override
Widget build(Navigator navigator, RouteBase route) => builder(navigator, route);
}
@@ -26,8 +28,10 @@ class RouteState extends RouteBase {
RouteBase route;
Function callback;
+ @override
Widget build(Navigator navigator, _) => route.build(navigator, this);
+ @override
void popState() {
if (callback != null)
callback(this);
@@ -80,6 +84,7 @@ class Navigator extends StatefulComponent {
NavigationState state;
+ @override
void syncFields(Navigator source) {
state = source.state;
}
@@ -113,6 +118,7 @@ class Navigator extends StatefulComponent {
});
}
+ @override
Widget build() {
return state.currentRoute.build(this, state.currentRoute);
}
« no previous file with comments | « sky/sdk/lib/widgets/modal_overlay.dart ('k') | sky/sdk/lib/widgets/popup_menu.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698