|
|
@ -60,7 +60,8 @@ class ChatEncryptionSettingsView extends StatelessWidget {
|
|
|
|
if (room.isDirectChat)
|
|
|
|
if (room.isDirectChat)
|
|
|
|
Padding(
|
|
|
|
Padding(
|
|
|
|
padding: const EdgeInsets.all(16.0),
|
|
|
|
padding: const EdgeInsets.all(16.0),
|
|
|
|
child: Center(
|
|
|
|
child: SizedBox(
|
|
|
|
|
|
|
|
width: double.infinity,
|
|
|
|
child: ElevatedButton.icon(
|
|
|
|
child: ElevatedButton.icon(
|
|
|
|
onPressed: controller.startVerification,
|
|
|
|
onPressed: controller.startVerification,
|
|
|
|
icon: const Icon(Icons.verified_outlined),
|
|
|
|
icon: const Icon(Icons.verified_outlined),
|
|
|
@ -69,15 +70,7 @@ class ChatEncryptionSettingsView extends StatelessWidget {
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
if (room.encrypted) ...[
|
|
|
|
if (room.encrypted) ...[
|
|
|
|
const Divider(height: 1),
|
|
|
|
const SizedBox(height: 16),
|
|
|
|
ListTile(
|
|
|
|
|
|
|
|
title: Text(
|
|
|
|
|
|
|
|
L10n.of(context)!.deviceKeys,
|
|
|
|
|
|
|
|
style: const TextStyle(
|
|
|
|
|
|
|
|
fontWeight: FontWeight.bold,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
StreamBuilder(
|
|
|
|
StreamBuilder(
|
|
|
|
stream: room.onUpdate.stream,
|
|
|
|
stream: room.onUpdate.stream,
|
|
|
|
builder: (context, snapshot) => FutureBuilder<
|
|
|
|
builder: (context, snapshot) => FutureBuilder<
|
|
|
@ -123,40 +116,39 @@ class ChatEncryptionSettingsView extends StatelessWidget {
|
|
|
|
: Colors.orange,
|
|
|
|
: Colors.orange,
|
|
|
|
size: 20,
|
|
|
|
size: 20,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
|
|
|
|
const SizedBox(width: 4),
|
|
|
|
Text(
|
|
|
|
Text(
|
|
|
|
deviceKeys[i].deviceId ??
|
|
|
|
deviceKeys[i].deviceId ??
|
|
|
|
L10n.of(context)!.unknownDevice,
|
|
|
|
L10n.of(context)!.unknownDevice,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
const SizedBox(width: 4),
|
|
|
|
const SizedBox(width: 4),
|
|
|
|
Expanded(
|
|
|
|
Flexible(
|
|
|
|
child: Align(
|
|
|
|
fit: FlexFit.loose,
|
|
|
|
alignment: Alignment.centerRight,
|
|
|
|
child: Material(
|
|
|
|
child: Material(
|
|
|
|
shape: RoundedRectangleBorder(
|
|
|
|
shape: RoundedRectangleBorder(
|
|
|
|
borderRadius: BorderRadius.circular(
|
|
|
|
borderRadius: BorderRadius.circular(
|
|
|
|
AppConfig.borderRadius),
|
|
|
|
AppConfig.borderRadius),
|
|
|
|
side: BorderSide(
|
|
|
|
side: BorderSide(
|
|
|
|
color: Theme.of(context)
|
|
|
|
|
|
|
|
.colorScheme
|
|
|
|
|
|
|
|
.primary,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
color: Theme.of(context)
|
|
|
|
|
|
|
|
.colorScheme
|
|
|
|
|
|
|
|
.primaryContainer,
|
|
|
|
|
|
|
|
child: Padding(
|
|
|
|
|
|
|
|
padding: const EdgeInsets.all(4.0),
|
|
|
|
|
|
|
|
child: Text(
|
|
|
|
|
|
|
|
deviceKeys[i].userId,
|
|
|
|
|
|
|
|
maxLines: 1,
|
|
|
|
|
|
|
|
overflow: TextOverflow.ellipsis,
|
|
|
|
|
|
|
|
style: TextStyle(
|
|
|
|
color: Theme.of(context)
|
|
|
|
color: Theme.of(context)
|
|
|
|
.colorScheme
|
|
|
|
.colorScheme
|
|
|
|
.primary,
|
|
|
|
.primary,
|
|
|
|
),
|
|
|
|
fontSize: 12,
|
|
|
|
),
|
|
|
|
fontStyle: FontStyle.italic,
|
|
|
|
color: Theme.of(context)
|
|
|
|
|
|
|
|
.colorScheme
|
|
|
|
|
|
|
|
.primaryContainer,
|
|
|
|
|
|
|
|
child: Padding(
|
|
|
|
|
|
|
|
padding: const EdgeInsets.all(4.0),
|
|
|
|
|
|
|
|
child: Text(
|
|
|
|
|
|
|
|
deviceKeys[i].userId,
|
|
|
|
|
|
|
|
maxLines: 1,
|
|
|
|
|
|
|
|
overflow: TextOverflow.ellipsis,
|
|
|
|
|
|
|
|
style: TextStyle(
|
|
|
|
|
|
|
|
color: Theme.of(context)
|
|
|
|
|
|
|
|
.colorScheme
|
|
|
|
|
|
|
|
.primary,
|
|
|
|
|
|
|
|
fontSize: 12,
|
|
|
|
|
|
|
|
fontStyle: FontStyle.italic,
|
|
|
|
|
|
|
|
),
|
|
|
|
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|