remove image and video buttons, file for them all

This commit is contained in:
OfficialDakari 2025-06-09 15:49:00 +05:00
parent d3d75252ee
commit 0c7e9a132e
3 changed files with 26 additions and 32 deletions

View File

@ -1212,12 +1212,6 @@ class ChatController extends State<ChatPageWithRoom>
if (choice == 'file') { if (choice == 'file') {
sendFileAction(); sendFileAction();
} }
if (choice == 'image') {
sendFileAction(type: FileSelectorType.images);
}
if (choice == 'video') {
sendFileAction(type: FileSelectorType.videos);
}
if (choice == 'camera') { if (choice == 'camera') {
openCameraAction(); openCameraAction();
} }

View File

@ -152,30 +152,30 @@ class ChatInputRow extends StatelessWidget {
contentPadding: const EdgeInsets.all(0), contentPadding: const EdgeInsets.all(0),
), ),
), ),
PopupMenuItem<String>( // PopupMenuItem<String>(
value: 'image', // value: 'image',
child: ListTile( // child: ListTile(
leading: CircleAvatar( // leading: CircleAvatar(
backgroundColor: theme.colorScheme.onPrimaryContainer, // backgroundColor: theme.colorScheme.onPrimaryContainer,
foregroundColor: theme.colorScheme.primaryContainer, // foregroundColor: theme.colorScheme.primaryContainer,
child: const Icon(Icons.photo_outlined), // child: const Icon(Icons.photo_outlined),
), // ),
title: Text(L10n.of(context).sendImage), // title: Text(L10n.of(context).sendImage),
contentPadding: const EdgeInsets.all(0), // contentPadding: const EdgeInsets.all(0),
), // ),
), // ),
PopupMenuItem<String>( // PopupMenuItem<String>(
value: 'video', // value: 'video',
child: ListTile( // child: ListTile(
leading: CircleAvatar( // leading: CircleAvatar(
backgroundColor: theme.colorScheme.onPrimaryContainer, // backgroundColor: theme.colorScheme.onPrimaryContainer,
foregroundColor: theme.colorScheme.primaryContainer, // foregroundColor: theme.colorScheme.primaryContainer,
child: const Icon(Icons.video_camera_back_outlined), // child: const Icon(Icons.video_camera_back_outlined),
), // ),
title: Text(L10n.of(context).sendVideo), // title: Text(L10n.of(context).sendVideo),
contentPadding: const EdgeInsets.all(0), // contentPadding: const EdgeInsets.all(0),
), // ),
), // ),
PopupMenuItem<String>( PopupMenuItem<String>(
value: 'file', value: 'file',
child: ListTile( child: ListTile(

View File

@ -1153,8 +1153,8 @@ packages:
matrix: matrix:
dependency: "direct main" dependency: "direct main"
description: description:
path: "/home/officialdakari/repos/matrix-dart-sdk" path: "../matrix-dart-sdk"
relative: false relative: true
source: path source: path
version: "0.40.0" version: "0.40.0"
meta: meta: