mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-11-20 11:09:25 +01:00
chore: Follow up fixes
This commit is contained in:
parent
c2d582f1f7
commit
84dedcf9ac
@ -42,6 +42,9 @@ class ChatListViewBody extends StatelessWidget {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
child: StreamBuilder(
|
child: StreamBuilder(
|
||||||
|
key: ValueKey(client.userID.toString() +
|
||||||
|
controller.activeFilter.toString() +
|
||||||
|
controller.activeSpaceId.toString()),
|
||||||
stream: client.onSync.stream
|
stream: client.onSync.stream
|
||||||
.where((s) => s.hasRoomUpdate)
|
.where((s) => s.hasRoomUpdate)
|
||||||
.rateLimit(const Duration(seconds: 1)),
|
.rateLimit(const Duration(seconds: 1)),
|
||||||
@ -55,8 +58,6 @@ class ChatListViewBody extends StatelessWidget {
|
|||||||
ActiveFilter.messages,
|
ActiveFilter.messages,
|
||||||
}.contains(controller.activeFilter);
|
}.contains(controller.activeFilter);
|
||||||
return ListView.builder(
|
return ListView.builder(
|
||||||
key: ValueKey(client.userID.toString() +
|
|
||||||
controller.activeFilter.toString()),
|
|
||||||
controller: controller.scrollController,
|
controller: controller.scrollController,
|
||||||
// add +1 space below in order to properly scroll below the spaces bar
|
// add +1 space below in order to properly scroll below the spaces bar
|
||||||
itemCount: rooms.length + 1,
|
itemCount: rooms.length + 1,
|
||||||
|
@ -17,7 +17,7 @@ class FluffyChatApp extends StatefulWidget {
|
|||||||
final Widget? testWidget;
|
final Widget? testWidget;
|
||||||
final List<Client> clients;
|
final List<Client> clients;
|
||||||
final Map<String, String>? queryParameters;
|
final Map<String, String>? queryParameters;
|
||||||
static final GlobalKey<VRouterState> routerKey = GlobalKey<VRouterState>();
|
static GlobalKey<VRouterState> routerKey = GlobalKey<VRouterState>();
|
||||||
const FluffyChatApp({
|
const FluffyChatApp({
|
||||||
Key? key,
|
Key? key,
|
||||||
this.testWidget,
|
this.testWidget,
|
||||||
@ -68,6 +68,7 @@ class FluffyChatAppState extends State<FluffyChatApp> {
|
|||||||
setState(() {
|
setState(() {
|
||||||
_initialUrl = FluffyChatApp.routerKey.currentState?.url;
|
_initialUrl = FluffyChatApp.routerKey.currentState?.url;
|
||||||
columnMode = isColumnMode;
|
columnMode = isColumnMode;
|
||||||
|
FluffyChatApp.routerKey = GlobalKey<VRouterState>();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user