fix: не хочу софтлок на линухе
This commit is contained in:
@@ -108,11 +108,24 @@ class _ChatInfoScreenState extends State<ChatInfoScreen> {
|
|||||||
'Ссылки',
|
'Ссылки',
|
||||||
];
|
];
|
||||||
case 'CHAT':
|
case 'CHAT':
|
||||||
return ['Участники', 'Info', 'Медиа', 'Файлы', 'Голосовые', 'Ссылки'];
|
return [
|
||||||
|
'Участники',
|
||||||
|
if (showInfo) 'Info',
|
||||||
|
'Медиа',
|
||||||
|
'Файлы',
|
||||||
|
'Голосовые',
|
||||||
|
'Ссылки',
|
||||||
|
];
|
||||||
case 'CHANNEL':
|
case 'CHANNEL':
|
||||||
return ['Info', 'Медиа', 'Файлы', 'Голосовые', 'Ссылки'];
|
return [
|
||||||
|
if (showInfo) 'Info',
|
||||||
|
'Медиа',
|
||||||
|
'Файлы',
|
||||||
|
'Голосовые',
|
||||||
|
'Ссылки',
|
||||||
|
];
|
||||||
default:
|
default:
|
||||||
return ['Info'];
|
return [if (showInfo) 'Info'];
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -199,7 +212,7 @@ class _ChatInfoScreenState extends State<ChatInfoScreen> {
|
|||||||
if (mounted) {
|
if (mounted) {
|
||||||
setState(() {
|
setState(() {
|
||||||
_isLoading = false;
|
_isLoading = false;
|
||||||
if (_selectedTab.isEmpty) _selectedTab = _tabs.first;
|
if (_selectedTab.isEmpty && _tabs.isNotEmpty) _selectedTab = _tabs.first;
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,6 +22,7 @@ import '../../core/utils/file_download.dart';
|
|||||||
import '../../core/utils/media_cache.dart';
|
import '../../core/utils/media_cache.dart';
|
||||||
import '../../core/utils/download_progress.dart';
|
import '../../core/utils/download_progress.dart';
|
||||||
import '../../core/utils/link_opener.dart';
|
import '../../core/utils/link_opener.dart';
|
||||||
|
import '../../core/utils/webview_support.dart';
|
||||||
import '../../core/config/app_link_preview.dart';
|
import '../../core/config/app_link_preview.dart';
|
||||||
import 'custom_notification.dart';
|
import 'custom_notification.dart';
|
||||||
import 'link_text.dart';
|
import 'link_text.dart';
|
||||||
@@ -706,6 +707,11 @@ class MessageBubble extends StatelessWidget {
|
|||||||
BuildContext context,
|
BuildContext context,
|
||||||
InlineKeyboardButton button,
|
InlineKeyboardButton button,
|
||||||
) async {
|
) async {
|
||||||
|
if (!webViewSupported) {
|
||||||
|
showCustomNotification(context, 'На вашей платформе это недоступно');
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
final deeplink = button.webApp != null
|
final deeplink = button.webApp != null
|
||||||
? Uri.tryParse(button.webApp!)
|
? Uri.tryParse(button.webApp!)
|
||||||
: null;
|
: null;
|
||||||
|
|||||||
Reference in New Issue
Block a user