Created
January 9, 2019 01:55
-
-
Save lawreyios/0b7fa61570d3c266bb2f7cedfb28cc97 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_HomePageState() { | |
_filter.addListener(() { | |
if (_filter.text.isEmpty) { | |
setState(() { | |
_searchText = ""; | |
_resetRecords(); | |
}); | |
} else { | |
setState(() { | |
_searchText = _filter.text; | |
}); | |
} | |
}); | |
} | |
void _resetRecords() { | |
this._filteredRecords.records = new List(); | |
for (Record record in _records.records) { | |
this._filteredRecords.records.add(record); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment