fix: Minor bugs
This commit is contained in:
parent
b3c51b5656
commit
44107f364e
3 changed files with 20 additions and 21 deletions
|
|
@ -259,17 +259,24 @@ class _ChatListState extends State<ChatList> {
|
|||
IconButton(
|
||||
icon: Icon(Icons.search_outlined),
|
||||
tooltip: L10n.of(context).search,
|
||||
onPressed: () async {
|
||||
await _scrollController.animateTo(
|
||||
_scrollController.position.minScrollExtent,
|
||||
duration: Duration(milliseconds: 200),
|
||||
curve: Curves.ease,
|
||||
);
|
||||
WidgetsBinding.instance.addPostFrameCallback(
|
||||
(_) => _searchFieldKey.currentState
|
||||
.requestFocus(),
|
||||
);
|
||||
},
|
||||
onPressed: Matrix.of(context)
|
||||
.client
|
||||
.rooms
|
||||
.isEmpty
|
||||
? null
|
||||
: () async {
|
||||
await _scrollController.animateTo(
|
||||
_scrollController
|
||||
.position.minScrollExtent,
|
||||
duration: Duration(milliseconds: 200),
|
||||
curve: Curves.ease,
|
||||
);
|
||||
WidgetsBinding.instance
|
||||
.addPostFrameCallback(
|
||||
(_) => _searchFieldKey.currentState
|
||||
.requestFocus(),
|
||||
);
|
||||
},
|
||||
),
|
||||
],
|
||||
title: Text(selectMode == SelectMode.share
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue