diff --git a/.github/workflows/pr.yaml b/.github/workflows/pr.yaml index afb7f14f..693cb878 100644 --- a/.github/workflows/pr.yaml +++ b/.github/workflows/pr.yaml @@ -153,7 +153,7 @@ jobs: run: flutter build windows - name: Compress artifacts - run: tar.exe -a -c -f windows-dev.zip build/windows/Runner/release + run: tar.exe -zcvf windows-dev.zip build\windows\x64\runner\Release - name: Upload Build Zip uses: actions/upload-artifact@v2.3.1 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 7c0a90c8..25f32525 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -331,7 +331,7 @@ jobs: run: flutter pub run msix:publish - name: Compress artifacts - run: tar.exe -a -c -f windows-${{ github.event.release.tag_name }}.zip build/windows/Runner/release + run: tar.exe -zcvf windows-${{ github.event.release.tag_name }}.zip build/windows/Runner/release - name: Upload artifacts to release uses: svenstaro/upload-release-action@2.2.1 diff --git a/lib/main.dart b/lib/main.dart index ca2a40fd..c1d9bde1 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -71,8 +71,8 @@ void main() async { /// Fvm App class FvmApp extends StatelessWidget { const FvmApp({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/lib/src/components/atoms/blur_background.dart b/lib/src/components/atoms/blur_background.dart index 4c6795a0..832c45dd 100644 --- a/lib/src/components/atoms/blur_background.dart +++ b/lib/src/components/atoms/blur_background.dart @@ -6,9 +6,9 @@ import 'package:flutter/material.dart'; class BlurBackground extends StatelessWidget { /// Constructor const BlurBackground({ - Key? key, + super.key, this.strength = 20.0, - }) : super(key: key); + }); /// Strength of the blur final double strength; diff --git a/lib/src/components/atoms/checkbox.dart b/lib/src/components/atoms/checkbox.dart index bfcf7e97..c1a75dac 100644 --- a/lib/src/components/atoms/checkbox.dart +++ b/lib/src/components/atoms/checkbox.dart @@ -9,8 +9,8 @@ class SkCheckBox extends HookWidget { required this.label, required this.value, required this.onChanged, - Key? key, - }) : super(key: key); + super.key, + }); /// Current value of checkbox final bool value; diff --git a/lib/src/components/atoms/console.dart b/lib/src/components/atoms/console.dart index dfe803d9..1af987ea 100644 --- a/lib/src/components/atoms/console.dart +++ b/lib/src/components/atoms/console.dart @@ -15,8 +15,8 @@ class Console extends HookWidget { this.expand = false, this.processing = false, this.onExpand, - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/lib/src/components/atoms/copy_button.dart b/lib/src/components/atoms/copy_button.dart index 0aa4a157..3d076e4c 100644 --- a/lib/src/components/atoms/copy_button.dart +++ b/lib/src/components/atoms/copy_button.dart @@ -9,21 +9,21 @@ class CopyButton extends HookWidget { /// Constructor const CopyButton( this.content, { - Key? key, - }) : super(key: key); + super.key, + }); /// Content to copy final String content; @override Widget build(BuildContext context) { - final isMounted = useIsMounted(); + final isMounted = context.mounted; return IconButton( iconSize: 20, splashRadius: 20, icon: const Icon(Icons.content_copy), onPressed: () async { await Clipboard.setData(ClipboardData(text: content)); - if (isMounted()) { + if (isMounted) { // ignore: use_build_context_synchronously notify(context.i18n('components:atoms.copiedToClipboard')); } diff --git a/lib/src/components/atoms/empty_dataset.dart b/lib/src/components/atoms/empty_dataset.dart index 90b8e763..5d5d6b03 100644 --- a/lib/src/components/atoms/empty_dataset.dart +++ b/lib/src/components/atoms/empty_dataset.dart @@ -42,8 +42,8 @@ class EmptyDataset extends StatelessWidget { this.iconColor, this.backgroundColor = Colors.black, this.opacity = 0.3, - Key? key, - }) : super(key: key); + super.key, + }); /// Icon final Widget icon; diff --git a/lib/src/components/atoms/group_tile.dart b/lib/src/components/atoms/group_tile.dart index 23c0a706..167f4cfd 100644 --- a/lib/src/components/atoms/group_tile.dart +++ b/lib/src/components/atoms/group_tile.dart @@ -6,12 +6,12 @@ class SkGroupTile extends HookWidget { /// Constructor const SkGroupTile({ required this.title, - Key? key, + super.key, this.leading, this.trailing, this.border = false, this.children = const [], - }) : super(key: key); + }); /// Title widget final Widget title; diff --git a/lib/src/components/atoms/loading_indicator.dart b/lib/src/components/atoms/loading_indicator.dart index 7d54e2d0..dd7c068b 100644 --- a/lib/src/components/atoms/loading_indicator.dart +++ b/lib/src/components/atoms/loading_indicator.dart @@ -5,8 +5,8 @@ import 'package:flutter_spinkit/flutter_spinkit.dart'; class SkLoadingIndicator extends StatelessWidget { /// Constructor const SkLoadingIndicator({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/lib/src/components/atoms/refresh_button.dart b/lib/src/components/atoms/refresh_button.dart index 9d6c5409..214b034d 100644 --- a/lib/src/components/atoms/refresh_button.dart +++ b/lib/src/components/atoms/refresh_button.dart @@ -8,8 +8,8 @@ class RefreshButton extends HookWidget { /// Constructor const RefreshButton({ required this.onPressed, - Key? key, - }) : super(key: key); + super.key, + }); /// On press handler final Future Function() onPressed; diff --git a/lib/src/components/atoms/sliver_animated_switcher.dart b/lib/src/components/atoms/sliver_animated_switcher.dart index 1efed427..c3058515 100644 --- a/lib/src/components/atoms/sliver_animated_switcher.dart +++ b/lib/src/components/atoms/sliver_animated_switcher.dart @@ -6,9 +6,9 @@ import 'package:flutter/material.dart'; class SliverAnimatedSwitcher extends StatefulWidget { /// Constructor const SliverAnimatedSwitcher({ - Key? key, + super.key, required this.child, - }) : super(key: key); + }); /// Child final Widget child; diff --git a/lib/src/components/atoms/sliver_section.dart b/lib/src/components/atoms/sliver_section.dart index c14aaab7..a42b2bf1 100644 --- a/lib/src/components/atoms/sliver_section.dart +++ b/lib/src/components/atoms/sliver_section.dart @@ -5,10 +5,10 @@ import 'package:flutter/rendering.dart'; class SliverSection extends StatelessWidget { /// Constructor const SliverSection({ - Key? key, + super.key, required this.slivers, this.shouldDisplay = false, - }) : super(key: key); + }); /// Slivers final List slivers; diff --git a/lib/src/components/atoms/typography.dart b/lib/src/components/atoms/typography.dart index 9751c550..2d94b571 100644 --- a/lib/src/components/atoms/typography.dart +++ b/lib/src/components/atoms/typography.dart @@ -8,8 +8,8 @@ class Paragraph extends StatelessWidget { this.text, { this.maxLines, this.overflow, - Key? key, - }) : super(key: key); + super.key, + }); /// Text final String text; @@ -39,8 +39,8 @@ class Caption extends StatelessWidget { /// Constructor const Caption( this.text, { - Key? key, - }) : super(key: key); + super.key, + }); /// Text for caption final String text; @@ -58,10 +58,10 @@ class ConsoleText extends StatelessWidget { /// Constructor const ConsoleText( this.text, { - Key? key, + super.key, this.maxLines = 1, this.color, - }) : super(key: key); + }); /// Content for stdout final String text; @@ -90,8 +90,8 @@ class Heading extends StatelessWidget { /// Constructor const Heading( this.text, { - Key? key, - }) : super(key: key); + super.key, + }); /// Content final String text; @@ -110,8 +110,8 @@ class Subheading extends StatelessWidget { /// Constructor const Subheading( this.text, { - Key? key, - }) : super(key: key); + super.key, + }); /// content final String text; diff --git a/lib/src/components/molecules/info_banner.dart b/lib/src/components/molecules/info_banner.dart index a5a3a276..c74c7861 100644 --- a/lib/src/components/molecules/info_banner.dart +++ b/lib/src/components/molecules/info_banner.dart @@ -6,8 +6,8 @@ import '../atoms/typography.dart'; // TODO: Make this generic class InfoBanner extends StatelessWidget { const InfoBanner({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/lib/src/components/molecules/list_tile.dart b/lib/src/components/molecules/list_tile.dart index 083a7c88..f8c33c94 100644 --- a/lib/src/components/molecules/list_tile.dart +++ b/lib/src/components/molecules/list_tile.dart @@ -22,14 +22,14 @@ class SkListTile extends StatelessWidget { /// Constructor const SkListTile({ - Key? key, + super.key, required this.title, this.subtitle, this.leading, this.trailing, this.onTap, this.selected = false, - }) : super(key: key); + }); @override Widget build(BuildContext context) { diff --git a/lib/src/components/molecules/top_app_bar.dart b/lib/src/components/molecules/top_app_bar.dart index 32a6eb07..2095f844 100644 --- a/lib/src/components/molecules/top_app_bar.dart +++ b/lib/src/components/molecules/top_app_bar.dart @@ -15,7 +15,7 @@ import 'package:sidekick/src/window_border.dart'; /// Sidekick top app bar class SkAppBar extends ConsumerWidget implements PreferredSizeWidget { /// Constructor - const SkAppBar({key}) : super(key: key); + const SkAppBar({super.key}); @override Size get preferredSize => const Size.fromHeight(45); diff --git a/lib/src/components/molecules/version_install_button.dart b/lib/src/components/molecules/version_install_button.dart index 8f476b11..3fe09721 100644 --- a/lib/src/components/molecules/version_install_button.dart +++ b/lib/src/components/molecules/version_install_button.dart @@ -14,8 +14,8 @@ class VersionInstallButton extends HookConsumerWidget { const VersionInstallButton( this.version, { - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/lib/src/components/organisms/app_bottom_bar.dart b/lib/src/components/organisms/app_bottom_bar.dart index 0e0424b8..5a5d5a93 100644 --- a/lib/src/components/organisms/app_bottom_bar.dart +++ b/lib/src/components/organisms/app_bottom_bar.dart @@ -7,8 +7,8 @@ import '../atoms/console.dart'; class AppBottomBar extends HookConsumerWidget { const AppBottomBar({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/lib/src/components/organisms/screen.dart b/lib/src/components/organisms/screen.dart index 1dace46a..6e3f59ff 100644 --- a/lib/src/components/organisms/screen.dart +++ b/lib/src/components/organisms/screen.dart @@ -12,8 +12,8 @@ class SkScreen extends StatelessWidget { this.processing = false, this.extendBody = true, required this.child, - Key? key, - }) : super(key: key); + super.key, + }); /// Screen title final String title; diff --git a/lib/src/components/organisms/shortcut_manager.dart b/lib/src/components/organisms/shortcut_manager.dart index 2e74bd58..72b05a5b 100644 --- a/lib/src/components/organisms/shortcut_manager.dart +++ b/lib/src/components/organisms/shortcut_manager.dart @@ -18,10 +18,10 @@ class NavigationIntent extends Intent { class SkShortcutManager extends ConsumerWidget { /// Constructor const SkShortcutManager({ - Key? key, + super.key, required this.child, required this.focusNode, - }) : super(key: key); + }); /// Child final Widget child; diff --git a/lib/src/modules/common/app_shell.dart b/lib/src/modules/common/app_shell.dart index 952effef..b989322c 100644 --- a/lib/src/modules/common/app_shell.dart +++ b/lib/src/modules/common/app_shell.dart @@ -38,8 +38,8 @@ const pages = [ class AppShell extends HookConsumerWidget { /// Constructor const AppShell({ - Key? key, - }) : super(key: key); + super.key, + }); NavigationRailDestination renderNavButton( BuildContext context, @@ -96,12 +96,14 @@ class AppShell extends HookConsumerWidget { if (!compatInfo.ready && !compatInfo.waiting) { notify("Sidekick is missing key components to work", error: true); Future.delayed(Duration.zero).then((value) { - Navigator.pushReplacement( - context, - MaterialPageRoute( - builder: (context) => const CompatCheckScreen(), - ), - ); + if (context.mounted) { + Navigator.pushReplacement( + context, + MaterialPageRoute( + builder: (context) => const CompatCheckScreen(), + ), + ); + } }); } diff --git a/lib/src/modules/common/dto/channel.dto.dart b/lib/src/modules/common/dto/channel.dto.dart index 7ef650b7..bce9144e 100644 --- a/lib/src/modules/common/dto/channel.dto.dart +++ b/lib/src/modules/common/dto/channel.dto.dart @@ -12,19 +12,14 @@ class ChannelDto extends ReleaseDto { /// Constructor ChannelDto({ - required String name, - required Release? release, - required CacheVersion? cache, - required needSetup, + required super.name, + required super.release, + required super.cache, + required super.needSetup, required this.sdkVersion, required this.currentRelease, - required isGlobal, + required super.isGlobal, }) : super( - name: name, - release: release, - needSetup: needSetup, isChannel: true, - cache: cache, - isGlobal: isGlobal, ); } diff --git a/lib/src/modules/common/dto/master.dto.dart b/lib/src/modules/common/dto/master.dto.dart index 6c053b57..2f5664a3 100644 --- a/lib/src/modules/common/dto/master.dto.dart +++ b/lib/src/modules/common/dto/master.dto.dart @@ -1,23 +1,16 @@ -import 'package:fvm/fvm.dart'; - import 'channel.dto.dart'; /// Master channel dto class MasterDto extends ChannelDto { /// Latest version of the channel MasterDto({ - required String name, - required needSetup, - required String? sdkVersion, - required CacheVersion? cache, - required bool isGlobal, + required super.name, + required super.needSetup, + required super.sdkVersion, + required super.cache, + required super.isGlobal, }) : super( - name: name, - needSetup: needSetup, - sdkVersion: sdkVersion, release: null, currentRelease: null, - cache: cache, - isGlobal: isGlobal, ); } diff --git a/lib/src/modules/common/dto/version.dto.dart b/lib/src/modules/common/dto/version.dto.dart index e03b62d5..60bb4f07 100644 --- a/lib/src/modules/common/dto/version.dto.dart +++ b/lib/src/modules/common/dto/version.dto.dart @@ -6,16 +6,10 @@ import 'release.dto.dart'; class VersionDto extends ReleaseDto { /// Constructor VersionDto({ - required String name, - required Release release, - required bool needSetup, - required CacheVersion? cache, - required bool isGlobal, - }) : super( - name: name, - release: release, - needSetup: needSetup, - cache: cache, - isGlobal: isGlobal, - ); + required super.name, + required Release super.release, + required super.needSetup, + required super.cache, + required super.isGlobal, + }); } diff --git a/lib/src/modules/common/utils/indexed_transition_switcher.dart b/lib/src/modules/common/utils/indexed_transition_switcher.dart index a7615286..c65258e0 100644 --- a/lib/src/modules/common/utils/indexed_transition_switcher.dart +++ b/lib/src/modules/common/utils/indexed_transition_switcher.dart @@ -11,8 +11,7 @@ class IndexedTransitionSwitcher extends StatefulWidget { required this.transitionBuilder, this.reverse = false, this.duration = const Duration(milliseconds: 300), - Key? key}) - : super(key: key); + super.key}); /// The index of the child to show. final int index; diff --git a/lib/src/modules/compatibility_checks/compat.dialog.dart b/lib/src/modules/compatibility_checks/compat.dialog.dart index 7f019b78..1be56005 100644 --- a/lib/src/modules/compatibility_checks/compat.dialog.dart +++ b/lib/src/modules/compatibility_checks/compat.dialog.dart @@ -13,8 +13,8 @@ import 'compat.utils.dart'; class CompatDialog extends ConsumerWidget { const CompatDialog({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/lib/src/modules/compatibility_checks/compat.screen.dart b/lib/src/modules/compatibility_checks/compat.screen.dart index 88a9604f..688e1f30 100644 --- a/lib/src/modules/compatibility_checks/compat.screen.dart +++ b/lib/src/modules/compatibility_checks/compat.screen.dart @@ -15,8 +15,8 @@ import 'compat.dialog.dart'; class CompatCheckScreen extends ConsumerWidget { /// Constructor const CompatCheckScreen({ - key, - }) : super(key: key); + super.key, + }); /// Current nav section @override diff --git a/lib/src/modules/fvm/components/fvm_cache_size.dart b/lib/src/modules/fvm/components/fvm_cache_size.dart index 3ca579de..aa07433b 100644 --- a/lib/src/modules/fvm/components/fvm_cache_size.dart +++ b/lib/src/modules/fvm/components/fvm_cache_size.dart @@ -11,8 +11,8 @@ import '../fvm.provider.dart'; class FvmCacheSize extends HookConsumerWidget { /// Constructor const FvmCacheSize({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/lib/src/modules/fvm/components/fvm_empty_releases.dart b/lib/src/modules/fvm/components/fvm_empty_releases.dart index 6aaab6b1..9773f547 100644 --- a/lib/src/modules/fvm/components/fvm_empty_releases.dart +++ b/lib/src/modules/fvm/components/fvm_empty_releases.dart @@ -7,8 +7,8 @@ import '../../navigation/navigation.provider.dart'; class EmptyVersions extends ConsumerWidget { const EmptyVersions({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context, WidgetRef ref) { @@ -34,7 +34,7 @@ class EmptyVersions extends ConsumerWidget { const SizedBox(height: 20), ElevatedButton.icon( style: ButtonStyle( - padding: MaterialStateProperty.resolveWith( + padding: WidgetStateProperty.resolveWith( (states) => const EdgeInsets.fromLTRB(30, 15, 30, 15), )), onPressed: () { diff --git a/lib/src/modules/fvm/components/fvm_master_status.dart b/lib/src/modules/fvm/components/fvm_master_status.dart index 9ce157cf..14dbec66 100644 --- a/lib/src/modules/fvm/components/fvm_master_status.dart +++ b/lib/src/modules/fvm/components/fvm_master_status.dart @@ -9,8 +9,8 @@ class FvmMasterStatus extends StatelessWidget { /// Constructor const FvmMasterStatus( this.masterChannel, { - Key? key, - }) : super(key: key); + super.key, + }); /// Master final MasterDto masterChannel; diff --git a/lib/src/modules/fvm/components/fvm_release_actions.dart b/lib/src/modules/fvm/components/fvm_release_actions.dart index 745c399f..9fdb27b7 100644 --- a/lib/src/modules/fvm/components/fvm_release_actions.dart +++ b/lib/src/modules/fvm/components/fvm_release_actions.dart @@ -29,8 +29,8 @@ class FvmReleaseActions extends ConsumerWidget { /// Constructor const FvmReleaseActions( this.release, { - Key? key, - }) : super(key: key); + super.key, + }); /// Release final ReleaseDto release; diff --git a/lib/src/modules/fvm/components/fvm_release_list_item.dart b/lib/src/modules/fvm/components/fvm_release_list_item.dart index 9074bf39..b0f9f675 100644 --- a/lib/src/modules/fvm/components/fvm_release_list_item.dart +++ b/lib/src/modules/fvm/components/fvm_release_list_item.dart @@ -16,8 +16,8 @@ class FvmReleaseListItem extends ConsumerWidget { /// Constructor const FvmReleaseListItem( this.release, { - Key? key, - }) : super(key: key); + super.key, + }); /// Release final ReleaseDto release; diff --git a/lib/src/modules/fvm/components/fvm_release_status.dart b/lib/src/modules/fvm/components/fvm_release_status.dart index ff2a7911..83b15082 100644 --- a/lib/src/modules/fvm/components/fvm_release_status.dart +++ b/lib/src/modules/fvm/components/fvm_release_status.dart @@ -14,8 +14,8 @@ class FvmReleaseStatus extends ConsumerWidget { /// Constructor const FvmReleaseStatus( this.release, { - Key? key, - }) : super(key: key); + super.key, + }); /// Release final ReleaseDto release; diff --git a/lib/src/modules/fvm/components/fvm_setup_button.dart b/lib/src/modules/fvm/components/fvm_setup_button.dart index fae0c13f..fd8e1a3e 100644 --- a/lib/src/modules/fvm/components/fvm_setup_button.dart +++ b/lib/src/modules/fvm/components/fvm_setup_button.dart @@ -11,8 +11,8 @@ class SetupButton extends ConsumerWidget { /// Constructor const SetupButton({ required this.release, - Key? key, - }) : super(key: key); + super.key, + }); /// Release final ReleaseDto release; diff --git a/lib/src/modules/fvm/dialogs/cleanup_unused_dialog.dart b/lib/src/modules/fvm/dialogs/cleanup_unused_dialog.dart index d9cf733e..ef27c7b5 100644 --- a/lib/src/modules/fvm/dialogs/cleanup_unused_dialog.dart +++ b/lib/src/modules/fvm/dialogs/cleanup_unused_dialog.dart @@ -80,9 +80,9 @@ Future cleanupUnusedDialog(BuildContext context, WidgetRef ref) async { }); }, ); - }).toList() + }) ], - ).toList() + ) ], ), ), diff --git a/lib/src/modules/fvm/dialogs/fvm_global_dialog.dart b/lib/src/modules/fvm/dialogs/fvm_global_dialog.dart index f6e5ab90..c42af0c2 100644 --- a/lib/src/modules/fvm/dialogs/fvm_global_dialog.dart +++ b/lib/src/modules/fvm/dialogs/fvm_global_dialog.dart @@ -14,88 +14,91 @@ Future showGlobalInfoDialog(BuildContext context) async { final configured = await FVMClient.checkIfGlobalConfigured(); // ignore: use_build_context_synchronously - await showDialog( - context: context, - builder: (context) { - return AlertDialog( - title: Heading( - context.i18n('modules:fvm.dialogs.globalConfiguration'), - ), - actions: [ - TextButton( - style: ButtonStyle( - padding: MaterialStateProperty.resolveWith( - (states) => const EdgeInsets.all(20), - )), - onPressed: () { - Navigator.of(context).pop(); - }, - child: Text(context.i18n('modules:fvm.dialogs.ok')), + if (context.mounted) { + await showDialog( + context: context, + builder: (context) { + return AlertDialog( + title: Heading( + context.i18n('modules:fvm.dialogs.globalConfiguration'), ), - ], - content: Column( - crossAxisAlignment: CrossAxisAlignment.start, - mainAxisSize: MainAxisSize.min, - children: [ - Subheading( - context.i18n('modules:fvm.dialogs.flutterPathIsPointingOn'), - ), - // Caption('${configured.currentPath}.\n\n'), - Flexible( - child: Text.rich( - TextSpan(children: [ - TextSpan( - text: configured.currentPath, - style: Theme.of(context).textTheme.bodySmall), - WidgetSpan( - alignment: PlaceholderAlignment.middle, - child: IconButton( - icon: const Icon(Icons.copy, size: 14), - onPressed: () { - if (configured.currentPath == null) return; - Clipboard.setData( - ClipboardData(text: configured.currentPath!), - ); - }), - ) - ]), - overflow: TextOverflow.ellipsis, - ), - ), - const SizedBox(height: 12), - - !configured.isSetup - ? Column( - children: [ - Subheading( - context.i18n('modules:fvm.dialogs.changeThePathTo') + - context.i18n( - 'modules:fvm.dialogs.ifYouWantToFlutterSdkThroughFvm'), - ), - Row( - children: [ - Caption(configured.correctPath), - CopyButton(configured.correctPath) - ], - ) - ], - ) - : Container(), - const SizedBox(height: 10), - TextButton.icon( + actions: [ + TextButton( + style: ButtonStyle( + padding: WidgetStateProperty.resolveWith( + (states) => const EdgeInsets.all(20), + )), onPressed: () { - final os = Platform.operatingSystem; - openLink( - 'https://flutter.dev/docs/get-started/install/$os#update-your-path', - ); + Navigator.of(context).pop(); }, - icon: const Icon(MdiIcons.informationOutline), - label: Text( - context.i18n('modules:fvm.dialogs.howToUpdateYourPath'), - ), - ) + child: Text(context.i18n('modules:fvm.dialogs.ok')), + ), ], - ), - ); - }); + content: Column( + crossAxisAlignment: CrossAxisAlignment.start, + mainAxisSize: MainAxisSize.min, + children: [ + Subheading( + context.i18n('modules:fvm.dialogs.flutterPathIsPointingOn'), + ), + // Caption('${configured.currentPath}.\n\n'), + Flexible( + child: Text.rich( + TextSpan(children: [ + TextSpan( + text: configured.currentPath, + style: Theme.of(context).textTheme.bodySmall), + WidgetSpan( + alignment: PlaceholderAlignment.middle, + child: IconButton( + icon: const Icon(Icons.copy, size: 14), + onPressed: () { + if (configured.currentPath == null) return; + Clipboard.setData( + ClipboardData(text: configured.currentPath!), + ); + }), + ) + ]), + overflow: TextOverflow.ellipsis, + ), + ), + const SizedBox(height: 12), + + !configured.isSetup + ? Column( + children: [ + Subheading( + context.i18n( + 'modules:fvm.dialogs.changeThePathTo') + + context.i18n( + 'modules:fvm.dialogs.ifYouWantToFlutterSdkThroughFvm'), + ), + Row( + children: [ + Caption(configured.correctPath), + CopyButton(configured.correctPath) + ], + ) + ], + ) + : Container(), + const SizedBox(height: 10), + TextButton.icon( + onPressed: () { + final os = Platform.operatingSystem; + openLink( + 'https://flutter.dev/docs/get-started/install/$os#update-your-path', + ); + }, + icon: const Icon(MdiIcons.informationOutline), + label: Text( + context.i18n('modules:fvm.dialogs.howToUpdateYourPath'), + ), + ) + ], + ), + ); + }); + } } diff --git a/lib/src/modules/fvm/fvm.screen.dart b/lib/src/modules/fvm/fvm.screen.dart index cd83dc58..4b1f8e3a 100644 --- a/lib/src/modules/fvm/fvm.screen.dart +++ b/lib/src/modules/fvm/fvm.screen.dart @@ -11,7 +11,7 @@ import 'components/fvm_release_list_item.dart'; import 'dialogs/cleanup_unused_dialog.dart'; class FVMScreen extends ConsumerWidget { - const FVMScreen({Key? key}) : super(key: key); + const FVMScreen({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/lib/src/modules/projects/components/project_actions.dart b/lib/src/modules/projects/components/project_actions.dart index 985c5b4e..fb141328 100644 --- a/lib/src/modules/projects/components/project_actions.dart +++ b/lib/src/modules/projects/components/project_actions.dart @@ -22,8 +22,8 @@ class ProjectActions extends ConsumerWidget { /// Constructor const ProjectActions( this.project, { - Key? key, - }) : super(key: key); + super.key, + }); /// Project final Project project; diff --git a/lib/src/modules/projects/components/project_list_item.dart b/lib/src/modules/projects/components/project_list_item.dart index 48d39407..e60d5c30 100644 --- a/lib/src/modules/projects/components/project_list_item.dart +++ b/lib/src/modules/projects/components/project_list_item.dart @@ -19,8 +19,8 @@ class ProjectListItem extends ConsumerWidget { const ProjectListItem( this.project, { this.versionSelect = false, - key, - }) : super(key: key); + super.key, + }); /// Flutter project final FlutterProject project; diff --git a/lib/src/modules/projects/components/project_release_select.dart b/lib/src/modules/projects/components/project_release_select.dart index a7876db3..26868e0e 100644 --- a/lib/src/modules/projects/components/project_release_select.dart +++ b/lib/src/modules/projects/components/project_release_select.dart @@ -14,8 +14,8 @@ class ProjectReleaseSelect extends ConsumerWidget { const ProjectReleaseSelect({ required this.project, required this.releases, - Key? key, - }) : super(key: key); + super.key, + }); /// Project final FlutterProject project; diff --git a/lib/src/modules/projects/components/projects_empty.dart b/lib/src/modules/projects/components/projects_empty.dart index 2171c32c..3112f3fe 100644 --- a/lib/src/modules/projects/components/projects_empty.dart +++ b/lib/src/modules/projects/components/projects_empty.dart @@ -7,7 +7,7 @@ import '../../../components/atoms/empty_dataset.dart'; /// Empty project screen class EmptyProjects extends StatelessWidget { /// Constructor - const EmptyProjects({key}) : super(key: key); + const EmptyProjects({super.key}); @override Widget build(BuildContext context) { diff --git a/lib/src/modules/projects/project.dto.dart b/lib/src/modules/projects/project.dto.dart index 4cca967f..f545fb30 100644 --- a/lib/src/modules/projects/project.dto.dart +++ b/lib/src/modules/projects/project.dto.dart @@ -1,4 +1,3 @@ -import 'dart:io'; import 'package:fvm/fvm.dart'; import 'package:hive/hive.dart'; @@ -12,14 +11,12 @@ class FlutterProject extends Project { final String name; FlutterProject._({ required this.name, - required FvmConfig config, - required Directory projectDir, + required super.config, + required super.projectDir, required this.pubspec, this.invalid = false, }) : super( name: name, - config: config, - projectDir: projectDir, isFlutterProject: true, ); diff --git a/lib/src/modules/projects/projects.screen.dart b/lib/src/modules/projects/projects.screen.dart index 81bdf326..699cf0e6 100644 --- a/lib/src/modules/projects/projects.screen.dart +++ b/lib/src/modules/projects/projects.screen.dart @@ -20,7 +20,7 @@ import 'projects.provider.dart'; /// Projects screen class ProjectsScreen extends HookConsumerWidget { /// Constructor - const ProjectsScreen({Key? key}) : super(key: key); + const ProjectsScreen({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/lib/src/modules/releases/components/channel_showcase_item.dart b/lib/src/modules/releases/components/channel_showcase_item.dart index 69a8545d..6dc7f69b 100644 --- a/lib/src/modules/releases/components/channel_showcase_item.dart +++ b/lib/src/modules/releases/components/channel_showcase_item.dart @@ -12,8 +12,8 @@ class ChannelShowcaseItem extends ConsumerWidget { /// Constructor const ChannelShowcaseItem( this.channel, { - Key? key, - }) : super(key: key); + super.key, + }); /// Channel final ChannelDto channel; diff --git a/lib/src/modules/releases/components/release_list_item.dart b/lib/src/modules/releases/components/release_list_item.dart index e9d297d0..7e474289 100644 --- a/lib/src/modules/releases/components/release_list_item.dart +++ b/lib/src/modules/releases/components/release_list_item.dart @@ -12,8 +12,8 @@ class ReleaseListItem extends ConsumerWidget { /// Constructor const ReleaseListItem( this.release, { - Key? key, - }) : super(key: key); + super.key, + }); /// Release in item final ReleaseDto release; diff --git a/lib/src/modules/releases/releases.screen.dart b/lib/src/modules/releases/releases.screen.dart index 22e16e46..df99d8b3 100644 --- a/lib/src/modules/releases/releases.screen.dart +++ b/lib/src/modules/releases/releases.screen.dart @@ -12,8 +12,8 @@ import 'releases.provider.dart'; class ReleasesScreen extends ConsumerWidget { const ReleasesScreen({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/lib/src/modules/sandbox/components/sandbox_terminal.dart b/lib/src/modules/sandbox/components/sandbox_terminal.dart index cb974b42..38dec172 100644 --- a/lib/src/modules/sandbox/components/sandbox_terminal.dart +++ b/lib/src/modules/sandbox/components/sandbox_terminal.dart @@ -16,8 +16,8 @@ class SandboxTerminal extends HookConsumerWidget { const SandboxTerminal({ required this.project, required this.release, - Key? key, - }) : super(key: key); + super.key, + }); /// Project final Project project; @@ -119,14 +119,14 @@ class SandboxTerminal extends HookConsumerWidget { }); } - void handlekeyDown(RawKeyEvent key) { + void handlekeyDown(KeyEvent key) { if (key.runtimeType.toString() == 'RawKeyDownEvent') { - if (key.data.logicalKey == LogicalKeyboardKey.arrowUp) { + if (key.logicalKey == LogicalKeyboardKey.arrowUp) { if (terminalState.cmdHistory.length > currentCmdIdx.value) { moveCmdIndex(1); } } - if (key.data.logicalKey == LogicalKeyboardKey.arrowDown) { + if (key.logicalKey == LogicalKeyboardKey.arrowDown) { if (currentCmdIdx.value > 0) { moveCmdIndex(-1); } @@ -163,9 +163,9 @@ class SandboxTerminal extends HookConsumerWidget { child: Row( children: [ Expanded( - child: RawKeyboardListener( + child: KeyboardListener( focusNode: keyListenerFocus, - onKey: handlekeyDown, + onKeyEvent: handlekeyDown, child: TextField( focusNode: focus, enabled: !terminalState.processing, diff --git a/lib/src/modules/sandbox/sandbox.screen.dart b/lib/src/modules/sandbox/sandbox.screen.dart index b29ef656..942094a0 100644 --- a/lib/src/modules/sandbox/sandbox.screen.dart +++ b/lib/src/modules/sandbox/sandbox.screen.dart @@ -18,8 +18,8 @@ class SandboxScreen extends HookConsumerWidget { /// Constructor const SandboxScreen({ required this.project, - Key? key, - }) : super(key: key); + super.key, + }); /// Project final Project project; diff --git a/lib/src/modules/search/components/search_bar.dart b/lib/src/modules/search/components/search_bar.dart index 205a9532..1f727527 100644 --- a/lib/src/modules/search/components/search_bar.dart +++ b/lib/src/modules/search/components/search_bar.dart @@ -14,10 +14,10 @@ import 'search_results_list.dart'; class SearchBar extends HookConsumerWidget { /// Constructor const SearchBar({ - Key? key, + super.key, // required this.onFocusChanged, // required this.showSearch, - }) : super(key: key); + }); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/lib/src/modules/search/components/search_results_list.dart b/lib/src/modules/search/components/search_results_list.dart index 05739dd0..1a95f0e9 100644 --- a/lib/src/modules/search/components/search_results_list.dart +++ b/lib/src/modules/search/components/search_results_list.dart @@ -12,8 +12,8 @@ class SearchResultsList extends StatelessWidget { /// Constructor const SearchResultsList( this.results, { - Key? key, - }) : super(key: key); + super.key, + }); /// Search results final SearchResults results; diff --git a/lib/src/modules/selected_detail/components/advanced_info_tile.dart b/lib/src/modules/selected_detail/components/advanced_info_tile.dart index f248f702..c58ec88f 100644 --- a/lib/src/modules/selected_detail/components/advanced_info_tile.dart +++ b/lib/src/modules/selected_detail/components/advanced_info_tile.dart @@ -13,8 +13,8 @@ class AdvancedInfoTile extends StatelessWidget { /// Constructor const AdvancedInfoTile( this.release, { - Key? key, - }) : super(key: key); + super.key, + }); /// Release final ReleaseDto release; diff --git a/lib/src/modules/selected_detail/components/cache_date_display.dart b/lib/src/modules/selected_detail/components/cache_date_display.dart index dd07fa6d..54032326 100644 --- a/lib/src/modules/selected_detail/components/cache_date_display.dart +++ b/lib/src/modules/selected_detail/components/cache_date_display.dart @@ -11,8 +11,8 @@ class CacheDateDisplay extends HookWidget { /// Constructor const CacheDateDisplay( this.release, { - Key? key, - }) : super(key: key); + super.key, + }); /// Release final ReleaseDto? release; diff --git a/lib/src/modules/selected_detail/components/cache_info_tile.dart b/lib/src/modules/selected_detail/components/cache_info_tile.dart index 33511bc1..7cfd1707 100644 --- a/lib/src/modules/selected_detail/components/cache_info_tile.dart +++ b/lib/src/modules/selected_detail/components/cache_info_tile.dart @@ -13,8 +13,8 @@ class FvmInfoTile extends StatelessWidget { /// Constructor const FvmInfoTile( this.release, { - Key? key, - }) : super(key: key); + super.key, + }); /// Release final ReleaseDto release; diff --git a/lib/src/modules/selected_detail/components/info_drawer.dart b/lib/src/modules/selected_detail/components/info_drawer.dart index 8529427b..dde944d9 100644 --- a/lib/src/modules/selected_detail/components/info_drawer.dart +++ b/lib/src/modules/selected_detail/components/info_drawer.dart @@ -15,8 +15,8 @@ import 'release_info_section.dart'; class SelectedDetailDrawer extends ConsumerWidget { /// Constructors const SelectedDetailDrawer({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/lib/src/modules/selected_detail/components/reference_info_tile.dart b/lib/src/modules/selected_detail/components/reference_info_tile.dart index e9c78cb7..9b089674 100644 --- a/lib/src/modules/selected_detail/components/reference_info_tile.dart +++ b/lib/src/modules/selected_detail/components/reference_info_tile.dart @@ -13,8 +13,8 @@ class ReferenceInfoTile extends StatelessWidget { final ReleaseDto version; const ReferenceInfoTile( this.version, { - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/lib/src/modules/selected_detail/components/release_info_section.dart b/lib/src/modules/selected_detail/components/release_info_section.dart index 3d68acd3..fd1a0d81 100644 --- a/lib/src/modules/selected_detail/components/release_info_section.dart +++ b/lib/src/modules/selected_detail/components/release_info_section.dart @@ -10,8 +10,8 @@ class ReleaseInfoSection extends StatelessWidget { final ReleaseDto version; const ReleaseInfoSection( this.version, { - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/lib/src/modules/settings/scenes/flutter_settings.scene.dart b/lib/src/modules/settings/scenes/flutter_settings.scene.dart index 6cbede1f..95a93f4b 100644 --- a/lib/src/modules/settings/scenes/flutter_settings.scene.dart +++ b/lib/src/modules/settings/scenes/flutter_settings.scene.dart @@ -12,8 +12,8 @@ class SettingsSectionFlutter extends ConsumerWidget { const SettingsSectionFlutter( this.settings, this.onSave, { - Key? key, - }) : super(key: key); + super.key, + }); /// Settings final AllSettings settings; diff --git a/lib/src/modules/settings/scenes/fvm_settings.scene.dart b/lib/src/modules/settings/scenes/fvm_settings.scene.dart index 8947279c..7ed28243 100644 --- a/lib/src/modules/settings/scenes/fvm_settings.scene.dart +++ b/lib/src/modules/settings/scenes/fvm_settings.scene.dart @@ -9,8 +9,8 @@ class FvmSettingsScene extends StatelessWidget { const FvmSettingsScene( this.settings, this.onSave, { - Key? key, - }) : super(key: key); + super.key, + }); /// Settings final AllSettings settings; diff --git a/lib/src/modules/settings/scenes/general_settings.scene.dart b/lib/src/modules/settings/scenes/general_settings.scene.dart index da3d31b9..04234272 100644 --- a/lib/src/modules/settings/scenes/general_settings.scene.dart +++ b/lib/src/modules/settings/scenes/general_settings.scene.dart @@ -14,8 +14,8 @@ class SettingsSectionGeneral extends StatelessWidget { const SettingsSectionGeneral( this.settings, this.onSave, { - Key? key, - }) : super(key: key); + super.key, + }); /// Settings final AllSettings settings; @@ -133,7 +133,7 @@ class SettingsSectionGeneral extends StatelessWidget { ], ), )) - .toList() + ], onChanged: (val) async { if (val == "Custom") { diff --git a/lib/src/modules/settings/settings.screen.dart b/lib/src/modules/settings/settings.screen.dart index d77d0a5a..5f0f70e4 100644 --- a/lib/src/modules/settings/settings.screen.dart +++ b/lib/src/modules/settings/settings.screen.dart @@ -35,8 +35,8 @@ class SettingsScreen extends HookConsumerWidget { /// Constructor const SettingsScreen({ this.section = NavSection.general, - key, - }) : super(key: key); + super.key, + }); /// Current nav section final NavSection section; diff --git a/lib/src/modules/updater/components/update_button.dart b/lib/src/modules/updater/components/update_button.dart index 8348eff6..389f4862 100644 --- a/lib/src/modules/updater/components/update_button.dart +++ b/lib/src/modules/updater/components/update_button.dart @@ -1,5 +1,4 @@ import 'package:flutter/material.dart'; -import 'package:flutter_hooks/flutter_hooks.dart'; import 'package:hooks_riverpod/hooks_riverpod.dart'; import 'package:material_design_icons_flutter/material_design_icons_flutter.dart'; import 'package:sidekick/src/modules/common/utils/helpers.dart'; @@ -11,8 +10,8 @@ import '../updater.provider.dart'; class SkUpdateButton extends HookConsumerWidget { /// Constructor const SkUpdateButton({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context, WidgetRef ref) { @@ -24,7 +23,7 @@ class SkUpdateButton extends HookConsumerWidget { return const SizedBox(height: 0, width: 0); } - final isMounted = useIsMounted(); + final isMounted = context.mounted; void showUpdateDialog() { // flutter defined function @@ -63,7 +62,7 @@ class SkUpdateButton extends HookConsumerWidget { onPressed: () async { await updater.openInstaller(context); // ignore: use_build_context_synchronously - if (isMounted()) Navigator.of(context).pop(); + if (isMounted) Navigator.of(context).pop(); }, child: Text(context.i18n('modules:updater.components.updateNow')), diff --git a/lib/src/modules/updater/components/update_info.dart b/lib/src/modules/updater/components/update_info.dart index d0c1691d..2ff25ff6 100644 --- a/lib/src/modules/updater/components/update_info.dart +++ b/lib/src/modules/updater/components/update_info.dart @@ -9,8 +9,8 @@ import '../updater.provider.dart'; class SkUpdateInfo extends ConsumerWidget { /// Constructor const SkUpdateInfo({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context, WidgetRef ref) { diff --git a/lib/src/screens/error_db_screen.dart b/lib/src/screens/error_db_screen.dart index 052742eb..9923c8bc 100644 --- a/lib/src/screens/error_db_screen.dart +++ b/lib/src/screens/error_db_screen.dart @@ -8,8 +8,8 @@ import 'package:window_manager/window_manager.dart'; class ErrorDBScreen extends StatelessWidget { const ErrorDBScreen({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { @@ -56,7 +56,7 @@ class ErrorDBScreen extends StatelessWidget { children: [ TextButton.icon( style: ButtonStyle( - padding: MaterialStateProperty.resolveWith( + padding: WidgetStateProperty.resolveWith( (states) => const EdgeInsets.symmetric( horizontal: 20, vertical: 10))), onPressed: () { diff --git a/lib/src/window_border.dart b/lib/src/window_border.dart index 448bc71e..4898dce6 100644 --- a/lib/src/window_border.dart +++ b/lib/src/window_border.dart @@ -5,8 +5,8 @@ const sidebarColor = Color(0xFFF6A00C); class LeftSide extends StatelessWidget { const LeftSide({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { @@ -28,8 +28,8 @@ const backgroundEndColor = Color(0xFFF6A00C); class RightSide extends StatelessWidget { const RightSide({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { @@ -54,8 +54,8 @@ class RightSide extends StatelessWidget { class WindowButtons extends StatelessWidget { const WindowButtons({ - Key? key, - }) : super(key: key); + super.key, + }); @override Widget build(BuildContext context) { diff --git a/macos/Flutter/GeneratedPluginRegistrant.swift b/macos/Flutter/GeneratedPluginRegistrant.swift index f6465da9..a6bb8002 100644 --- a/macos/Flutter/GeneratedPluginRegistrant.swift +++ b/macos/Flutter/GeneratedPluginRegistrant.swift @@ -14,7 +14,6 @@ import screen_retriever import shared_preferences_foundation import url_launcher_macos import window_manager -import window_size func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { BitsdojoWindowPlugin.register(with: registry.registrar(forPlugin: "BitsdojoWindowPlugin")) @@ -26,5 +25,4 @@ func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { SharedPreferencesPlugin.register(with: registry.registrar(forPlugin: "SharedPreferencesPlugin")) UrlLauncherPlugin.register(with: registry.registrar(forPlugin: "UrlLauncherPlugin")) WindowManagerPlugin.register(with: registry.registrar(forPlugin: "WindowManagerPlugin")) - WindowSizePlugin.register(with: registry.registrar(forPlugin: "WindowSizePlugin")) } diff --git a/macos/Podfile.lock b/macos/Podfile.lock index d9b1734f..cefcffd0 100644 --- a/macos/Podfile.lock +++ b/macos/Podfile.lock @@ -20,8 +20,6 @@ PODS: - FlutterMacOS - window_manager (0.2.0): - FlutterMacOS - - window_size (0.0.2): - - FlutterMacOS DEPENDENCIES: - bitsdojo_window_macos (from `Flutter/ephemeral/.symlinks/plugins/bitsdojo_window_macos/macos`) @@ -34,7 +32,6 @@ DEPENDENCIES: - shared_preferences_foundation (from `Flutter/ephemeral/.symlinks/plugins/shared_preferences_foundation/darwin`) - url_launcher_macos (from `Flutter/ephemeral/.symlinks/plugins/url_launcher_macos/macos`) - window_manager (from `Flutter/ephemeral/.symlinks/plugins/window_manager/macos`) - - window_size (from `Flutter/ephemeral/.symlinks/plugins/window_size/macos`) EXTERNAL SOURCES: bitsdojo_window_macos: @@ -57,8 +54,6 @@ EXTERNAL SOURCES: :path: Flutter/ephemeral/.symlinks/plugins/url_launcher_macos/macos window_manager: :path: Flutter/ephemeral/.symlinks/plugins/window_manager/macos - window_size: - :path: Flutter/ephemeral/.symlinks/plugins/window_size/macos SPEC CHECKSUMS: bitsdojo_window_macos: 44e3b8fe3dd463820e0321f6256c5b1c16bb6a00 @@ -71,7 +66,6 @@ SPEC CHECKSUMS: shared_preferences_foundation: fcdcbc04712aee1108ac7fda236f363274528f78 url_launcher_macos: 5f437abeda8c85500ceb03f5c1938a8c5a705399 window_manager: 3a1844359a6295ab1e47659b1a777e36773cd6e8 - window_size: 339dafa0b27a95a62a843042038fa6c3c48de195 PODFILE CHECKSUM: 7aa1d423c1515a30c2de10403d141950ff9e7ad2 diff --git a/macos/Runner.xcodeproj/project.pbxproj b/macos/Runner.xcodeproj/project.pbxproj index a821fb5a..92da82c7 100644 --- a/macos/Runner.xcodeproj/project.pbxproj +++ b/macos/Runner.xcodeproj/project.pbxproj @@ -274,7 +274,6 @@ "${BUILT_PRODUCTS_DIR}/shared_preferences_foundation/shared_preferences_foundation.framework", "${BUILT_PRODUCTS_DIR}/url_launcher_macos/url_launcher_macos.framework", "${BUILT_PRODUCTS_DIR}/window_manager/window_manager.framework", - "${BUILT_PRODUCTS_DIR}/window_size/window_size.framework", ); name = "[CP] Embed Pods Frameworks"; outputPaths = ( @@ -287,7 +286,6 @@ "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/shared_preferences_foundation.framework", "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/url_launcher_macos.framework", "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/window_manager.framework", - "${TARGET_BUILD_DIR}/${FRAMEWORKS_FOLDER_PATH}/window_size.framework", ); runOnlyForDeploymentPostprocessing = 0; shellPath = /bin/sh; diff --git a/pubspec.lock b/pubspec.lock index 055acc95..e365ef41 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -597,12 +597,11 @@ packages: i18next: dependency: "direct main" description: - path: "." - ref: HEAD - resolved-ref: "01006cb864af334208a835dfe6e4ee34bf0dd592" - url: "https://github.com/Ahmadre/i18next.git" - source: git - version: "0.6.1" + name: i18next + sha256: "4a2eb141fa5e20aad966ac29b4dad2293ab150f98ac3f70c69da986f426e669f" + url: "https://pub.flutter-io.cn" + source: hosted + version: "0.7.3" image: dependency: transitive description: @@ -774,68 +773,67 @@ packages: open_file: dependency: "direct main" description: - path: open_file - ref: HEAD - resolved-ref: fae7cb62566775bd07801c0f1fcd60d7cb1311af - url: "https://github.com/crazecoder/open_file" - source: git - version: "3.5.1" + name: open_file + sha256: de371f549b1320a48980952473fae1903d4927975506534c8ea4643642eb5f98 + url: "https://pub.flutter-io.cn" + source: hosted + version: "3.5.3" open_file_android: dependency: transitive description: name: open_file_android - sha256: "43f9ddb0e2eb76e560f44c83ea1959962699526b6f59ec88f87eca009271c56f" + sha256: b5e1a2e9c5ea8e256b015403e94299039627c7205c2a5e6bb426c33235b6ca9a url: "https://pub.flutter-io.cn" source: hosted - version: "1.0.0" + version: "1.0.2" open_file_ios: dependency: transitive description: name: open_file_ios - sha256: "9f019f10045dc88c0c01acdac9ee038cbaa0dc898e756aa336d6b015cdb8ddb9" + sha256: "8d9c03495cf14ca70bdbf191894b822ba3b2629cc0046ee311cbbe504db66c44" url: "https://pub.flutter-io.cn" source: hosted - version: "1.0.0" + version: "1.0.2" open_file_linux: dependency: transitive description: name: open_file_linux - sha256: "2c7c8e6a9ce430b2fae8cbc5551466369d657402c1527eef49be5c9cc9c92944" + sha256: cd2088722048b9c40f8615c6d83005fe0726e0e447e9cdfb40c2b65477291f7d url: "https://pub.flutter-io.cn" source: hosted - version: "0.0.3" + version: "0.0.4" open_file_mac: dependency: transitive description: name: open_file_mac - sha256: f878b6863af99e6abae4cde8c4c1fe2e58e1e7f3f0c4c5e4c65fb2e697cbd28d + sha256: "9d809f528cccc6dc9390caf50893eae9a6944e0f3b8a2558c7ad19e91c9244a1" url: "https://pub.flutter-io.cn" source: hosted - version: "1.0.0" + version: "1.0.1" open_file_platform_interface: dependency: transitive description: name: open_file_platform_interface - sha256: e410d18264a0f3166f0c7f5460e931920a14f680ec38e2a25c8e0a8a901da838 + sha256: "14c50efb1a9667cb96e4fa68d601e6ad348fe337b02789834029b37ae3631498" url: "https://pub.flutter-io.cn" source: hosted - version: "1.0.1" + version: "1.0.2" open_file_web: dependency: transitive description: name: open_file_web - sha256: "34d1da10b30911066c939f11b79f420ecb85e0c3372eefa7c1adb37693dc930e" + sha256: ba35c6f38c21c2bb4268a80927bb828353dda0edfce92e274e0b9639e4f31360 url: "https://pub.flutter-io.cn" source: hosted - version: "0.0.1" + version: "0.0.2" open_file_windows: dependency: transitive description: name: open_file_windows - sha256: a13e754c131eabf3a8e5dce0adb2fff4e3827fe3acd71219da3a57f65a22920c + sha256: "2f4318d2d3958ec8d63b6dd4430c15b1fcb2fe7a2113e83c734584501a5c6d81" url: "https://pub.flutter-io.cn" source: hosted - version: "0.0.1" + version: "0.0.2" package_config: dependency: transitive description: @@ -1345,15 +1343,6 @@ packages: url: "https://pub.flutter-io.cn" source: hosted version: "0.4.2" - window_size: - dependency: "direct main" - description: - path: "plugins/window_size" - ref: HEAD - resolved-ref: eb3964990cf19629c89ff8cb4a37640c7b3d5601 - url: "https://github.com/google/flutter-desktop-embedding.git" - source: git - version: "0.1.0" xdg_directories: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index 6b92e654..7ae9d429 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -33,16 +33,12 @@ dependencies: hive_flutter: ^1.0.0 hooks_riverpod: ^2.1.3 http: ^1.2.2 - i18next: - git: https://github.com/Ahmadre/i18next.git + i18next: ^0.7.3 intl: 0.19.0 material_design_icons_flutter: ^6.0.7096 material_floating_search_bar_2: ^0.5.0 oktoast: ^3.2.0 - open_file: - git: - url: https://github.com/crazecoder/open_file - path: open_file + open_file: ^3.5.3 path: ^1.8.3 path_provider: ^2.0.1 pool: ^1.5.1 @@ -54,11 +50,7 @@ dependencies: system_info2: ^4.0.0 url_launcher: ^6.0.4 watcher: ^1.0.0 - window_manager: ">=0.2.3" - window_size: - git: - url: https://github.com/google/flutter-desktop-embedding.git - path: plugins/window_size + window_manager: ^0.4.2 dev_dependencies: build_runner: ^2.4.6