mirror of
https://github.com/twonlyapp/twonly-app.git
synced 2026-04-22 16:12:52 +00:00
fixes small ui issues
This commit is contained in:
parent
37c5ce933d
commit
6ed3af5a92
6 changed files with 29 additions and 8 deletions
|
|
@ -1,5 +1,10 @@
|
|||
# Changelog
|
||||
|
||||
## 0.1.6
|
||||
|
||||
- Fix: Phantom push notification
|
||||
- Fix: Smaller UI fixes
|
||||
|
||||
## 0.1.5
|
||||
|
||||
- Fix: Reupload of media files was not working properly
|
||||
|
|
|
|||
|
|
@ -1,8 +1,10 @@
|
|||
import 'dart:async';
|
||||
import 'dart:io';
|
||||
|
||||
import 'package:camera/camera.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter_secure_storage/flutter_secure_storage.dart';
|
||||
import 'package:path_provider/path_provider.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:sentry_flutter/sentry_flutter.dart';
|
||||
|
|
@ -33,9 +35,20 @@ void main() async {
|
|||
globalApplicationSupportDirectory =
|
||||
(await getApplicationSupportDirectory()).path;
|
||||
|
||||
initLogger();
|
||||
await initFCMService();
|
||||
|
||||
final user = await getUser();
|
||||
var user = await getUser();
|
||||
|
||||
if (Platform.isIOS && user != null) {
|
||||
final db = File('$globalApplicationSupportDirectory/twonly.sqlite');
|
||||
if (!db.existsSync()) {
|
||||
Log.error('[twonly] IOS: App was removed and then reinstalled again...');
|
||||
await const FlutterSecureStorage().deleteAll();
|
||||
user = await getUser();
|
||||
}
|
||||
}
|
||||
|
||||
if (user != null) {
|
||||
gUser = user;
|
||||
|
||||
|
|
@ -57,8 +70,6 @@ void main() async {
|
|||
await deleteLocalUserData();
|
||||
}
|
||||
|
||||
initLogger();
|
||||
|
||||
final settingsController = SettingsChangeProvider();
|
||||
|
||||
await settingsController.loadSettings();
|
||||
|
|
|
|||
|
|
@ -77,7 +77,8 @@ class MessagesDao extends DatabaseAccessor<TwonlyDB> with _$MessagesDaoMixin {
|
|||
t.groupId.equals(groupId) &
|
||||
// messages in groups will only be removed in case all members have received it...
|
||||
// so ensuring that this message is not shown in the messages anymore
|
||||
t.openedAt.isBiggerThanValue(deletionTime),
|
||||
(t.openedAt.isBiggerThanValue(deletionTime) |
|
||||
t.openedAt.isNull()),
|
||||
)
|
||||
..orderBy([(t) => OrderingTerm.desc(t.createdAt)])
|
||||
..limit(1))
|
||||
|
|
@ -96,7 +97,8 @@ class MessagesDao extends DatabaseAccessor<TwonlyDB> with _$MessagesDaoMixin {
|
|||
t.groupId.equals(groupId) &
|
||||
// messages in groups will only be removed in case all members have received it...
|
||||
// so ensuring that this message is not shown in the messages anymore
|
||||
t.openedAt.isBiggerThanValue(deletionTime) &
|
||||
(t.openedAt.isBiggerThanValue(deletionTime) |
|
||||
t.openedAt.isNull()) &
|
||||
(t.isDeletedFromSender.equals(true) |
|
||||
(t.type.equals(MessageType.text.name).not() |
|
||||
t.type.equals(MessageType.media.name).not()) |
|
||||
|
|
|
|||
|
|
@ -70,11 +70,11 @@ class PurchasesProvider with ChangeNotifier, DiagnosticableTreeMixin {
|
|||
};
|
||||
final response = await iapConnection.queryProductDetails(ids);
|
||||
if (response.notFoundIDs.isNotEmpty) {
|
||||
Log.error(response.notFoundIDs);
|
||||
Log.warn(response.notFoundIDs);
|
||||
}
|
||||
products = response.productDetails.map(PurchasableProduct.new).toList();
|
||||
if (products.isEmpty) {
|
||||
Log.error('Could not load any products from the store!');
|
||||
Log.warn('Could not load any products from the store!');
|
||||
}
|
||||
storeState = StoreState.available;
|
||||
notifyListeners();
|
||||
|
|
|
|||
|
|
@ -228,6 +228,7 @@ class _UserListItem extends State<GroupListItem> {
|
|||
VerifiedShield(
|
||||
group: widget.group,
|
||||
showOnlyIfVerified: true,
|
||||
clickable: false,
|
||||
size: 12,
|
||||
),
|
||||
],
|
||||
|
|
|
|||
|
|
@ -13,12 +13,14 @@ class VerifiedShield extends StatefulWidget {
|
|||
super.key,
|
||||
this.size = 15,
|
||||
this.showOnlyIfVerified = false,
|
||||
this.clickable = true,
|
||||
});
|
||||
final Group? group;
|
||||
final Contact? contact;
|
||||
final double size;
|
||||
|
||||
final bool showOnlyIfVerified;
|
||||
final bool clickable;
|
||||
|
||||
@override
|
||||
State<VerifiedShield> createState() => _VerifiedShieldState();
|
||||
|
|
@ -61,7 +63,7 @@ class _VerifiedShieldState extends State<VerifiedShield> {
|
|||
Widget build(BuildContext context) {
|
||||
if (!isVerified && widget.showOnlyIfVerified) return Container();
|
||||
return GestureDetector(
|
||||
onTap: (contact == null)
|
||||
onTap: (contact == null || !widget.clickable)
|
||||
? null
|
||||
: () => context.push(Routes.settingsHelpFaqVerifyBadge),
|
||||
child: ColoredBox(
|
||||
|
|
|
|||
Loading…
Reference in a new issue