v1.1.5+35
- overlay buttons - encrypted storage - downloadbutton (wip)
This commit is contained in:
parent
43c42ac0d5
commit
1cd10b3809
@ -34,7 +34,11 @@ class ThemeNotifier extends StateNotifier<ThemeData> {
|
|||||||
final themeNotifierProvider = StateNotifierProvider<ThemeNotifier, ThemeData>((
|
final themeNotifierProvider = StateNotifierProvider<ThemeNotifier, ThemeData>((
|
||||||
ref,
|
ref,
|
||||||
) {
|
) {
|
||||||
return ThemeNotifier(secureStorage: FlutterSecureStorage());
|
return ThemeNotifier(
|
||||||
|
secureStorage: FlutterSecureStorage(
|
||||||
|
aOptions: AndroidOptions(encryptedSharedPreferences: true),
|
||||||
|
),
|
||||||
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
class CustomTheme {
|
class CustomTheme {
|
||||||
|
@ -106,9 +106,9 @@ class _DetailViewState extends ConsumerState<DetailView> {
|
|||||||
title: Text('f0ck #${mediaState.mediaItems[_currentIndex].id}'),
|
title: Text('f0ck #${mediaState.mediaItems[_currentIndex].id}'),
|
||||||
actions: [
|
actions: [
|
||||||
IconButton(
|
IconButton(
|
||||||
icon: Icon(mediaState.muted ? Icons.volume_off : Icons.volume_up),
|
icon: Icon(Icons.download),
|
||||||
onPressed: () {
|
onPressed: () {
|
||||||
mediaNotifier.toggleMute();
|
// wip
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
PopupMenuButton<String>(
|
PopupMenuButton<String>(
|
||||||
|
@ -1,8 +1,11 @@
|
|||||||
import 'package:flutter/material.dart';
|
import 'package:flutter/material.dart';
|
||||||
|
|
||||||
|
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||||
import 'package:cached_video_player_plus/cached_video_player_plus.dart';
|
import 'package:cached_video_player_plus/cached_video_player_plus.dart';
|
||||||
|
|
||||||
class VideoControlsOverlay extends StatelessWidget {
|
import 'package:f0ckapp/providers/MediaProvider.dart';
|
||||||
|
|
||||||
|
class VideoControlsOverlay extends ConsumerWidget {
|
||||||
final CachedVideoPlayerPlusController controller;
|
final CachedVideoPlayerPlusController controller;
|
||||||
final VoidCallback button;
|
final VoidCallback button;
|
||||||
|
|
||||||
@ -13,10 +16,32 @@ class VideoControlsOverlay extends StatelessWidget {
|
|||||||
});
|
});
|
||||||
|
|
||||||
@override
|
@override
|
||||||
Widget build(BuildContext context) {
|
Widget build(BuildContext context, ref) {
|
||||||
|
final mediaState = ref.watch(mediaProvider);
|
||||||
|
final mediaNotifier = ref.read(mediaProvider.notifier);
|
||||||
|
|
||||||
return Stack(
|
return Stack(
|
||||||
alignment: Alignment.center,
|
alignment: Alignment.center,
|
||||||
children: [
|
children: [
|
||||||
|
Positioned(
|
||||||
|
right: 12,
|
||||||
|
top: 12,
|
||||||
|
child: _ControlButton(
|
||||||
|
mediaState.muted ? Icons.volume_off : Icons.volume_up,
|
||||||
|
() {
|
||||||
|
button();
|
||||||
|
mediaNotifier.toggleMute();
|
||||||
|
},
|
||||||
|
size: 16,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
Positioned(
|
||||||
|
right: 12,
|
||||||
|
bottom: 12,
|
||||||
|
child: _ControlButton(Icons.fullscreen, () {
|
||||||
|
button();
|
||||||
|
}, size: 16),
|
||||||
|
),
|
||||||
Center(
|
Center(
|
||||||
child: Row(
|
child: Row(
|
||||||
mainAxisAlignment: MainAxisAlignment.center,
|
mainAxisAlignment: MainAxisAlignment.center,
|
||||||
|
@ -16,7 +16,7 @@ publish_to: 'none' # Remove this line if you wish to publish to pub.dev
|
|||||||
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
|
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
|
||||||
# In Windows, build-name is used as the major, minor, and patch parts
|
# In Windows, build-name is used as the major, minor, and patch parts
|
||||||
# of the product and file versions while build-number is used as the build suffix.
|
# of the product and file versions while build-number is used as the build suffix.
|
||||||
version: 1.1.4+34
|
version: 1.1.5+35
|
||||||
|
|
||||||
environment:
|
environment:
|
||||||
sdk: ^3.9.0-100.2.beta
|
sdk: ^3.9.0-100.2.beta
|
||||||
|
Loading…
x
Reference in New Issue
Block a user