Commit c724d3a1 by Rizal Hermawan

refactor : clears hint text after click close on appbar

parent 7024a6a9
...@@ -379,12 +379,9 @@ class FloatingSearchAppBarState extends ImplicitlyAnimatedWidgetState< ...@@ -379,12 +379,9 @@ class FloatingSearchAppBarState extends ImplicitlyAnimatedWidgetState<
} }
void clear() { void clear() {
final bool hasQuery = !widget.clearQueryOnClose && query.isNotEmpty;
if (hasQuery == true) {
setState(() { setState(() {
widget.hint = ''; widget.hint = '';
}); });
}
_input.clear(); _input.clear();
} }
......
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