Compare commits
6 Commits
Author | SHA1 | Date | |
---|---|---|---|
001549b190 | |||
4595865ad3 | |||
|
1834643167 | ||
|
0e816eaa3e | ||
|
7c1f24b824 | ||
|
b7d44d96ba |
@@ -120,13 +120,24 @@ void main() async {
|
||||
windowButtonVisibility: true,
|
||||
);
|
||||
windowManager.waitUntilReadyToShow(windowOptions, () async {
|
||||
final env = Platform.environment;
|
||||
final isWayland = env.containsKey('WAYLAND_DISPLAY');
|
||||
|
||||
if (isWayland) {
|
||||
try {
|
||||
await windowManager.setAsFrameless();
|
||||
} catch (e) {
|
||||
debugPrint('[Wayland] setAsFrameless failed: $e');
|
||||
}
|
||||
}
|
||||
await windowManager.setMinimumSize(defaultSize);
|
||||
await windowManager.show();
|
||||
await windowManager.focus();
|
||||
final opacity = prefs.getDouble(kAppWindowOpacity) ?? 1.0;
|
||||
await windowManager.setOpacity(opacity);
|
||||
talker.info(
|
||||
"[SplashScreen] Desktop window is ready with size: ${initialSize.width}x${initialSize.height}",
|
||||
"[SplashScreen] Desktop window is ready with size: ${initialSize.width}x${initialSize.height}"
|
||||
"${isWayland ? " (Wayland frameless fix applied)" : ""}",
|
||||
);
|
||||
});
|
||||
}
|
||||
|
@@ -25,7 +25,6 @@ import 'package:island/screens/tabs.dart';
|
||||
import 'package:island/screens/explore.dart';
|
||||
import 'package:island/screens/discovery/article_detail.dart';
|
||||
import 'package:island/screens/account.dart';
|
||||
import 'package:island/screens/notification.dart';
|
||||
import 'package:island/screens/wallet.dart';
|
||||
import 'package:island/screens/account/relationship.dart';
|
||||
import 'package:island/screens/account/profile.dart';
|
||||
@@ -392,11 +391,6 @@ final routerProvider = Provider<GoRouter>((ref) {
|
||||
),
|
||||
],
|
||||
),
|
||||
GoRoute(
|
||||
name: 'notifications',
|
||||
path: '/account/notifications',
|
||||
builder: (context, state) => const NotificationScreen(),
|
||||
),
|
||||
GoRoute(
|
||||
name: 'wallet',
|
||||
path: '/account/wallet',
|
||||
|
@@ -285,7 +285,8 @@ class AccountScreen extends HookConsumerWidget {
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
isScrollControlled: true,
|
||||
builder: (context) => const NotificationScreen(),
|
||||
useRootNavigator: true,
|
||||
builder: (context) => const NotificationSheet(),
|
||||
);
|
||||
},
|
||||
),
|
||||
|
@@ -57,7 +57,8 @@ Widget notificationIndicatorWidget(
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
isScrollControlled: true,
|
||||
builder: (context) => const NotificationScreen(),
|
||||
useRootNavigator: true,
|
||||
builder: (context) => const NotificationSheet(),
|
||||
);
|
||||
},
|
||||
),
|
||||
|
@@ -112,8 +112,8 @@ class NotificationListNotifier extends _$NotificationListNotifier
|
||||
}
|
||||
}
|
||||
|
||||
class NotificationScreen extends HookConsumerWidget {
|
||||
const NotificationScreen({super.key});
|
||||
class NotificationSheet extends HookConsumerWidget {
|
||||
const NotificationSheet({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context, WidgetRef ref) {
|
||||
|
@@ -374,10 +374,10 @@ class PageBackButton extends StatelessWidget {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final isDesktop =
|
||||
!kIsWeb && (Platform.isMacOS || Platform.isLinux || Platform.isWindows);
|
||||
final hasPageAction =
|
||||
!kIsWeb && Platform.isMacOS;
|
||||
|
||||
if (isDesktop && isWideScreen(context)) return const SizedBox.shrink();
|
||||
if (hasPageAction && isWideScreen(context)) return const SizedBox.shrink();
|
||||
|
||||
return IconButton(
|
||||
onPressed: () {
|
||||
|
@@ -14,7 +14,6 @@ import 'package:island/pods/chat/messages_notifier.dart';
|
||||
import 'package:island/pods/translate.dart';
|
||||
import 'package:island/pods/config.dart';
|
||||
import 'package:island/widgets/account/account_pfc.dart';
|
||||
import 'package:island/widgets/app_scaffold.dart';
|
||||
import 'package:island/widgets/chat/message_content.dart';
|
||||
import 'package:island/widgets/chat/message_indicators.dart';
|
||||
import 'package:island/widgets/chat/message_sender_info.dart';
|
||||
@@ -666,17 +665,11 @@ class MessageItemDisplayBubble extends HookConsumerWidget {
|
||||
? Theme.of(context).colorScheme.primaryContainer.withOpacity(0.5)
|
||||
: Theme.of(context).colorScheme.surfaceContainer;
|
||||
|
||||
final hasBackground =
|
||||
ref.watch(backgroundImageFileProvider).valueOrNull != null;
|
||||
|
||||
final remoteMessage = message.toRemoteMessage();
|
||||
final sender = remoteMessage.sender;
|
||||
|
||||
return Material(
|
||||
color:
|
||||
hasBackground
|
||||
? Colors.transparent
|
||||
: Theme.of(context).colorScheme.surface,
|
||||
color: Colors.transparent,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 4),
|
||||
child: Column(
|
||||
|
Reference in New Issue
Block a user