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

Unified Diff: sky/sdk/lib/widgets/README.md

Issue 1217093005: Refactor stateful parts of Component into StatefulComponent (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: rebase 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/editing/input.dart ('k') | sky/sdk/lib/widgets/animated_component.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/sdk/lib/widgets/README.md
diff --git a/sky/sdk/lib/widgets/README.md b/sky/sdk/lib/widgets/README.md
index 3ddfb85aadcdb6e5a9d6b069c85a2a80b0d8ac01..e6077549058503d59689efd9f0cdb3ab8b7f3ea7 100644
--- a/sky/sdk/lib/widgets/README.md
+++ b/sky/sdk/lib/widgets/README.md
@@ -254,8 +254,8 @@ class MyCheckbox extends Component {
}
}
-class MyDialog extends Component {
- MyDialog({ this.onDismissed }) : super(stateful: true);
+class MyDialog extends StatefulComponent {
+ MyDialog({ this.onDismissed });
Function onDismissed;
bool _checkboxValue = false;
@@ -298,8 +298,7 @@ component persists for the lifetime of the application.
The `MyDialog` component is more complicated because it is a stateful component.
Let's walk through the differences in `MyDialog` caused by its being stateful:
- * `MyDialog` passes `stateful: true` to the `Component` constructor, marking
- the component stateful.
+ * `MyDialog` extends StatefulComponent instead of Component.
* `MyDialog` has non-`final` member variables. Over the lifetime of the dialog,
we'll need to modify the values of these member variables, which means we
« no previous file with comments | « sky/sdk/lib/editing/input.dart ('k') | sky/sdk/lib/widgets/animated_component.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698