mirror of
https://gitlab.com/comunic/comunicmobile
synced 2025-06-19 08:15:16 +00:00
Get the list of members of the call
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
import 'package:comunic/helpers/calls_helper.dart';
|
||||
import 'package:comunic/helpers/conversations_helper.dart';
|
||||
import 'package:comunic/lists/call_members_list.dart';
|
||||
import 'package:comunic/models/call_config.dart';
|
||||
import 'package:comunic/models/conversation.dart';
|
||||
import 'package:comunic/ui/widgets/comunic_back_button_widget.dart';
|
||||
@ -33,6 +34,7 @@ class _CallScreenState extends SafeState<CallScreen> {
|
||||
String _convName;
|
||||
CallConfig _conf;
|
||||
var _error = false;
|
||||
CallMembersList _membersList;
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
@ -63,6 +65,9 @@ class _CallScreenState extends SafeState<CallScreen> {
|
||||
|
||||
// Get call configuration
|
||||
_conf = await CallsHelper.getConfig();
|
||||
|
||||
// Get current members of the call
|
||||
_membersList = await CallsHelper.getMembers(convID);
|
||||
} catch (e, stack) {
|
||||
print("Could not initialize call! $e\n$stack");
|
||||
setState(() => _error = true);
|
||||
@ -92,8 +97,8 @@ class _CallScreenState extends SafeState<CallScreen> {
|
||||
|
||||
/// Build widget body
|
||||
Widget _buildBody() {
|
||||
// Handle errors
|
||||
if (_error)
|
||||
// Handle errors
|
||||
return buildErrorCard(tr("Could not initialize call!"), actions: [
|
||||
MaterialButton(
|
||||
onPressed: () => _initCall(),
|
||||
|
Reference in New Issue
Block a user