Commit 3aa0437f authored by Hixie's avatar Hixie

Rename defaultFocus to initialFocus.

parent 4da27671
......@@ -112,7 +112,7 @@ class AddressBookApp extends App {
child: new TaskDescription(
label: 'Address Book',
child: new Focus(
defaultFocus: nameKey,
initialFocus: nameKey,
child: buildMain()
)
)
......
......@@ -322,7 +322,7 @@ class StockHome extends StatefulComponent {
];
addMenuToOverlays(overlays);
return new Focus(
defaultFocus: searchFieldKey,
initialFocus: searchFieldKey,
child: new Stack(overlays)
);
}
......
......@@ -14,17 +14,17 @@ class Focus extends Inherited {
Focus({
GlobalKey key,
GlobalKey defaultFocus,
GlobalKey initialFocus,
Widget child
}) : super(key: key, child: child);
GlobalKey defaultFocus;
GlobalKey initialFocus;
GlobalKey _currentlyFocusedKey;
GlobalKey get currentlyFocusedKey {
if (_currentlyFocusedKey != null)
return _currentlyFocusedKey;
return defaultFocus;
return initialFocus;
}
void set currentlyFocusedKey(GlobalKey value) {
if (value != _currentlyFocusedKey) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment