diff --git a/.metadata b/.metadata index 6eb54a1..ef8804a 100644 --- a/.metadata +++ b/.metadata @@ -15,21 +15,6 @@ migration: - platform: root create_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 base_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - - platform: android - create_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - base_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - - platform: ios - create_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - base_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - - platform: linux - create_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - base_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - - platform: macos - create_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - base_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - - platform: web - create_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - base_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 - platform: windows create_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 base_revision: 761747bfc538b5af34aa0d3fac380f1bc331ec49 diff --git a/README.md b/README.md index a63ca98..0313fe1 100644 --- a/README.md +++ b/README.md @@ -1,34 +1,21 @@ -
- -

Gyawun Music

-

A Flutter application for streaming music from YouTube Music

- - Latest release - Commits since latest release - Commits per month - Last release - - - - Telergram - - - -
- ---

-

- - - -

+

+

Gyawun Music

+ + Latest release + Commits since latest release + Commits per month + Last release + + Telergram +
## Features / TODO diff --git a/android/app/build.gradle b/android/app/build.gradle index f485bab..07b020c 100644 --- a/android/app/build.gradle +++ b/android/app/build.gradle @@ -29,7 +29,7 @@ if (keystorePropertiesFile.exists()) { } android { - namespace = "com.jhelum.gyawun.beta" + namespace = "com.jhelum.gyawun" compileSdk = flutter.compileSdkVersion ndkVersion = flutter.ndkVersion compileOptions { @@ -39,7 +39,7 @@ android { defaultConfig { // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html). - applicationId = "com.jhelum.gyawun.beta" + applicationId = "com.jhelum.gyawun" // You can update the following values to match your application needs. // For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration. minSdk = flutter.minSdkVersion diff --git a/android/app/src/main/AndroidManifest.xml b/android/app/src/main/AndroidManifest.xml index e7e8162..cbb514f 100644 --- a/android/app/src/main/AndroidManifest.xml +++ b/android/app/src/main/AndroidManifest.xml @@ -14,7 +14,7 @@ { void didUpdateWidget(covariant BrowseScreen oldWidget) { super.didUpdateWidget(oldWidget); if (oldWidget.endpoint['browseId'] != widget.endpoint['browseId']) { - pprint(oldWidget.endpoint); - pprint(widget.endpoint); fetchData(); } } diff --git a/lib/screens/home_screen/chip_screen.dart b/lib/screens/home_screen/chip_screen.dart index fa4c52e..4188c7c 100644 --- a/lib/screens/home_screen/chip_screen.dart +++ b/lib/screens/home_screen/chip_screen.dart @@ -1,7 +1,7 @@ import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../ytmusic/ytmusic.dart'; import 'section_item.dart'; diff --git a/lib/screens/home_screen/home_screen.dart b/lib/screens/home_screen/home_screen.dart index db9ac1e..6ae2f2b 100644 --- a/lib/screens/home_screen/home_screen.dart +++ b/lib/screens/home_screen/home_screen.dart @@ -3,9 +3,9 @@ import 'dart:io'; import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import '../../generated/l10n.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../ytmusic/ytmusic.dart'; import 'section_item.dart'; diff --git a/lib/screens/home_screen/search_screen/search_screen.dart b/lib/screens/home_screen/search_screen/search_screen.dart index 4a4f0cc..3f1ca98 100644 --- a/lib/screens/home_screen/search_screen/search_screen.dart +++ b/lib/screens/home_screen/search_screen/search_screen.dart @@ -4,11 +4,11 @@ import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:flutter_typeahead/flutter_typeahead.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import 'package:hive_flutter/hive_flutter.dart'; import '../../../generated/l10n.dart'; import '../../../services/media_player.dart'; +import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../../utils/bottom_modals.dart'; import '../../../ytmusic/ytmusic.dart'; import '../../browse_screen/browse_screen.dart'; diff --git a/lib/screens/home_screen/section_item.dart b/lib/screens/home_screen/section_item.dart index 6ec2fe5..609435b 100644 --- a/lib/screens/home_screen/section_item.dart +++ b/lib/screens/home_screen/section_item.dart @@ -7,12 +7,12 @@ import 'package:expandable_text/expandable_text.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/services/bottom_message.dart'; -import 'package:gyawun_beta/themes/text_styles.dart'; -import 'package:gyawun_beta/utils/enhanced_image.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../generated/l10n.dart'; +import '../../services/bottom_message.dart'; +import '../../themes/text_styles.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../utils/enhanced_image.dart'; import '../../utils/extensions.dart'; import '../../services/media_player.dart'; import '../../utils/bottom_modals.dart'; diff --git a/lib/screens/main_screen/bottom_player.dart b/lib/screens/main_screen/bottom_player.dart index 084a9f7..5e279ae 100644 --- a/lib/screens/main_screen/bottom_player.dart +++ b/lib/screens/main_screen/bottom_player.dart @@ -5,11 +5,11 @@ import 'package:fluent_ui/fluent_ui.dart' as fluent_ui; import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; -import 'package:gyawun_beta/utils/enhanced_image.dart'; import 'package:provider/provider.dart'; import '../../services/media_player.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../utils/enhanced_image.dart'; class BottomPlayer extends StatelessWidget { const BottomPlayer({super.key}); diff --git a/lib/screens/main_screen/lyrics_box.dart b/lib/screens/main_screen/lyrics_box.dart index 68f92a8..37880b7 100644 --- a/lib/screens/main_screen/lyrics_box.dart +++ b/lib/screens/main_screen/lyrics_box.dart @@ -1,12 +1,12 @@ import 'package:flutter/material.dart'; import 'package:flutter_lyric/lyrics_reader.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/services/media_player.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import 'package:just_audio_background/just_audio_background.dart'; import 'package:provider/provider.dart'; import '../../services/lyrics.dart'; +import '../../services/media_player.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; class LyricsBox extends StatefulWidget { const LyricsBox({required this.currentSong, required this.size, super.key}); diff --git a/lib/screens/main_screen/main_screen.dart b/lib/screens/main_screen/main_screen.dart index 5423b0d..3543b4d 100644 --- a/lib/screens/main_screen/main_screen.dart +++ b/lib/screens/main_screen/main_screen.dart @@ -7,17 +7,17 @@ import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/screens/browse_screen/browse_screen.dart'; -import 'package:gyawun_beta/services/yt_account.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import 'package:receive_sharing_intent/receive_sharing_intent.dart'; import 'package:salomon_bottom_bar/salomon_bottom_bar.dart'; import 'package:window_manager/window_manager.dart'; import '../../generated/l10n.dart'; +import '../../services/yt_account.dart'; import '../../themes/text_styles.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../utils/bottom_modals.dart'; import '../../utils/check_update.dart'; +import '../browse_screen/browse_screen.dart'; import 'bottom_player.dart'; class MainScreen extends StatefulWidget { diff --git a/lib/screens/main_screen/play_button.dart b/lib/screens/main_screen/play_button.dart index b465108..d2d1212 100644 --- a/lib/screens/main_screen/play_button.dart +++ b/lib/screens/main_screen/play_button.dart @@ -1,8 +1,8 @@ import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import '../../services/media_player.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../utils/extensions.dart'; class PlayButton extends StatefulWidget { diff --git a/lib/screens/main_screen/player_screen.dart b/lib/screens/main_screen/player_screen.dart index 572bc68..c47402e 100644 --- a/lib/screens/main_screen/player_screen.dart +++ b/lib/screens/main_screen/player_screen.dart @@ -8,13 +8,8 @@ import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; import 'package:get_it/get_it.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/screens/main_screen/lyrics_box.dart'; -import 'package:gyawun_beta/screens/main_screen/main_screen.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; -import 'package:gyawun_beta/utils/enhanced_image.dart'; -import 'package:gyawun_beta/utils/extensions.dart'; -import 'package:gyawun_beta/ytmusic/ytmusic.dart'; +import 'package:gyawun/screens/main_screen/main_screen.dart'; +import 'package:gyawun/utils/extensions.dart'; import 'package:hive_flutter/hive_flutter.dart'; import 'package:just_audio/just_audio.dart'; import 'package:just_audio_background/just_audio_background.dart'; @@ -24,12 +19,17 @@ import 'package:sliding_up_panel/sliding_up_panel.dart'; import 'package:text_scroll/text_scroll.dart'; import 'package:window_manager/window_manager.dart'; +import '../../generated/l10n.dart'; import '../../services/download_manager.dart'; import '../../services/media_player.dart'; import '../../themes/colors.dart'; import '../../themes/dark.dart'; import '../../themes/text_styles.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../utils/bottom_modals.dart'; +import '../../utils/enhanced_image.dart'; +import '../../ytmusic/ytmusic.dart'; +import 'lyrics_box.dart'; import 'play_button.dart'; import 'queue_list.dart'; diff --git a/lib/screens/main_screen/queue_list.dart b/lib/screens/main_screen/queue_list.dart index 3d74405..0be6fd1 100644 --- a/lib/screens/main_screen/queue_list.dart +++ b/lib/screens/main_screen/queue_list.dart @@ -4,12 +4,12 @@ import 'dart:ui'; import 'package:cached_network_image/cached_network_image.dart'; import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/utils/enhanced_image.dart'; import 'package:just_audio_background/just_audio_background.dart'; import 'package:provider/provider.dart'; +import '../../generated/l10n.dart'; import '../../services/media_player.dart'; +import '../../utils/enhanced_image.dart'; class QueueList extends StatelessWidget { const QueueList({super.key}); diff --git a/lib/screens/saved_screen/download_screen.dart b/lib/screens/saved_screen/download_screen.dart index 2f0ed71..b9c855a 100644 --- a/lib/screens/saved_screen/download_screen.dart +++ b/lib/screens/saved_screen/download_screen.dart @@ -5,13 +5,13 @@ import 'package:expandable_text/expandable_text.dart'; import 'package:flutter/material.dart'; import 'package:flutter_swipe_action_cell/core/cell.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; -import 'package:gyawun_beta/utils/extensions.dart'; +import 'package:gyawun/utils/extensions.dart'; +import '../../generated/l10n.dart'; import '../../services/bottom_message.dart'; import '../../services/download_manager.dart'; import '../../services/media_player.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../utils/bottom_modals.dart'; class DownloadScreen extends StatelessWidget { diff --git a/lib/screens/saved_screen/favourite_details_screen.dart b/lib/screens/saved_screen/favourite_details_screen.dart index 12ada41..bf828ac 100644 --- a/lib/screens/saved_screen/favourite_details_screen.dart +++ b/lib/screens/saved_screen/favourite_details_screen.dart @@ -1,9 +1,9 @@ import 'package:flutter/material.dart'; import 'package:flutter_swipe_action_cell/core/cell.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import 'package:hive_flutter/hive_flutter.dart'; import '../../generated/l10n.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../utils/bottom_modals.dart'; import 'library_tile.dart'; import 'playlist_details_screen.dart'; diff --git a/lib/screens/saved_screen/history_screen.dart b/lib/screens/saved_screen/history_screen.dart index 88cf85e..1470db0 100644 --- a/lib/screens/saved_screen/history_screen.dart +++ b/lib/screens/saved_screen/history_screen.dart @@ -1,9 +1,9 @@ import 'package:flutter/material.dart'; import 'package:flutter_swipe_action_cell/core/cell.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import 'package:hive_flutter/hive_flutter.dart'; import '../../generated/l10n.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../utils/bottom_modals.dart'; import '../home_screen/section_item.dart'; diff --git a/lib/screens/saved_screen/library_tile.dart b/lib/screens/saved_screen/library_tile.dart index eb9bbc9..3a956a8 100644 --- a/lib/screens/saved_screen/library_tile.dart +++ b/lib/screens/saved_screen/library_tile.dart @@ -3,10 +3,10 @@ import 'package:expandable_text/expandable_text.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../generated/l10n.dart'; import '../../services/media_player.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../utils/bottom_modals.dart'; import '../../utils/extensions.dart'; diff --git a/lib/screens/saved_screen/playlist_details_screen.dart b/lib/screens/saved_screen/playlist_details_screen.dart index 636d556..88521e9 100644 --- a/lib/screens/saved_screen/playlist_details_screen.dart +++ b/lib/screens/saved_screen/playlist_details_screen.dart @@ -7,14 +7,14 @@ import 'package:flutter/material.dart'; import 'package:flutter_staggered_grid_view/flutter_staggered_grid_view.dart'; import 'package:flutter_swipe_action_cell/core/cell.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import 'package:provider/provider.dart'; +import '../../generated/l10n.dart'; import '../../services/bottom_message.dart'; import '../../services/library.dart'; import '../../services/media_player.dart'; import '../../themes/colors.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../utils/bottom_modals.dart'; import '../home_screen/section_item.dart'; import '../../utils/extensions.dart'; diff --git a/lib/screens/saved_screen/saved_screen.dart b/lib/screens/saved_screen/saved_screen.dart index acf1fc1..d64e22a 100644 --- a/lib/screens/saved_screen/saved_screen.dart +++ b/lib/screens/saved_screen/saved_screen.dart @@ -6,14 +6,14 @@ import 'package:cached_network_image/cached_network_image.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:flutter_staggered_grid_view/flutter_staggered_grid_view.dart'; -import 'package:gyawun_beta/utils/extensions.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; +import 'package:gyawun/utils/extensions.dart'; import 'package:hive_flutter/hive_flutter.dart'; import 'package:provider/provider.dart'; import '../../generated/l10n.dart'; import '../../services/library.dart'; import '../../themes/colors.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../utils/bottom_modals.dart'; import '../browse_screen/browse_screen.dart'; import 'download_screen.dart'; diff --git a/lib/screens/settings_screen/about/about_screen.dart b/lib/screens/settings_screen/about/about_screen.dart index cd92d12..0f98236 100644 --- a/lib/screens/settings_screen/about/about_screen.dart +++ b/lib/screens/settings_screen/about/about_screen.dart @@ -1,6 +1,5 @@ import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; -import 'package:gyawun_beta/screens/settings_screen/color_icon.dart'; import 'package:url_launcher/url_launcher.dart'; import '../../../app_config.dart'; @@ -8,6 +7,7 @@ import '../../../generated/l10n.dart'; import '../../../themes/colors.dart'; import '../../../themes/text_styles.dart'; import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; +import '../color_icon.dart'; class AboutScreen extends StatelessWidget { const AboutScreen({super.key}); @@ -53,7 +53,7 @@ class AboutScreen extends StatelessWidget { margin: const EdgeInsets.symmetric(vertical: 4), leading: const ColorIcon(icon: Icons.title, color: null), title: Text( - S.of(context).Name, + "Gyawun Music", style: textStyle(context, bold: false) .copyWith(fontSize: 16), ), diff --git a/lib/screens/settings_screen/account/account_screen.dart b/lib/screens/settings_screen/account/account_screen.dart index d7be17b..3756e79 100644 --- a/lib/screens/settings_screen/account/account_screen.dart +++ b/lib/screens/settings_screen/account/account_screen.dart @@ -1,10 +1,10 @@ import 'package:cached_network_image/cached_network_image.dart'; import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/services/yt_account.dart'; -import 'package:gyawun_beta/themes/text_styles.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../../generated/l10n.dart'; +import '../../../services/yt_account.dart'; +import '../../../themes/text_styles.dart'; +import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../color_icon.dart'; class AccountScreen extends StatelessWidget { diff --git a/lib/screens/settings_screen/appearence/appearence_screen.dart b/lib/screens/settings_screen/appearence/appearence_screen.dart index 54c1aa2..216afe8 100644 --- a/lib/screens/settings_screen/appearence/appearence_screen.dart +++ b/lib/screens/settings_screen/appearence/appearence_screen.dart @@ -1,9 +1,9 @@ import 'package:flutter/cupertino.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import '../../../generated/l10n.dart'; import '../../../themes/text_styles.dart'; +import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../color_icon.dart'; import 'appearence_screen_data.dart'; diff --git a/lib/screens/settings_screen/appearence/appearence_screen_data.dart b/lib/screens/settings_screen/appearence/appearence_screen_data.dart index 2ddcff2..9c7db19 100644 --- a/lib/screens/settings_screen/appearence/appearence_screen_data.dart +++ b/lib/screens/settings_screen/appearence/appearence_screen_data.dart @@ -2,14 +2,13 @@ import 'dart:io'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/dropdown_button.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/switch.dart'; -import 'package:gyawun_beta/utils/bottom_modals.dart'; +import '../../../generated/l10n.dart'; +import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; import 'package:provider/provider.dart'; import 'package:fluent_ui/fluent_ui.dart' as fluent_ui; -import '../../../generated/l10n.dart'; import '../../../services/settings_manager.dart'; +import '../../../utils/bottom_modals.dart'; import '../setting_item.dart'; List appearenceScreenData(BuildContext context) => [ diff --git a/lib/screens/settings_screen/backup_restore/backup_restore_screen.dart b/lib/screens/settings_screen/backup_restore/backup_restore_screen.dart index fd24273..a84e27a 100644 --- a/lib/screens/settings_screen/backup_restore/backup_restore_screen.dart +++ b/lib/screens/settings_screen/backup_restore/backup_restore_screen.dart @@ -1,9 +1,9 @@ import 'package:flutter/cupertino.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../../generated/l10n.dart'; import '../../../themes/text_styles.dart'; +import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../color_icon.dart'; import 'backup_restore_screen_data.dart'; diff --git a/lib/screens/settings_screen/backup_restore/backup_restore_screen_data.dart b/lib/screens/settings_screen/backup_restore/backup_restore_screen_data.dart index 0223b35..d2a6b17 100644 --- a/lib/screens/settings_screen/backup_restore/backup_restore_screen_data.dart +++ b/lib/screens/settings_screen/backup_restore/backup_restore_screen_data.dart @@ -4,9 +4,9 @@ import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; import 'package:hive_flutter/hive_flutter.dart'; +import '../../../generated/l10n.dart'; import '../../../services/bottom_message.dart'; import '../../../services/file_storage.dart'; import '../../../services/library.dart'; diff --git a/lib/screens/settings_screen/content/content_screen.dart b/lib/screens/settings_screen/content/content_screen.dart index f54e0bd..6b60fd2 100644 --- a/lib/screens/settings_screen/content/content_screen.dart +++ b/lib/screens/settings_screen/content/content_screen.dart @@ -1,9 +1,9 @@ import 'package:flutter/cupertino.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../../generated/l10n.dart'; import '../../../themes/text_styles.dart'; +import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../color_icon.dart'; import 'content_screen_data.dart'; diff --git a/lib/screens/settings_screen/content/content_screen_data.dart b/lib/screens/settings_screen/content/content_screen_data.dart index d2d3c09..e35f590 100644 --- a/lib/screens/settings_screen/content/content_screen_data.dart +++ b/lib/screens/settings_screen/content/content_screen_data.dart @@ -3,7 +3,6 @@ import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; import 'package:get_it/get_it.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import 'package:hive_flutter/hive_flutter.dart'; import 'package:provider/provider.dart'; @@ -11,6 +10,7 @@ import '../../../generated/l10n.dart'; import '../../../services/bottom_message.dart'; import '../../../services/settings_manager.dart'; import '../../../themes/text_styles.dart'; +import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../../utils/bottom_modals.dart'; import '../../../ytmusic/ytmusic.dart'; import '../setting_item.dart'; diff --git a/lib/screens/settings_screen/playback/audio_and_playback_screen.dart b/lib/screens/settings_screen/playback/audio_and_playback_screen.dart index edc8dbe..6a9296e 100644 --- a/lib/screens/settings_screen/playback/audio_and_playback_screen.dart +++ b/lib/screens/settings_screen/playback/audio_and_playback_screen.dart @@ -1,9 +1,9 @@ import 'package:flutter/cupertino.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import '../../../generated/l10n.dart'; import '../../../themes/text_styles.dart'; +import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../color_icon.dart'; import 'audio_and_playback_screen_data.dart'; diff --git a/lib/screens/settings_screen/playback/audio_and_playback_screen_data.dart b/lib/screens/settings_screen/playback/audio_and_playback_screen_data.dart index 39ca574..6985f3f 100644 --- a/lib/screens/settings_screen/playback/audio_and_playback_screen_data.dart +++ b/lib/screens/settings_screen/playback/audio_and_playback_screen_data.dart @@ -3,16 +3,15 @@ import 'dart:io'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/services/media_player.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/dropdown_button.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/switch.dart'; import 'package:hive_flutter/hive_flutter.dart'; import 'package:provider/provider.dart'; import '../../../generated/l10n.dart'; import '../../../services/bottom_message.dart'; +import '../../../services/media_player.dart'; import '../../../services/settings_manager.dart'; import '../../../themes/text_styles.dart'; +import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../../utils/bottom_modals.dart'; import '../setting_item.dart'; diff --git a/lib/screens/settings_screen/playback/equalizer_screen.dart b/lib/screens/settings_screen/playback/equalizer_screen.dart index 4daba36..628dc0e 100644 --- a/lib/screens/settings_screen/playback/equalizer_screen.dart +++ b/lib/screens/settings_screen/playback/equalizer_screen.dart @@ -1,6 +1,5 @@ import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import 'package:just_audio/just_audio.dart'; import 'package:provider/provider.dart'; @@ -8,6 +7,7 @@ import '../../../generated/l10n.dart'; import '../../../services/media_player.dart'; import '../../../services/settings_manager.dart'; import '../../../themes/text_styles.dart'; +import '../../../utils/adaptive_widgets/adaptive_widgets.dart'; class EqualizerScreen extends StatefulWidget { const EqualizerScreen({super.key}); diff --git a/lib/screens/settings_screen/settings_screen.dart b/lib/screens/settings_screen/settings_screen.dart index 1bdd125..11fe90c 100644 --- a/lib/screens/settings_screen/settings_screen.dart +++ b/lib/screens/settings_screen/settings_screen.dart @@ -3,8 +3,6 @@ import 'dart:io'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; -import 'package:gyawun_beta/utils/bottom_modals.dart'; import 'package:permission_handler/permission_handler.dart'; import 'package:url_launcher/url_launcher.dart'; import 'package:fluent_ui/fluent_ui.dart' as fluent_ui; @@ -12,6 +10,8 @@ import 'package:fluent_ui/fluent_ui.dart' as fluent_ui; import '../../generated/l10n.dart'; import '../../themes/colors.dart'; import '../../themes/text_styles.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../utils/bottom_modals.dart'; import 'color_icon.dart'; import 'setting_screen_data.dart'; diff --git a/lib/screens/ytmusic_screen/albums_screen.dart b/lib/screens/ytmusic_screen/albums_screen.dart index 3da0c72..2e8e79c 100644 --- a/lib/screens/ytmusic_screen/albums_screen.dart +++ b/lib/screens/ytmusic_screen/albums_screen.dart @@ -1,9 +1,9 @@ import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/song_tile.dart'; import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../ytmusic/ytmusic.dart'; +import 'song_tile.dart'; class AlbumsScreen extends StatefulWidget { const AlbumsScreen({super.key}); diff --git a/lib/screens/ytmusic_screen/artists_screen.dart b/lib/screens/ytmusic_screen/artists_screen.dart index 670ee2c..89df8cb 100644 --- a/lib/screens/ytmusic_screen/artists_screen.dart +++ b/lib/screens/ytmusic_screen/artists_screen.dart @@ -1,9 +1,9 @@ import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/song_tile.dart'; import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../ytmusic/ytmusic.dart'; +import 'song_tile.dart'; class ArtistsScreen extends StatefulWidget { const ArtistsScreen({super.key}); diff --git a/lib/screens/ytmusic_screen/playlists_screen.dart b/lib/screens/ytmusic_screen/playlists_screen.dart index 921b3e5..9280530 100644 --- a/lib/screens/ytmusic_screen/playlists_screen.dart +++ b/lib/screens/ytmusic_screen/playlists_screen.dart @@ -1,8 +1,8 @@ import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/song_tile.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; -import 'package:gyawun_beta/ytmusic/ytmusic.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../ytmusic/ytmusic.dart'; +import 'song_tile.dart'; class PlaylistsScreen extends StatefulWidget { const PlaylistsScreen({super.key}); diff --git a/lib/screens/ytmusic_screen/songs_screen.dart b/lib/screens/ytmusic_screen/songs_screen.dart index 8f1e715..ec84d65 100644 --- a/lib/screens/ytmusic_screen/songs_screen.dart +++ b/lib/screens/ytmusic_screen/songs_screen.dart @@ -1,8 +1,8 @@ import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/song_tile.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; -import 'package:gyawun_beta/ytmusic/ytmusic.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../ytmusic/ytmusic.dart'; +import 'song_tile.dart'; class SongsScreen extends StatefulWidget { const SongsScreen({super.key}); diff --git a/lib/screens/ytmusic_screen/subscriptions_screen.dart b/lib/screens/ytmusic_screen/subscriptions_screen.dart index 82f4335..eb82023 100644 --- a/lib/screens/ytmusic_screen/subscriptions_screen.dart +++ b/lib/screens/ytmusic_screen/subscriptions_screen.dart @@ -1,6 +1,6 @@ import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/song_tile.dart'; +import 'song_tile.dart'; import '../../utils/adaptive_widgets/adaptive_widgets.dart'; import '../../ytmusic/ytmusic.dart'; diff --git a/lib/screens/ytmusic_screen/youtube_history.dart b/lib/screens/ytmusic_screen/youtube_history.dart index ff28f03..a6b2ba4 100644 --- a/lib/screens/ytmusic_screen/youtube_history.dart +++ b/lib/screens/ytmusic_screen/youtube_history.dart @@ -2,12 +2,13 @@ import 'package:cached_network_image/cached_network_image.dart'; import 'package:flutter/material.dart'; import 'package:flutter_swipe_action_cell/core/cell.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/services/media_player.dart'; -import 'package:gyawun_beta/themes/text_styles.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; -import 'package:gyawun_beta/utils/bottom_modals.dart'; -import 'package:gyawun_beta/ytmusic/ytmusic.dart'; + +import '../../generated/l10n.dart'; +import '../../services/media_player.dart'; +import '../../themes/text_styles.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../utils/bottom_modals.dart'; +import '../../ytmusic/ytmusic.dart'; class YoutubeHistory extends StatefulWidget { const YoutubeHistory({super.key}); diff --git a/lib/screens/ytmusic_screen/ytmusic_screen.dart b/lib/screens/ytmusic_screen/ytmusic_screen.dart index 381b9a6..fc5c0a9 100644 --- a/lib/screens/ytmusic_screen/ytmusic_screen.dart +++ b/lib/screens/ytmusic_screen/ytmusic_screen.dart @@ -1,12 +1,12 @@ import 'package:flutter/material.dart'; -import 'package:gyawun_beta/generated/l10n.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/albums_screen.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/artists_screen.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/playlists_screen.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/songs_screen.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/subscriptions_screen.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; +import '../../generated/l10n.dart'; +import '../../utils/adaptive_widgets/adaptive_widgets.dart'; +import 'albums_screen.dart'; +import 'artists_screen.dart'; +import 'playlists_screen.dart'; +import 'songs_screen.dart'; +import 'subscriptions_screen.dart'; import 'youtube_history.dart'; class YTMScreen extends StatefulWidget { diff --git a/lib/services/bottom_message.dart b/lib/services/bottom_message.dart index 395d12f..601522f 100644 --- a/lib/services/bottom_message.dart +++ b/lib/services/bottom_message.dart @@ -1,7 +1,8 @@ import 'package:fl_toast/fl_toast.dart'; import 'package:flutter/material.dart'; -import 'package:gyawun_beta/themes/text_styles.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; + +import '../themes/text_styles.dart'; +import '../utils/adaptive_widgets/theme.dart'; class BottomMessage { static showText(BuildContext context, String text, diff --git a/lib/services/file_storage.dart b/lib/services/file_storage.dart index 830553f..f94feb6 100644 --- a/lib/services/file_storage.dart +++ b/lib/services/file_storage.dart @@ -5,7 +5,6 @@ import 'package:file_picker/file_picker.dart'; import 'package:flutter/cupertino.dart'; import 'package:flutter/material.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/utils/enhanced_image.dart'; import 'package:hive_flutter/hive_flutter.dart'; import 'package:http/http.dart'; import 'package:intl/intl.dart'; @@ -13,6 +12,7 @@ import 'package:path_provider/path_provider.dart'; import 'package:permission_handler/permission_handler.dart'; import 'package:path/path.dart' as path; +import '../utils/enhanced_image.dart'; import '../utils/pprint.dart'; import '../ytmusic/ytmusic.dart'; import 'library.dart'; diff --git a/lib/services/library.dart b/lib/services/library.dart index 865778b..c7c3aa7 100644 --- a/lib/services/library.dart +++ b/lib/services/library.dart @@ -1,8 +1,9 @@ import 'package:flutter/cupertino.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/ytmusic/ytmusic.dart'; import 'package:hive_flutter/hive_flutter.dart'; +import '../ytmusic/ytmusic.dart'; + class LibraryService extends ChangeNotifier { final Box _box = Hive.box('LIBRARY'); late Map _playlists; diff --git a/lib/services/media_player.dart b/lib/services/media_player.dart index 2c62f52..2764e4a 100644 --- a/lib/services/media_player.dart +++ b/lib/services/media_player.dart @@ -6,12 +6,12 @@ import 'package:flutter/foundation.dart'; import 'package:flutter/material.dart'; import 'package:flutter/widgets.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/services/custom_audio_stream.dart'; import 'package:just_audio/just_audio.dart'; import 'package:just_audio_background/just_audio_background.dart'; import '../utils/add_history.dart'; import '../ytmusic/ytmusic.dart'; +import 'custom_audio_stream.dart'; import 'settings_manager.dart'; class MediaPlayer extends ChangeNotifier { diff --git a/lib/services/yt_account.dart b/lib/services/yt_account.dart index 1af7fd7..8d7b824 100644 --- a/lib/services/yt_account.dart +++ b/lib/services/yt_account.dart @@ -1,9 +1,9 @@ import 'package:flutter/material.dart'; import 'package:flutter/widgets.dart'; import 'package:get_it/get_it.dart'; -import 'package:gyawun_beta/ytmusic/ytmusic.dart'; import '../ytmusic/modals/user.dart'; +import '../ytmusic/ytmusic.dart'; class YTAccount { ValueNotifier isLogged = GetIt.I().isLogged; diff --git a/lib/utils/adaptive_widgets/buttons.dart b/lib/utils/adaptive_widgets/buttons.dart index 3e5ffd6..41541e5 100644 --- a/lib/utils/adaptive_widgets/buttons.dart +++ b/lib/utils/adaptive_widgets/buttons.dart @@ -2,7 +2,8 @@ import 'dart:io'; import 'package:fluent_ui/fluent_ui.dart' as fluent_ui; import 'package:flutter/material.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; + +import 'icons.dart'; class AdaptiveButton extends fluent_ui.StatelessWidget { final Widget child; diff --git a/lib/utils/adaptive_widgets/listtile.dart b/lib/utils/adaptive_widgets/listtile.dart index 3e40807..b8263c7 100644 --- a/lib/utils/adaptive_widgets/listtile.dart +++ b/lib/utils/adaptive_widgets/listtile.dart @@ -1,8 +1,8 @@ import 'dart:io'; import 'package:flutter/material.dart'; -import 'package:gyawun_beta/themes/text_styles.dart'; +import '../../themes/text_styles.dart'; import 'no_splash_factory.dart'; class AdaptiveListTile extends StatelessWidget { diff --git a/lib/utils/bottom_modals.dart b/lib/utils/bottom_modals.dart index 503966c..3886b9d 100644 --- a/lib/utils/bottom_modals.dart +++ b/lib/utils/bottom_modals.dart @@ -9,9 +9,6 @@ import 'package:flutter_markdown/flutter_markdown.dart'; import 'package:flutter_staggered_grid_view/flutter_staggered_grid_view.dart'; import 'package:get_it/get_it.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/services/settings_manager.dart'; -import 'package:gyawun_beta/themes/text_styles.dart'; -import 'package:gyawun_beta/utils/adaptive_widgets/adaptive_widgets.dart'; import 'package:hive_flutter/hive_flutter.dart'; import 'package:intl/intl.dart'; import 'package:provider/provider.dart'; @@ -26,7 +23,10 @@ import '../services/bottom_message.dart'; import '../services/download_manager.dart'; import '../services/library.dart'; import '../services/media_player.dart'; +import '../services/settings_manager.dart'; import '../themes/colors.dart'; +import '../themes/text_styles.dart'; +import 'adaptive_widgets/adaptive_widgets.dart'; import 'check_update.dart'; import 'format_duration.dart'; import '../utils/extensions.dart'; diff --git a/lib/utils/check_update.dart b/lib/utils/check_update.dart index d579744..7700f93 100644 --- a/lib/utils/check_update.dart +++ b/lib/utils/check_update.dart @@ -10,12 +10,14 @@ import '../app_config.dart'; Future checkUpdate({BaseDeviceInfo? deviceInfo}) async { final response = await http.get(appConfig.updateUri, headers: {'Accept': 'application/vnd.github+json'}); - List updates = jsonDecode(response.body); - Map update = updates.firstWhere((element) => element['prerelease'] == true); + Map update = jsonDecode(response.body); Version currentVersion = Version.parse(appConfig.codeName); + Version remoteVersion = Version.parse(update['tag_name'].toString().replaceAll('v', '')); + int comparison = remoteVersion.compareTo(currentVersion); + if (comparison > 0) { if (deviceInfo == null) { final deviceInfoPlugin = DeviceInfoPlugin(); diff --git a/lib/utils/router.dart b/lib/utils/router.dart index cff820f..5af4b53 100644 --- a/lib/utils/router.dart +++ b/lib/utils/router.dart @@ -4,9 +4,6 @@ import 'package:fluent_ui/fluent_ui.dart'; import 'package:flutter/cupertino.dart'; import 'package:get_it/get_it.dart'; import 'package:go_router/go_router.dart'; -import 'package:gyawun_beta/screens/settings_screen/account/account_screen.dart'; -import 'package:gyawun_beta/screens/ytmusic_screen/ytmusic_screen.dart'; -import 'package:gyawun_beta/services/yt_account.dart'; import '../screens/home_screen/chip_screen.dart'; import '../screens/home_screen/home_screen.dart'; @@ -16,12 +13,15 @@ import '../screens/main_screen/main_screen.dart'; import '../screens/main_screen/player_screen.dart'; import '../screens/browse_screen/browse_screen.dart'; import '../screens/settings_screen/about/about_screen.dart'; +import '../screens/settings_screen/account/account_screen.dart'; import '../screens/settings_screen/appearence/appearence_screen.dart'; import '../screens/settings_screen/backup_restore/backup_restore_screen.dart'; import '../screens/settings_screen/content/content_screen.dart'; import '../screens/settings_screen/playback/audio_and_playback_screen.dart'; import '../screens/settings_screen/playback/equalizer_screen.dart'; import '../screens/settings_screen/settings_screen.dart'; +import '../screens/ytmusic_screen/ytmusic_screen.dart'; +import '../services/yt_account.dart'; GoRouter router = GoRouter( initialLocation: '/', diff --git a/lib/ytmusic/auth/auth.dart b/lib/ytmusic/auth/auth.dart index 4785bea..59d0b9e 100644 --- a/lib/ytmusic/auth/auth.dart +++ b/lib/ytmusic/auth/auth.dart @@ -2,11 +2,11 @@ import 'dart:convert'; import 'package:flutter/material.dart'; -import 'package:gyawun_beta/utils/bottom_modals.dart'; import 'package:hive_flutter/hive_flutter.dart'; import 'package:http/http.dart' as http; import 'package:url_launcher/url_launcher.dart'; +import '../../utils/bottom_modals.dart'; import '../helpers.dart'; const USER_AGENT = diff --git a/lib/ytmusic/mixins/library.dart b/lib/ytmusic/mixins/library.dart index 4b6ed22..760a0b9 100644 --- a/lib/ytmusic/mixins/library.dart +++ b/lib/ytmusic/mixins/library.dart @@ -1,4 +1,4 @@ -import 'package:gyawun_beta/ytmusic/helpers.dart'; +import '../helpers.dart'; import '../yt_service_provider.dart'; import 'utils.dart'; diff --git a/lib/ytmusic/mixins/user.dart b/lib/ytmusic/mixins/user.dart index 0861419..422270c 100644 --- a/lib/ytmusic/mixins/user.dart +++ b/lib/ytmusic/mixins/user.dart @@ -1,5 +1,4 @@ -import 'package:gyawun_beta/ytmusic/helpers.dart'; - +import '../helpers.dart'; import '../modals/user.dart'; import '../yt_service_provider.dart'; diff --git a/lib/ytmusic/ytmusic.dart b/lib/ytmusic/ytmusic.dart index e55e159..848ab07 100644 --- a/lib/ytmusic/ytmusic.dart +++ b/lib/ytmusic/ytmusic.dart @@ -1,7 +1,7 @@ library ytmusic; -import 'package:gyawun_beta/ytmusic/mixins/library.dart'; import 'mixins/browsing.dart'; +import 'mixins/library.dart'; import 'mixins/search.dart'; import 'mixins/user.dart'; import 'yt_service_provider.dart'; diff --git a/pubspec.yaml b/pubspec.yaml index 4da8a1b..c57d34b 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,7 +1,7 @@ -name: gyawun_beta +name: gyawun description: "A new Flutter project." publish_to: 'none' -version: 2.0.0-beta-4+24 +version: 2.0.0+25 environment: sdk: '>=3.4.1 <4.0.0' diff --git a/test/widget_test.dart b/test/widget_test.dart index 176b64c..2885bf0 100644 --- a/test/widget_test.dart +++ b/test/widget_test.dart @@ -8,7 +8,7 @@ import 'package:flutter/material.dart'; import 'package:flutter_test/flutter_test.dart'; -import 'package:gyawun_beta/main.dart'; +import 'package:gyawun/main.dart'; void main() { testWidgets('Counter increments smoke test', (WidgetTester tester) async {