mirror of
https://gitlab.com/comunic/comunicmobile
synced 2024-12-27 21:38:51 +00:00
Fix issue
This commit is contained in:
parent
662c4ab3eb
commit
4db2120de9
@ -154,11 +154,11 @@ abstract class MainController extends State<MainRoute> {
|
||||
child: w, hideNavBar: hideNavBar, canShowAsDialog: canShowAsDialog));
|
||||
|
||||
/// Open a conversation in its context (in group page for group conversations)
|
||||
void openConversation(Conversation conv) {
|
||||
void openConversation(Conversation conv, {fullScreen: false}) {
|
||||
if (conv.isGroupConversation)
|
||||
openGroup(conv.groupID, conversationID: conv.id);
|
||||
else
|
||||
openConversationById(conv.id);
|
||||
openConversationById(conv.id, fullScreen: fullScreen);
|
||||
}
|
||||
|
||||
/// Open a conversation
|
||||
|
@ -1,3 +1,4 @@
|
||||
import 'package:comunic/models/conversation.dart';
|
||||
import 'package:comunic/ui/dialogs/screen_dialog.dart';
|
||||
import 'package:comunic/ui/routes/main_route/main_route.dart';
|
||||
import 'package:comunic/ui/routes/main_route/page_info.dart';
|
||||
@ -89,6 +90,14 @@ class _TabletRouteState extends MainController {
|
||||
super.pushPage(page);
|
||||
}
|
||||
|
||||
@override
|
||||
void openConversation(Conversation conv, {fullScreen: false}) {
|
||||
if (fullScreen)
|
||||
super.openConversation(conv, fullScreen: fullScreen);
|
||||
else
|
||||
openConversationById(conv.id, fullScreen: false);
|
||||
}
|
||||
|
||||
@override
|
||||
void openConversationById(int convID, {fullScreen = false}) {
|
||||
if (!fullScreen) {
|
||||
|
@ -238,7 +238,8 @@ class _MembershipsPanelState extends SafeState<MembershipsPanel> {
|
||||
),
|
||||
subtitle: Text(diffTimeFromNowToStr(membership.lastActive) +
|
||||
(conversation.isHavingCall ? "\n" + tr("Ongoing call") : "")),
|
||||
onTap: () => MainController.of(context).openConversation(conversation),
|
||||
onTap: () => MainController.of(context)
|
||||
.openConversation(conversation, fullScreen: true),
|
||||
trailing: conversation.isHavingCall
|
||||
? FloatingActionButton(
|
||||
heroTag: null,
|
||||
|
Loading…
Reference in New Issue
Block a user