From 3ea02ea98c0a8dce5dd044ffcb836e685bccc40e Mon Sep 17 00:00:00 2001 From: Pierre HUBERT Date: Mon, 26 Apr 2021 09:40:49 +0200 Subject: [PATCH] Can start private conversation from user profile route --- lib/forez/ui/routes/forez_member_profile_route.dart | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/lib/forez/ui/routes/forez_member_profile_route.dart b/lib/forez/ui/routes/forez_member_profile_route.dart index 581ad55..8c0f662 100644 --- a/lib/forez/ui/routes/forez_member_profile_route.dart +++ b/lib/forez/ui/routes/forez_member_profile_route.dart @@ -9,6 +9,8 @@ import 'package:comunic/ui/widgets/async_screen_widget.dart'; import 'package:comunic/ui/widgets/copy_icon.dart'; import 'package:comunic/ui/widgets/forez_presence_calendar_widget.dart'; import 'package:comunic/ui/widgets/text_widget.dart'; +import 'package:comunic/utils/account_utils.dart'; +import 'package:comunic/utils/conversations_utils.dart'; import 'package:comunic/utils/intl_utils.dart'; import 'package:comunic/utils/ui_utils.dart'; import 'package:flutter/material.dart'; @@ -115,6 +117,13 @@ class _ForezMemberProfileRouteState extends State { ], ), ), + actions: _user.id == userID() + ? null + : [ + IconButton( + icon: Icon(Icons.message), + onPressed: () => openPrivateConversation(context, _user.id)) + ], ); Widget _buildList() => SliverList(