diff --git a/lib/controllers/playlistController.dart b/lib/controllers/playlistController.dart index f12ddd42..9263f943 100644 --- a/lib/controllers/playlistController.dart +++ b/lib/controllers/playlistController.dart @@ -33,14 +33,14 @@ class PlaylistController extends GetxController { Future removeVideoFromPlayList(VideoInList v) async { await service.deleteUserPlaylistVideo(playlist.playlistId, v.indexId ?? ''); PlaylistListController.to(tag: PlaylistListController.getTag(userPlayListTag))?.refreshPlaylists(); - + playlist.videos.remove(v); update(); return false; } - play(){ - MiniPlayerController.to()?.playVideo(playlist.videos, goBack: false); + play() { + MiniPlayerController.to()?.playVideo(playlist.videos, goBack: false); } getAllVideos() async { diff --git a/lib/main.dart b/lib/main.dart index 2e663ada..01093fb4 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -198,7 +198,6 @@ class _HomeState extends State with AfterLayoutMixin { IconButton( onPressed: () => openSettings(context), icon: const Icon(Icons.settings), - color: colorScheme.secondary, ), ], ), diff --git a/lib/views/components/videoAddToPlaylistButton.dart b/lib/views/components/videoAddToPlaylistButton.dart index 0bfebeb6..a7c932c2 100644 --- a/lib/views/components/videoAddToPlaylistButton.dart +++ b/lib/views/components/videoAddToPlaylistButton.dart @@ -24,7 +24,6 @@ class VideoAddToPlaylistButton extends StatelessWidget { onPressed: () => AddToPlaylist.showAddToPlaylistDialog(context, _.videoId!), icon: Icon( Icons.add, - color: colors.secondary, ), ), _.playListCount > 0 @@ -33,7 +32,7 @@ class VideoAddToPlaylistButton extends StatelessWidget { right: 10, child: Text( _.playListCount.toString(), - style: TextStyle(color: colors.secondary, fontSize: 8), + style: const TextStyle(fontSize: 8), ), ) : const SizedBox.shrink() diff --git a/lib/views/components/videoLikeButton.dart b/lib/views/components/videoLikeButton.dart index bfb0d73e..209631c4 100644 --- a/lib/views/components/videoLikeButton.dart +++ b/lib/views/components/videoLikeButton.dart @@ -22,7 +22,6 @@ class VideoLikeButton extends StatelessWidget { iconSize: size, onPressed: _.toggleLike, icon: _.isVideoLiked ? const Icon(Icons.favorite) : const Icon(Icons.favorite_border), - color: colors.secondary, ), ), ); diff --git a/lib/views/settings.dart b/lib/views/settings.dart index 4fa8409d..3fe37a9d 100644 --- a/lib/views/settings.dart +++ b/lib/views/settings.dart @@ -26,11 +26,11 @@ class Settings extends StatelessWidget { const Settings({super.key}); manageServers(BuildContext context) { - navigatorKey.currentState?.push( MaterialPageRoute(settings: ROUTE_SETTINGS_MANAGE_SERVERS, builder: (context) => const ManageServers())); + navigatorKey.currentState?.push(MaterialPageRoute(settings: ROUTE_SETTINGS_MANAGE_SERVERS, builder: (context) => const ManageServers())); } openSponsorBlockSettings(BuildContext context) { - Navigator.push(context, MaterialPageRoute(settings: ROUTE_SETTINGS_SPONSOR_BLOCK, builder: (context) => const SponsorBlockSettings())); + navigatorKey.currentState?.push(MaterialPageRoute(settings: ROUTE_SETTINGS_SPONSOR_BLOCK, builder: (context) => const SponsorBlockSettings())); } searchCountry(BuildContext context, SettingsController controller) { @@ -116,16 +116,16 @@ class Settings extends StatelessWidget { title: Text(locals.useDash), description: Text(locals.useDashDescription), ), - SettingsTile.switchTile( initialValue: _.useProxy, onToggle: _.toggleProxy, title: Text(locals.useProxy), - description: Text(locals.useProxyDescription), - ), - SettingsTile.navigation( - title: Text('SponsorBlock'), - description: Text(locals.sponsorBlockDescription),onPressed: openSponsorBlockSettings, + description: Text(locals.useProxyDescription), + ), + SettingsTile.navigation( + title: Text('SponsorBlock'), + description: Text(locals.sponsorBlockDescription), + onPressed: openSponsorBlockSettings, ) ]), SettingsSection( diff --git a/lib/views/settings/sponsorBlockSettings.dart b/lib/views/settings/sponsorBlockSettings.dart index 1c191f4d..18de35d0 100644 --- a/lib/views/settings/sponsorBlockSettings.dart +++ b/lib/views/settings/sponsorBlockSettings.dart @@ -21,29 +21,27 @@ class SponsorBlockSettings extends StatelessWidget { init: SponsorBlockSettingsController(), global: false, builder: (_) { - return MiniPlayerAware( - child: Scaffold( - appBar: AppBar( - scrolledUnderElevation: 0, - title: const Text('SponsorBlock'), - ), - backgroundColor: colorScheme.background, - body: SafeArea( - bottom: false, - child: SettingsList(lightTheme: theme, darkTheme: theme, sections: [ - SettingsSection( - title: Text(locals.sponsorBlockSettingsQuickDescription), - tiles: SponsorSegmentType.values - .map((t) => SettingsTile.switchTile( - initialValue: _.value(t), - onToggle: (bool value) => _.setValue(t, value), - title: Text(SponsorSegmentType.getLabel(t, locals)), - description: Text(SponsorSegmentType.getDescription(t, locals)), - )) - .toList()), - ]), - )), - ); + return Scaffold( + appBar: AppBar( + scrolledUnderElevation: 0, + title: const Text('SponsorBlock'), + ), + backgroundColor: colorScheme.background, + body: SafeArea( + bottom: false, + child: SettingsList(lightTheme: theme, darkTheme: theme, sections: [ + SettingsSection( + title: Text(locals.sponsorBlockSettingsQuickDescription), + tiles: SponsorSegmentType.values + .map((t) => SettingsTile.switchTile( + initialValue: _.value(t), + onToggle: (bool value) => _.setValue(t, value), + title: Text(SponsorSegmentType.getLabel(t, locals)), + description: Text(SponsorSegmentType.getDescription(t, locals)), + )) + .toList()), + ]), + )); }, ); } diff --git a/lib/views/video.dart b/lib/views/video.dart index 0b8ab281..63883989 100644 --- a/lib/views/video.dart +++ b/lib/views/video.dart @@ -53,7 +53,6 @@ class VideoView extends StatelessWidget { child: IconButton( onPressed: () => showSharingSheet(context, _.video!), icon: const Icon(Icons.share), - color: colorScheme.secondary, ), ), VideoLikeButton(videoId: _.video?.videoId), diff --git a/lib/views/videoPlayer/miniPlayerControls.dart b/lib/views/videoPlayer/miniPlayerControls.dart index 4590fe3a..1c47636d 100644 --- a/lib/views/videoPlayer/miniPlayerControls.dart +++ b/lib/views/videoPlayer/miniPlayerControls.dart @@ -28,7 +28,7 @@ class MiniPlayerControls extends StatelessWidget { builder: (_) => Stack( alignment: Alignment.center, children: [ - Positioned(left: 0, child: VideoLikeButton(videoId: videoId, style: buttonStyle)), + // Positioned(left: 0, child: VideoLikeButton(videoId: videoId, style: buttonStyle)), Row( mainAxisAlignment: MainAxisAlignment.center, children: [ diff --git a/lib/views/welcomeWizard.dart b/lib/views/welcomeWizard.dart index b0f6870f..d01e684c 100644 --- a/lib/views/welcomeWizard.dart +++ b/lib/views/welcomeWizard.dart @@ -42,7 +42,7 @@ class WelcomeWizard extends StatelessWidget { child: FilledButton.tonal( onPressed: _.selected != null ? () { - navigatorKey.currentState?.pushReplacement(MaterialPageRoute( + navigatorKey.currentState?.push(MaterialPageRoute( builder: (context) => const Home(), )); }