Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
1855549ccb | ||
|
|
26ff55e005 | ||
|
|
6916b386eb | ||
|
|
1860a1cea6 | ||
|
|
7802beb41b | ||
|
|
4eb55885f7 | ||
|
|
03fc1c1109 | ||
|
|
d709d638c7 | ||
|
|
7f8d4c7946 | ||
|
|
1536feb034 | ||
|
|
83c0cce7f3 | ||
|
|
389a4dcc25 | ||
|
|
0aee098d46 | ||
|
|
3289ce0fbc | ||
|
|
8ef0d2e25c | ||
|
|
c4a51e0fb9 | ||
|
|
9819c4f495 | ||
|
|
1ebc2a85d1 | ||
|
|
0159c18497 | ||
|
|
0b1b18fd35 | ||
|
|
4dc7101f39 | ||
|
|
3bfc24bf9b | ||
|
|
d307f8c99d | ||
|
|
ec054fce46 | ||
|
|
b25df3b411 | ||
|
|
57bdb3997e | ||
|
|
6647cf25b0 | ||
|
|
1e6a1af1cf | ||
|
|
637a3e9e37 | ||
|
|
ad4b23b18b | ||
|
|
582809427e | ||
|
|
df09d2249d | ||
|
|
c2cca423d7 | ||
|
|
0ba2ecd90a | ||
|
|
60ef83bd3a | ||
|
|
89c7b79867 | ||
|
|
bfe7d54dcf | ||
|
|
d9bfb73146 | ||
|
|
fc2aa53197 | ||
|
|
9bf9a6f23b | ||
|
|
9e7c66f66a | ||
|
|
63d711ae43 | ||
|
|
7c651eb61f | ||
|
|
3bba440e18 | ||
|
|
1f44ac6050 | ||
|
|
8d5b5d2e0c | ||
|
|
aae1b1c45c | ||
|
|
b74cacd660 | ||
|
|
1fc0d0458b | ||
|
|
64c0c9979b | ||
|
|
b419ff5507 | ||
|
|
f508013aa5 | ||
|
|
756eb8d6f0 | ||
|
|
83e04b64da | ||
|
|
408bf8577d | ||
|
|
90e8223c74 | ||
|
|
b1377ea4a1 | ||
|
|
348aa69a50 | ||
|
|
1913d49117 | ||
|
|
2bc2c0a0ec | ||
|
|
544fccf82d | ||
|
|
71bfd3ca2f | ||
|
|
f2f7bb3508 | ||
|
|
c98add8065 | ||
|
|
56b7cb842e | ||
|
|
223a5d2219 | ||
|
|
66611b9bc3 | ||
|
|
35f56c8a80 | ||
|
|
653eee1453 | ||
|
|
29f5dc00c4 | ||
|
|
9d04833b3e | ||
|
|
a55b255d05 |
@@ -0,0 +1,19 @@
|
||||
.git
|
||||
build/
|
||||
.dart_tool/
|
||||
.idea/
|
||||
*.tar.gz
|
||||
nul
|
||||
libmpv-prefix/
|
||||
steamfiles/
|
||||
pubspec_overrides.yaml
|
||||
|
||||
# Flutter ephemeral / generated plugin symlinks
|
||||
linux/flutter/ephemeral/
|
||||
windows/flutter/
|
||||
macos/Flutter/
|
||||
ios/Flutter/
|
||||
android/.gradle/
|
||||
android/app/build/
|
||||
.flutter-plugins
|
||||
.flutter-plugins-dependencies
|
||||
@@ -0,0 +1,3 @@
|
||||
*.sh text eol=lf
|
||||
*.Dockerfile text eol=lf
|
||||
Dockerfile text eol=lf
|
||||
@@ -429,13 +429,13 @@ jobs:
|
||||
- name: Cache APT packages
|
||||
uses: awalsh128/cache-apt-pkgs-action@latest
|
||||
with:
|
||||
packages: clang cmake meson ninja-build pkg-config nasm libgtk-3-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick
|
||||
packages: clang cmake meson ninja-build pkg-config nasm libgtk-3-dev libevdev-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick
|
||||
version: 1.1
|
||||
|
||||
- name: Install Linux dependencies
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y clang cmake meson ninja-build pkg-config nasm libgtk-3-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick
|
||||
sudo apt-get install -y clang cmake meson ninja-build pkg-config nasm libgtk-3-dev libevdev-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick
|
||||
|
||||
- name: Cache libmpv build
|
||||
id: libmpv-cache
|
||||
@@ -537,13 +537,13 @@ jobs:
|
||||
- name: Cache APT packages
|
||||
uses: awalsh128/cache-apt-pkgs-action@latest
|
||||
with:
|
||||
packages: clang cmake meson ninja-build pkg-config nasm libgtk-3-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick
|
||||
packages: clang cmake meson ninja-build pkg-config nasm libgtk-3-dev libevdev-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick
|
||||
version: 1.1
|
||||
|
||||
- name: Install Linux dependencies
|
||||
run: |
|
||||
sudo apt-get update
|
||||
sudo apt-get install -y clang cmake meson ninja-build pkg-config nasm libgtk-3-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick
|
||||
sudo apt-get install -y clang cmake meson ninja-build pkg-config nasm libgtk-3-dev libevdev-dev liblzma-dev libstdc++-12-dev libasound2-dev libass-dev libfreetype-dev libfontconfig-dev libfribidi-dev libharfbuzz-dev libepoxy-dev libegl-dev libgl-dev libgnutls28-dev libpipewire-0.3-dev libva-dev libvdpau-dev libx11-dev libxext-dev libxrandr-dev libxcursor-dev libxi-dev libxss-dev libxpresent-dev libxkbcommon-dev libpulse-dev libdbus-1-dev libdrm-dev libgbm-dev libwayland-dev wayland-protocols liblcms2-dev ruby ruby-dev rubygems build-essential rpm libarchive-tools imagemagick
|
||||
|
||||
- name: Cache libmpv build
|
||||
id: libmpv-cache
|
||||
|
||||
+2
-2
@@ -1,6 +1,6 @@
|
||||
cask "plezy" do
|
||||
version "1.16.1"
|
||||
sha256 "56a079818bec9d332a2dc9a16d54b20cb477f5d8f104c1870fc1e936acf78d36"
|
||||
version "1.18.2"
|
||||
sha256 "83739e8c298e19eefc1e54b1c3d054da99ad03874dbf07e069fcad0f5f264fb6"
|
||||
|
||||
url "https://github.com/edde746/plezy/releases/download/#{version}/plezy-macos.dmg"
|
||||
name "Plezy"
|
||||
|
||||
@@ -13,15 +13,13 @@ A modern Plex client for desktop and mobile. Built with Flutter for native perfo
|
||||
|
||||
## Download
|
||||
|
||||
### Mobile
|
||||
<a href='https://apps.apple.com/us/app/id6754315964'><img height='60' alt='Download on the App Store' src='./assets/app-store-badge.png'/></a>
|
||||
<a href='https://play.google.com/store/apps/details?id=com.edde746.plezy'><img height='60' alt='Get it on Google Play' src='./assets/play-store-badge.png'/></a>
|
||||
<a href='https://www.amazon.com/gp/product/B0GK65CVS1'><img height='60' alt='Available at the Amazon App Store' src='./assets/amazon-badge.png'/></a>
|
||||
|
||||
### Desktop
|
||||
- [Windows (Universal)](https://github.com/edde746/plezy/releases/latest/download/plezy-windows-installer.exe)
|
||||
- [macOS (Universal)](https://github.com/edde746/plezy/releases/latest/download/plezy-macos.dmg)
|
||||
- [Linux (x64)](https://github.com/edde746/plezy/releases/latest) - .deb, .rpm, .pkg.tar.zst, and portable tar.gz available
|
||||
- [Windows (x64, arm64)](https://github.com/edde746/plezy/releases/latest/download/plezy-windows-installer.exe)
|
||||
- [macOS (x64, arm64)](https://github.com/edde746/plezy/releases/latest/download/plezy-macos.dmg)
|
||||
- [Linux (x64, arm64)](https://github.com/edde746/plezy/releases/latest) - .deb, .rpm, .pkg.tar.zst, and portable tar.gz available
|
||||
- [NixOS/Nix](https://github.com/mio-19/nurpkgs/tree/main/pkgs/plezy) - Community package by [@mio-19](https://github.com/mio-19)
|
||||
- **Homebrew** (macOS):
|
||||
```bash
|
||||
@@ -49,6 +47,12 @@ A modern Plex client for desktop and mobile. Built with Flutter for native perfo
|
||||
- Progress sync and resume
|
||||
- Auto-play next episode
|
||||
|
||||
### 📺 Live TV & DVR
|
||||
- EPG guide grid
|
||||
- Channel tuning
|
||||
- DVR recording rules and scheduled recordings
|
||||
- Multi-server DVR support
|
||||
|
||||
### 📥 Downloads
|
||||
- Download media for offline viewing
|
||||
- Background downloads with queue management
|
||||
|
||||
@@ -0,0 +1,10 @@
|
||||
# Autogenerated by fastlane
|
||||
#
|
||||
# Ensure this file is checked in to source control!
|
||||
|
||||
source "https://rubygems.org"
|
||||
|
||||
gem 'fastlane'
|
||||
|
||||
plugins_path = File.join(File.dirname(__FILE__), 'fastlane', 'Pluginfile')
|
||||
eval_gemfile(plugins_path) if File.exist?(plugins_path)
|
||||
@@ -0,0 +1,244 @@
|
||||
GEM
|
||||
remote: https://rubygems.org/
|
||||
specs:
|
||||
CFPropertyList (3.0.8)
|
||||
abbrev (0.1.2)
|
||||
addressable (2.8.8)
|
||||
public_suffix (>= 2.0.2, < 8.0)
|
||||
artifactory (3.0.17)
|
||||
atomos (0.1.3)
|
||||
aws-eventstream (1.4.0)
|
||||
aws-partitions (1.1215.0)
|
||||
aws-sdk-core (3.242.0)
|
||||
aws-eventstream (~> 1, >= 1.3.0)
|
||||
aws-partitions (~> 1, >= 1.992.0)
|
||||
aws-sigv4 (~> 1.9)
|
||||
base64
|
||||
bigdecimal
|
||||
jmespath (~> 1, >= 1.6.1)
|
||||
logger
|
||||
aws-sdk-kms (1.122.0)
|
||||
aws-sdk-core (~> 3, >= 3.241.4)
|
||||
aws-sigv4 (~> 1.5)
|
||||
aws-sdk-s3 (1.213.0)
|
||||
aws-sdk-core (~> 3, >= 3.241.4)
|
||||
aws-sdk-kms (~> 1)
|
||||
aws-sigv4 (~> 1.5)
|
||||
aws-sigv4 (1.12.1)
|
||||
aws-eventstream (~> 1, >= 1.0.2)
|
||||
babosa (1.0.4)
|
||||
base64 (0.2.0)
|
||||
benchmark (0.5.0)
|
||||
bigdecimal (4.0.1)
|
||||
claide (1.1.0)
|
||||
colored (1.2)
|
||||
colored2 (3.1.2)
|
||||
commander (4.6.0)
|
||||
highline (~> 2.0.0)
|
||||
csv (3.3.5)
|
||||
declarative (0.0.20)
|
||||
digest-crc (0.7.0)
|
||||
rake (>= 12.0.0, < 14.0.0)
|
||||
domain_name (0.6.20240107)
|
||||
dotenv (2.8.1)
|
||||
emoji_regex (3.2.3)
|
||||
excon (0.112.0)
|
||||
faraday (1.10.5)
|
||||
faraday-em_http (~> 1.0)
|
||||
faraday-em_synchrony (~> 1.0)
|
||||
faraday-excon (~> 1.1)
|
||||
faraday-httpclient (~> 1.0)
|
||||
faraday-multipart (~> 1.0)
|
||||
faraday-net_http (~> 1.0)
|
||||
faraday-net_http_persistent (~> 1.0)
|
||||
faraday-patron (~> 1.0)
|
||||
faraday-rack (~> 1.0)
|
||||
faraday-retry (~> 1.0)
|
||||
ruby2_keywords (>= 0.0.4)
|
||||
faraday-cookie_jar (0.0.8)
|
||||
faraday (>= 0.8.0)
|
||||
http-cookie (>= 1.0.0)
|
||||
faraday-em_http (1.0.0)
|
||||
faraday-em_synchrony (1.0.1)
|
||||
faraday-excon (1.1.0)
|
||||
faraday-httpclient (1.0.1)
|
||||
faraday-multipart (1.2.0)
|
||||
multipart-post (~> 2.0)
|
||||
faraday-net_http (1.0.2)
|
||||
faraday-net_http_persistent (1.2.0)
|
||||
faraday-patron (1.0.0)
|
||||
faraday-rack (1.0.0)
|
||||
faraday-retry (1.0.3)
|
||||
faraday_middleware (1.2.1)
|
||||
faraday (~> 1.0)
|
||||
fastimage (2.4.0)
|
||||
fastlane (2.232.1)
|
||||
CFPropertyList (>= 2.3, < 4.0.0)
|
||||
abbrev (~> 0.1.2)
|
||||
addressable (>= 2.8, < 3.0.0)
|
||||
artifactory (~> 3.0)
|
||||
aws-sdk-s3 (~> 1.197)
|
||||
babosa (>= 1.0.3, < 2.0.0)
|
||||
base64 (~> 0.2.0)
|
||||
benchmark (>= 0.1.0)
|
||||
bundler (>= 1.17.3, < 5.0.0)
|
||||
colored (~> 1.2)
|
||||
commander (~> 4.6)
|
||||
csv (~> 3.3)
|
||||
dotenv (>= 2.1.1, < 3.0.0)
|
||||
emoji_regex (>= 0.1, < 4.0)
|
||||
excon (>= 0.71.0, < 1.0.0)
|
||||
faraday (~> 1.0)
|
||||
faraday-cookie_jar (~> 0.0.6)
|
||||
faraday_middleware (~> 1.0)
|
||||
fastimage (>= 2.1.0, < 3.0.0)
|
||||
fastlane-sirp (>= 1.0.0)
|
||||
gh_inspector (>= 1.1.2, < 2.0.0)
|
||||
google-apis-androidpublisher_v3 (~> 0.3)
|
||||
google-apis-playcustomapp_v1 (~> 0.1)
|
||||
google-cloud-env (>= 1.6.0, <= 2.1.1)
|
||||
google-cloud-storage (~> 1.31)
|
||||
highline (~> 2.0)
|
||||
http-cookie (~> 1.0.5)
|
||||
json (< 3.0.0)
|
||||
jwt (>= 2.1.0, < 3)
|
||||
logger (>= 1.6, < 2.0)
|
||||
mini_magick (>= 4.9.4, < 5.0.0)
|
||||
multipart-post (>= 2.0.0, < 3.0.0)
|
||||
mutex_m (~> 0.3.0)
|
||||
naturally (~> 2.2)
|
||||
nkf (~> 0.2.0)
|
||||
optparse (>= 0.1.1, < 1.0.0)
|
||||
ostruct (>= 0.1.0)
|
||||
plist (>= 3.1.0, < 4.0.0)
|
||||
rubyzip (>= 2.0.0, < 3.0.0)
|
||||
security (= 0.1.5)
|
||||
simctl (~> 1.6.3)
|
||||
terminal-notifier (>= 2.0.0, < 3.0.0)
|
||||
terminal-table (~> 3)
|
||||
tty-screen (>= 0.6.3, < 1.0.0)
|
||||
tty-spinner (>= 0.8.0, < 1.0.0)
|
||||
word_wrap (~> 1.0.0)
|
||||
xcodeproj (>= 1.13.0, < 2.0.0)
|
||||
xcpretty (~> 0.4.1)
|
||||
xcpretty-travis-formatter (>= 0.0.3, < 2.0.0)
|
||||
fastlane-plugin-amazon_appstore (1.4.0)
|
||||
faraday (~> 1.0)
|
||||
faraday_middleware (~> 1.0)
|
||||
fastlane-sirp (1.0.0)
|
||||
sysrandom (~> 1.0)
|
||||
gh_inspector (1.1.3)
|
||||
google-apis-androidpublisher_v3 (0.96.0)
|
||||
google-apis-core (>= 0.15.0, < 2.a)
|
||||
google-apis-core (0.18.0)
|
||||
addressable (~> 2.5, >= 2.5.1)
|
||||
googleauth (~> 1.9)
|
||||
httpclient (>= 2.8.3, < 3.a)
|
||||
mini_mime (~> 1.0)
|
||||
mutex_m
|
||||
representable (~> 3.0)
|
||||
retriable (>= 2.0, < 4.a)
|
||||
google-apis-iamcredentials_v1 (0.26.0)
|
||||
google-apis-core (>= 0.15.0, < 2.a)
|
||||
google-apis-playcustomapp_v1 (0.17.0)
|
||||
google-apis-core (>= 0.15.0, < 2.a)
|
||||
google-apis-storage_v1 (0.60.0)
|
||||
google-apis-core (>= 0.15.0, < 2.a)
|
||||
google-cloud-core (1.8.0)
|
||||
google-cloud-env (>= 1.0, < 3.a)
|
||||
google-cloud-errors (~> 1.0)
|
||||
google-cloud-env (2.1.1)
|
||||
faraday (>= 1.0, < 3.a)
|
||||
google-cloud-errors (1.5.0)
|
||||
google-cloud-storage (1.58.0)
|
||||
addressable (~> 2.8)
|
||||
digest-crc (~> 0.4)
|
||||
google-apis-core (>= 0.18, < 2)
|
||||
google-apis-iamcredentials_v1 (~> 0.18)
|
||||
google-apis-storage_v1 (>= 0.42)
|
||||
google-cloud-core (~> 1.6)
|
||||
googleauth (~> 1.9)
|
||||
mini_mime (~> 1.0)
|
||||
googleauth (1.11.2)
|
||||
faraday (>= 1.0, < 3.a)
|
||||
google-cloud-env (~> 2.1)
|
||||
jwt (>= 1.4, < 3.0)
|
||||
multi_json (~> 1.11)
|
||||
os (>= 0.9, < 2.0)
|
||||
signet (>= 0.16, < 2.a)
|
||||
highline (2.0.3)
|
||||
http-cookie (1.0.8)
|
||||
domain_name (~> 0.5)
|
||||
httpclient (2.9.0)
|
||||
mutex_m
|
||||
jmespath (1.6.2)
|
||||
json (2.18.1)
|
||||
jwt (2.10.2)
|
||||
base64
|
||||
logger (1.7.0)
|
||||
mini_magick (4.13.2)
|
||||
mini_mime (1.1.5)
|
||||
multi_json (1.19.1)
|
||||
multipart-post (2.4.1)
|
||||
mutex_m (0.3.0)
|
||||
nanaimo (0.4.0)
|
||||
naturally (2.3.0)
|
||||
nkf (0.2.0)
|
||||
optparse (0.8.1)
|
||||
os (1.1.4)
|
||||
ostruct (0.6.3)
|
||||
plist (3.7.2)
|
||||
public_suffix (7.0.2)
|
||||
rake (13.3.1)
|
||||
representable (3.2.0)
|
||||
declarative (< 0.1.0)
|
||||
trailblazer-option (>= 0.1.1, < 0.2.0)
|
||||
uber (< 0.2.0)
|
||||
retriable (3.1.2)
|
||||
rexml (3.4.4)
|
||||
rouge (3.28.0)
|
||||
ruby2_keywords (0.0.5)
|
||||
rubyzip (2.4.1)
|
||||
security (0.1.5)
|
||||
signet (0.21.0)
|
||||
addressable (~> 2.8)
|
||||
faraday (>= 0.17.5, < 3.a)
|
||||
jwt (>= 1.5, < 4.0)
|
||||
multi_json (~> 1.10)
|
||||
simctl (1.6.10)
|
||||
CFPropertyList
|
||||
naturally
|
||||
sysrandom (1.0.5)
|
||||
terminal-notifier (2.0.0)
|
||||
terminal-table (3.0.2)
|
||||
unicode-display_width (>= 1.1.1, < 3)
|
||||
trailblazer-option (0.1.2)
|
||||
tty-cursor (0.7.1)
|
||||
tty-screen (0.8.2)
|
||||
tty-spinner (0.9.3)
|
||||
tty-cursor (~> 0.7)
|
||||
uber (0.1.0)
|
||||
unicode-display_width (2.6.0)
|
||||
word_wrap (1.0.0)
|
||||
xcodeproj (1.27.0)
|
||||
CFPropertyList (>= 2.3.3, < 4.0)
|
||||
atomos (~> 0.1.3)
|
||||
claide (>= 1.0.2, < 2.0)
|
||||
colored2 (~> 3.1)
|
||||
nanaimo (~> 0.4.0)
|
||||
rexml (>= 3.3.6, < 4.0)
|
||||
xcpretty (0.4.1)
|
||||
rouge (~> 3.28.0)
|
||||
xcpretty-travis-formatter (1.0.1)
|
||||
xcpretty (~> 0.2, >= 0.0.7)
|
||||
|
||||
PLATFORMS
|
||||
arm64-darwin-25
|
||||
ruby
|
||||
|
||||
DEPENDENCIES
|
||||
fastlane
|
||||
fastlane-plugin-amazon_appstore
|
||||
|
||||
BUNDLED WITH
|
||||
2.7.2
|
||||
@@ -55,6 +55,9 @@ android {
|
||||
signingConfig = signingConfigs.getByName("release")
|
||||
}
|
||||
// If key.properties doesn't exist, it will use debug signing for CI builds
|
||||
ndk {
|
||||
debugSymbolLevel = "FULL"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -77,10 +80,9 @@ dependencies {
|
||||
implementation("androidx.tvprovider:tvprovider:1.0.0")
|
||||
|
||||
// Media3 ExoPlayer for Android
|
||||
implementation("androidx.media3:media3-exoplayer:1.5.1")
|
||||
implementation("androidx.media3:media3-ui:1.5.1")
|
||||
implementation("androidx.media3:media3-common:1.5.1")
|
||||
implementation("androidx.media3:media3-session:1.5.1")
|
||||
implementation("androidx.media3:media3-exoplayer:1.9.2")
|
||||
implementation("androidx.media3:media3-ui:1.9.2")
|
||||
implementation("androidx.media3:media3-common:1.9.2")
|
||||
|
||||
// FFmpeg audio decoder for unsupported codecs (ALAC, DTS, TrueHD, etc.)
|
||||
implementation("org.jellyfin.media3:media3-ffmpeg-decoder:1.9.0+1")
|
||||
|
||||
@@ -43,6 +43,7 @@
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:banner="@drawable/tv_banner"
|
||||
android:appCategory="video"
|
||||
android:largeHeap="true"
|
||||
android:usesCleartextTraffic="true">
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
|
||||
@@ -36,6 +36,7 @@ import androidx.media3.common.Tracks
|
||||
import androidx.media3.common.VideoSize
|
||||
import androidx.media3.common.util.UnstableApi
|
||||
import androidx.media3.datasource.DefaultDataSource
|
||||
import androidx.media3.exoplayer.DefaultLoadControl
|
||||
import androidx.media3.exoplayer.DefaultRenderersFactory
|
||||
import androidx.media3.exoplayer.ExoPlayer
|
||||
import androidx.media3.exoplayer.source.DefaultMediaSourceFactory
|
||||
@@ -145,6 +146,7 @@ class ExoPlayerCore(private val activity: Activity) : Player.Listener {
|
||||
private fun ensureFlutterOverlayOnTop() {
|
||||
val contentView = activity.findViewById<ViewGroup>(android.R.id.content)
|
||||
contentView.post {
|
||||
if (!isInitialized) return@post
|
||||
var flutterContainer: ViewGroup? = null
|
||||
|
||||
for (i in 0 until contentView.childCount) {
|
||||
@@ -202,7 +204,7 @@ class ExoPlayerCore(private val activity: Activity) : Player.Listener {
|
||||
}
|
||||
}
|
||||
|
||||
fun initialize(): Boolean {
|
||||
fun initialize(bufferSizeBytes: Int? = null): Boolean {
|
||||
if (isInitialized) {
|
||||
Log.d(TAG, "Already initialized")
|
||||
return true
|
||||
@@ -337,8 +339,19 @@ class ExoPlayerCore(private val activity: Activity) : Player.Listener {
|
||||
|
||||
val wrappedRenderersFactory = AssRenderersFactory(handler, renderersFactory)
|
||||
|
||||
val loadControl = DefaultLoadControl.Builder().apply {
|
||||
if (bufferSizeBytes != null && bufferSizeBytes > 0) {
|
||||
setTargetBufferBytes(bufferSizeBytes)
|
||||
setPrioritizeTimeOverSizeThresholds(false)
|
||||
Log.d(TAG, "Buffer byte limit set to ${bufferSizeBytes / 1024 / 1024}MB")
|
||||
} else {
|
||||
Log.d(TAG, "Buffer in auto mode (time-based thresholds)")
|
||||
}
|
||||
}.build()
|
||||
|
||||
exoPlayer = ExoPlayer.Builder(activity)
|
||||
.setTrackSelector(trackSelector!!)
|
||||
.setLoadControl(loadControl)
|
||||
.setAudioAttributes(audioAttributes, false) // We handle audio focus manually
|
||||
.setMediaSourceFactory(mediaSourceFactory)
|
||||
.setRenderersFactory(wrappedRenderersFactory)
|
||||
@@ -1265,14 +1278,19 @@ class ExoPlayerCore(private val activity: Activity) : Player.Listener {
|
||||
val contentView = activity.findViewById<ViewGroup>(android.R.id.content)
|
||||
contentView.viewTreeObserver.removeOnGlobalLayoutListener(listener)
|
||||
}
|
||||
overlayLayoutListener = null
|
||||
|
||||
// Post view removal to next frame to avoid SurfaceControl race on render thread
|
||||
val contentView = activity.findViewById<ViewGroup>(android.R.id.content)
|
||||
// Remove SurfaceView from container synchronously — triggers
|
||||
// onDetachedFromWindow which properly unregisters PositionUpdateListener
|
||||
// and releases SurfaceControl before the render thread can access it.
|
||||
val container = surfaceContainer
|
||||
val subtitle = subtitleView
|
||||
surfaceView?.let { container?.removeView(it) }
|
||||
subtitleView?.let { container?.removeView(it) }
|
||||
|
||||
// Defer empty container removal (plain FrameLayout, no SurfaceControl)
|
||||
val contentView = activity.findViewById<ViewGroup>(android.R.id.content)
|
||||
contentView.post {
|
||||
container?.let { contentView.removeView(it) }
|
||||
subtitle?.let { contentView.removeView(it) }
|
||||
}
|
||||
surfaceContainer = null
|
||||
surfaceView = null
|
||||
|
||||
@@ -1,6 +1,8 @@
|
||||
package com.edde746.plezy.exoplayer
|
||||
|
||||
import android.app.Activity
|
||||
import android.app.ActivityManager
|
||||
import android.content.Context
|
||||
import android.net.Uri
|
||||
import android.util.Log
|
||||
import com.edde746.plezy.mpv.MpvPlayerCore
|
||||
@@ -96,7 +98,7 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
|
||||
|
||||
override fun onMethodCall(call: MethodCall, result: MethodChannel.Result) {
|
||||
when (call.method) {
|
||||
"initialize" -> handleInitialize(result)
|
||||
"initialize" -> handleInitialize(call, result)
|
||||
"dispose" -> handleDispose(result)
|
||||
"open" -> handleOpen(call, result)
|
||||
"play" -> handlePlay(result)
|
||||
@@ -119,13 +121,17 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
|
||||
)
|
||||
"getStats" -> handleGetStats(result)
|
||||
"getPlayerType" -> result.success(if (usingMpvFallback) "mpv" else "exoplayer")
|
||||
"getHeapSize" -> {
|
||||
val am = activity?.getSystemService(Context.ACTIVITY_SERVICE) as? ActivityManager
|
||||
result.success(am?.largeMemoryClass ?: 0)
|
||||
}
|
||||
"setSubtitleStyle" -> handleSetSubtitleStyle(call, result)
|
||||
"observeProperty" -> handleObserveProperty(call, result)
|
||||
else -> result.notImplemented()
|
||||
}
|
||||
}
|
||||
|
||||
private fun handleInitialize(result: MethodChannel.Result) {
|
||||
private fun handleInitialize(call: MethodCall, result: MethodChannel.Result) {
|
||||
val currentActivity = activity
|
||||
if (currentActivity == null) {
|
||||
result.error("NO_ACTIVITY", "Activity not available", null)
|
||||
@@ -138,12 +144,14 @@ class ExoPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
|
||||
return
|
||||
}
|
||||
|
||||
val bufferSizeBytes = call.argument<Int>("bufferSizeBytes")
|
||||
|
||||
currentActivity.runOnUiThread {
|
||||
try {
|
||||
playerCore = ExoPlayerCore(currentActivity).apply {
|
||||
delegate = this@ExoPlayerPlugin
|
||||
}
|
||||
val success = playerCore?.initialize() ?: false
|
||||
val success = playerCore?.initialize(bufferSizeBytes = bufferSizeBytes) ?: false
|
||||
|
||||
// Start hidden
|
||||
playerCore?.setVisible(false)
|
||||
|
||||
@@ -135,6 +135,7 @@ class MpvPlayerCore(private val activity: Activity) :
|
||||
private fun ensureFlutterOverlayOnTop() {
|
||||
val contentView = activity.findViewById<ViewGroup>(android.R.id.content)
|
||||
contentView.post {
|
||||
if (!isInitialized) return@post
|
||||
var flutterContainer: ViewGroup? = null
|
||||
|
||||
// First pass: look for FlutterView by name (debug builds)
|
||||
@@ -717,15 +718,20 @@ class MpvPlayerCore(private val activity: Activity) :
|
||||
MPVLib.removeObserver(this)
|
||||
MPVLib.removeLogObserver(this)
|
||||
|
||||
surfaceView?.holder?.removeCallback(this)
|
||||
overlayLayoutListener?.let { listener ->
|
||||
val contentView = activity.findViewById<ViewGroup>(android.R.id.content)
|
||||
contentView.viewTreeObserver.removeOnGlobalLayoutListener(listener)
|
||||
}
|
||||
overlayLayoutListener = null
|
||||
|
||||
// Post view removal to next frame to avoid SurfaceControl race on render thread
|
||||
val contentView = activity.findViewById<ViewGroup>(android.R.id.content)
|
||||
// Remove SurfaceView synchronously (keep callback so surfaceDestroyed
|
||||
// fires → MPVLib.detachSurface()), then remove callback after.
|
||||
val container = surfaceContainer
|
||||
surfaceView?.let { container?.removeView(it) }
|
||||
surfaceView?.holder?.removeCallback(this)
|
||||
|
||||
// Defer empty container removal (plain FrameLayout, no SurfaceControl)
|
||||
val contentView = activity.findViewById<ViewGroup>(android.R.id.content)
|
||||
contentView.post {
|
||||
container?.let { contentView.removeView(it) }
|
||||
}
|
||||
|
||||
@@ -102,6 +102,7 @@ class MpvPlayerPlugin : FlutterPlugin, MethodChannel.MethodCallHandler,
|
||||
"abandonAudioFocus" -> handleAbandonAudioFocus(result)
|
||||
"openContentFd" -> handleOpenContentFd(call, result)
|
||||
"isInitialized" -> result.success(playerCore?.isInitialized ?: false)
|
||||
"setLogLevel" -> result.success(null)
|
||||
else -> result.notImplemented()
|
||||
}
|
||||
}
|
||||
|
||||
+24
-41
@@ -4,60 +4,43 @@ Dotenv.load("../../.env")
|
||||
default_platform(:android)
|
||||
|
||||
platform :android do
|
||||
desc "Deploy a new version to the Google Play"
|
||||
lane :deploy do
|
||||
gradle(task: "clean bundleRelease")
|
||||
|
||||
# Get version code from pubspec.yaml
|
||||
pubspec_path = "#{ENV['PWD']}/../pubspec.yaml"
|
||||
pubspec_content = File.read(pubspec_path)
|
||||
version_match = pubspec_content.match(/version:\s*(.+)\+(\d+)/)
|
||||
|
||||
if version_match
|
||||
version_code = version_match[2].to_i
|
||||
UI.message("Using version code: #{version_code}")
|
||||
else
|
||||
UI.user_error!("Could not extract version code from pubspec.yaml")
|
||||
end
|
||||
|
||||
upload_to_play_store(
|
||||
version_code: version_code,
|
||||
skip_upload_changelogs: true,
|
||||
skip_upload_metadata: true,
|
||||
skip_upload_images: true,
|
||||
skip_upload_screenshots: true
|
||||
)
|
||||
end
|
||||
|
||||
desc "Build release AAB"
|
||||
lane :build do
|
||||
# Navigate to Flutter project root and build
|
||||
sh("cd #{ENV['PWD']}/.. && flutter build appbundle --dart-define=ENABLE_IN_APP_REVIEW=true")
|
||||
end
|
||||
|
||||
desc "Build and deploy to Google Play Store"
|
||||
lane :release do
|
||||
# Build the Flutter app
|
||||
sh("cd #{ENV['PWD']}/.. && flutter build appbundle --dart-define=ENABLE_IN_APP_REVIEW=true")
|
||||
|
||||
# Get version code from pubspec.yaml
|
||||
# Get version from pubspec.yaml
|
||||
pubspec_path = "#{ENV['PWD']}/../pubspec.yaml"
|
||||
pubspec_content = File.read(pubspec_path)
|
||||
version_match = pubspec_content.match(/version:\s*(.+)\+(\d+)/)
|
||||
|
||||
if version_match
|
||||
version_name = version_match[1].strip
|
||||
version_code = version_match[2].to_i
|
||||
UI.message("Using version code: #{version_code}")
|
||||
UI.message("Using version: #{version_name}+#{version_code}")
|
||||
else
|
||||
UI.user_error!("Could not extract version code from pubspec.yaml")
|
||||
UI.user_error!("Could not extract version from pubspec.yaml")
|
||||
end
|
||||
|
||||
# Upload to Play Store
|
||||
debug_info_dir = "./build/debug-info/#{version_name}+#{version_code}"
|
||||
|
||||
# Build the Flutter app
|
||||
sh("cd #{ENV['PWD']}/.. && flutter build appbundle --dart-define=ENABLE_IN_APP_REVIEW=true --obfuscate --split-debug-info=#{debug_info_dir}/aab")
|
||||
|
||||
upload_to_play_store(
|
||||
track: "internal",
|
||||
release_status: "draft",
|
||||
track: "production",
|
||||
release_status: "completed",
|
||||
version_code: version_code,
|
||||
aab: "../build/app/outputs/bundle/release/app-release.aab"
|
||||
)
|
||||
|
||||
# Build split-per-ABI APKs for Amazon Appstore (doesn't accept AABs)
|
||||
sh("cd #{ENV['PWD']}/.. && flutter build apk --release --split-per-abi --obfuscate --split-debug-info=#{debug_info_dir}/apk")
|
||||
|
||||
upload_to_amazon_appstore(
|
||||
apk_paths: [
|
||||
"../build/app/outputs/flutter-apk/app-armeabi-v7a-release.apk",
|
||||
"../build/app/outputs/flutter-apk/app-arm64-v8a-release.apk"
|
||||
],
|
||||
overwrite_upload: true,
|
||||
overwrite_upload_mode: 'reuse'
|
||||
)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
@@ -0,0 +1,5 @@
|
||||
# Autogenerated by fastlane
|
||||
#
|
||||
# Ensure this file is checked in to source control!
|
||||
|
||||
gem 'fastlane-plugin-amazon_appstore'
|
||||
@@ -52,7 +52,6 @@
|
||||
<key>UIBackgroundModes</key>
|
||||
<array>
|
||||
<string>fetch</string>
|
||||
<string>processing</string>
|
||||
</array>
|
||||
<key>UISupportedInterfaceOrientations</key>
|
||||
<array>
|
||||
|
||||
@@ -236,6 +236,11 @@ class MpvPlayerCore: NSObject {
|
||||
return cstr.map { String(cString: $0) }
|
||||
}
|
||||
|
||||
func setLogLevel(_ level: String) {
|
||||
guard let mpv = mpv else { return }
|
||||
mpv_request_log_messages(mpv, level)
|
||||
}
|
||||
|
||||
func observeProperty(_ name: String, format: String) {
|
||||
guard mpv != nil else { return }
|
||||
|
||||
|
||||
@@ -80,6 +80,9 @@ class MpvPlayerPlugin: NSObject, FlutterPlugin, FlutterStreamHandler, MpvPlayerD
|
||||
case "updateFrame":
|
||||
handleUpdateFrame(result: result)
|
||||
|
||||
case "setLogLevel":
|
||||
handleSetLogLevel(call: call, result: result)
|
||||
|
||||
default:
|
||||
result(FlutterMethodNotImplemented)
|
||||
}
|
||||
@@ -218,6 +221,16 @@ class MpvPlayerPlugin: NSObject, FlutterPlugin, FlutterStreamHandler, MpvPlayerD
|
||||
}
|
||||
}
|
||||
|
||||
private func handleSetLogLevel(call: FlutterMethodCall, result: @escaping FlutterResult) {
|
||||
guard let args = call.arguments as? [String: Any],
|
||||
let level = args["level"] as? String else {
|
||||
result(FlutterError(code: "INVALID_ARGS", message: "Missing 'level'", details: nil))
|
||||
return
|
||||
}
|
||||
playerCore?.setLogLevel(level)
|
||||
result(nil)
|
||||
}
|
||||
|
||||
// MARK: - MpvPlayerDelegate
|
||||
|
||||
func onPropertyChange(name: String, value: Any?) {
|
||||
|
||||
+1
-30
@@ -4,35 +4,6 @@ Dotenv.load("../../.env")
|
||||
default_platform(:ios)
|
||||
|
||||
platform :ios do
|
||||
desc "Push a new beta build to TestFlight"
|
||||
lane :beta do
|
||||
build_app(workspace: "Runner.xcworkspace", scheme: "Runner")
|
||||
upload_to_testflight
|
||||
end
|
||||
|
||||
desc "Push a new release build to the App Store"
|
||||
lane :release do
|
||||
build_app(workspace: "Runner.xcworkspace", scheme: "Runner")
|
||||
upload_to_app_store
|
||||
end
|
||||
|
||||
desc "Build release IPA"
|
||||
lane :build do
|
||||
# Navigate to Flutter project root and build
|
||||
sh("cd #{ENV['PWD']}/.. && flutter build ipa --dart-define=ENABLE_IN_APP_REVIEW=true")
|
||||
end
|
||||
|
||||
desc "Build and deploy to TestFlight"
|
||||
lane :deploy_testflight do
|
||||
# Build the Flutter app
|
||||
sh("cd #{ENV['PWD']}/.. && flutter build ipa --dart-define=ENABLE_IN_APP_REVIEW=true")
|
||||
|
||||
# Upload to TestFlight
|
||||
upload_to_testflight(
|
||||
skip_waiting_for_build_processing: true
|
||||
)
|
||||
end
|
||||
|
||||
desc "Build and deploy to App Store"
|
||||
lane :deploy_appstore do
|
||||
# Build the Flutter app
|
||||
@@ -46,4 +17,4 @@ platform :ios do
|
||||
skip_screenshots: true, # https://github.com/fastlane/fastlane/issues/29735
|
||||
)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -71,6 +71,10 @@ class SelectKeyUpSuppressor {
|
||||
_suppressSelectUntilKeyUp = true;
|
||||
}
|
||||
|
||||
static void clearSuppression() {
|
||||
_suppressSelectUntilKeyUp = false;
|
||||
}
|
||||
|
||||
static bool consumeIfSuppressed(KeyEvent event) {
|
||||
if (!_suppressSelectUntilKeyUp) return false;
|
||||
if (event.logicalKey.isSelectKey) {
|
||||
|
||||
@@ -29,8 +29,9 @@ class FocusTheme {
|
||||
BuildContext context, {
|
||||
required bool isFocused,
|
||||
double borderRadius = defaultBorderRadius,
|
||||
Color? color,
|
||||
}) {
|
||||
final focusColor = getFocusBorderColor(context);
|
||||
final focusColor = color ?? getFocusBorderColor(context);
|
||||
|
||||
return BoxDecoration(
|
||||
borderRadius: BorderRadius.circular(borderRadius),
|
||||
|
||||
@@ -0,0 +1,95 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import 'focus_theme.dart';
|
||||
import 'focusable_wrapper.dart';
|
||||
import 'input_mode_tracker.dart';
|
||||
|
||||
/// A focusable button wrapper for D-pad navigation on TV.
|
||||
///
|
||||
/// Wraps any button widget with [FocusableWrapper] and adds a white overlay
|
||||
/// + contrasting border when focused. Tracks focus state internally so callers
|
||||
/// don't need manual state management.
|
||||
///
|
||||
/// ```dart
|
||||
/// FocusableButton(
|
||||
/// autofocus: true,
|
||||
/// onPressed: _doSomething,
|
||||
/// child: FilledButton.icon(
|
||||
/// onPressed: _doSomething,
|
||||
/// icon: Icon(Symbols.add_rounded),
|
||||
/// label: Text('Create'),
|
||||
/// ),
|
||||
/// )
|
||||
/// ```
|
||||
class FocusableButton extends StatefulWidget {
|
||||
final Widget child;
|
||||
final VoidCallback? onPressed;
|
||||
final bool autofocus;
|
||||
final FocusNode? focusNode;
|
||||
|
||||
/// Navigation callbacks for explicit focus control (e.g. horizontal button rows).
|
||||
final VoidCallback? onNavigateUp;
|
||||
final VoidCallback? onNavigateDown;
|
||||
final VoidCallback? onNavigateLeft;
|
||||
final VoidCallback? onNavigateRight;
|
||||
final VoidCallback? onBack;
|
||||
|
||||
/// Whether to scroll the widget into view when focused.
|
||||
final bool autoScroll;
|
||||
|
||||
/// Whether to use background color instead of border for focus indicator.
|
||||
final bool useBackgroundFocus;
|
||||
|
||||
const FocusableButton({
|
||||
super.key,
|
||||
required this.child,
|
||||
this.onPressed,
|
||||
this.autofocus = false,
|
||||
this.focusNode,
|
||||
this.onNavigateUp,
|
||||
this.onNavigateDown,
|
||||
this.onNavigateLeft,
|
||||
this.onNavigateRight,
|
||||
this.onBack,
|
||||
this.autoScroll = true,
|
||||
this.useBackgroundFocus = false,
|
||||
});
|
||||
|
||||
@override
|
||||
State<FocusableButton> createState() => _FocusableButtonState();
|
||||
}
|
||||
|
||||
class _FocusableButtonState extends State<FocusableButton> {
|
||||
bool _isFocused = false;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final isKeyboard = InputModeTracker.isKeyboardMode(context);
|
||||
final showFocus = _isFocused && isKeyboard;
|
||||
final duration = FocusTheme.getAnimationDuration(context);
|
||||
// In dpad mode: focused = full opacity, unfocused = dimmed
|
||||
final opacity = isKeyboard && !_isFocused ? 0.6 : 1.0;
|
||||
|
||||
return FocusableWrapper(
|
||||
autofocus: widget.autofocus,
|
||||
focusNode: widget.focusNode,
|
||||
disableScale: true,
|
||||
borderRadius: 100,
|
||||
useBackgroundFocus: widget.useBackgroundFocus,
|
||||
descendantsAreFocusable: false,
|
||||
onFocusChange: (f) => setState(() => _isFocused = f),
|
||||
autoScroll: widget.autoScroll,
|
||||
onSelect: widget.onPressed,
|
||||
onNavigateUp: widget.onNavigateUp,
|
||||
onNavigateDown: widget.onNavigateDown,
|
||||
onNavigateLeft: widget.onNavigateLeft,
|
||||
onNavigateRight: widget.onNavigateRight,
|
||||
onBack: widget.onBack,
|
||||
child: AnimatedOpacity(
|
||||
opacity: showFocus ? 1.0 : opacity,
|
||||
duration: duration,
|
||||
child: widget.child,
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -33,6 +33,9 @@ class FocusableWrapper extends StatefulWidget {
|
||||
/// Called when the user presses UP and there's no focusable item above.
|
||||
final VoidCallback? onNavigateUp;
|
||||
|
||||
/// Called when the user presses DOWN and there's no focusable item below.
|
||||
final VoidCallback? onNavigateDown;
|
||||
|
||||
/// Called when the user presses LEFT and there's no focusable item to the left.
|
||||
final VoidCallback? onNavigateLeft;
|
||||
|
||||
@@ -83,10 +86,19 @@ class FocusableWrapper extends StatefulWidget {
|
||||
/// Useful for video controls where outline doesn't look good.
|
||||
final bool useBackgroundFocus;
|
||||
|
||||
/// Custom color for the focus border. Only used when [useBackgroundFocus] is false.
|
||||
/// Useful for filled buttons where the default primary border blends in.
|
||||
final Color? focusColor;
|
||||
|
||||
/// Whether to disable the scale animation on focus.
|
||||
/// Useful for elements like sliders where scaling looks odd.
|
||||
final bool disableScale;
|
||||
|
||||
/// Whether descendants can receive focus.
|
||||
/// Set to false when the child widget has its own Focus (e.g. buttons)
|
||||
/// that would compete with this wrapper's focus handling.
|
||||
final bool descendantsAreFocusable;
|
||||
|
||||
const FocusableWrapper({
|
||||
super.key,
|
||||
required this.child,
|
||||
@@ -94,6 +106,7 @@ class FocusableWrapper extends StatefulWidget {
|
||||
this.onLongPress,
|
||||
this.onFocusChange,
|
||||
this.onNavigateUp,
|
||||
this.onNavigateDown,
|
||||
this.onNavigateLeft,
|
||||
this.onNavigateRight,
|
||||
this.onBack,
|
||||
@@ -109,7 +122,9 @@ class FocusableWrapper extends StatefulWidget {
|
||||
this.enableLongPress = false,
|
||||
this.longPressDuration = const Duration(milliseconds: 500),
|
||||
this.useBackgroundFocus = false,
|
||||
this.focusColor,
|
||||
this.disableScale = false,
|
||||
this.descendantsAreFocusable = true,
|
||||
});
|
||||
|
||||
@override
|
||||
@@ -367,6 +382,12 @@ class _FocusableWrapperState extends State<FocusableWrapper> with SingleTickerPr
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
// DOWN arrow - if callback provided, navigate down
|
||||
if (key == LogicalKeyboardKey.arrowDown && widget.onNavigateDown != null) {
|
||||
widget.onNavigateDown!();
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
// LEFT arrow - if callback provided, navigate left (caller is responsible
|
||||
// for only providing this callback when the item is at the left edge)
|
||||
if (key == LogicalKeyboardKey.arrowLeft && widget.onNavigateLeft != null) {
|
||||
@@ -398,11 +419,12 @@ class _FocusableWrapperState extends State<FocusableWrapper> with SingleTickerPr
|
||||
// Choose decoration based on useBackgroundFocus
|
||||
final decoration = widget.useBackgroundFocus
|
||||
? FocusTheme.focusBackgroundDecoration(isFocused: showFocus, borderRadius: widget.borderRadius)
|
||||
: FocusTheme.focusDecoration(context, isFocused: showFocus, borderRadius: widget.borderRadius);
|
||||
: FocusTheme.focusDecoration(context, isFocused: showFocus, borderRadius: widget.borderRadius, color: widget.focusColor);
|
||||
|
||||
Widget result = Focus(
|
||||
focusNode: _focusNode,
|
||||
autofocus: widget.autofocus,
|
||||
descendantsAreFocusable: widget.descendantsAreFocusable,
|
||||
onFocusChange: _handleFocusChange,
|
||||
onKeyEvent: _handleKeyEvent,
|
||||
child: AnimatedBuilder(
|
||||
|
||||
+74
-4
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"app": {
|
||||
"title": "Plezy"
|
||||
},
|
||||
},
|
||||
"auth": {
|
||||
"signInWithPlex": "Mit Plex anmelden",
|
||||
"showQRCode": "QR-Code anzeigen",
|
||||
@@ -51,7 +51,8 @@
|
||||
"exitConfirmTitle": "App beenden?",
|
||||
"exitConfirmMessage": "Möchtest du die App wirklich beenden?",
|
||||
"dontAskAgain": "Nicht erneut fragen",
|
||||
"exit": "Beenden"
|
||||
"exit": "Beenden",
|
||||
"viewAll": "Alle anzeigen"
|
||||
},
|
||||
"screens": {
|
||||
"licenses": "Lizenzen",
|
||||
@@ -125,6 +126,8 @@
|
||||
"hardwareDecodingDescription": "Hardwarebeschleunigung verwenden, sofern verfügbar",
|
||||
"bufferSize": "Puffergröße",
|
||||
"bufferSizeMB": "${size}MB",
|
||||
"bufferSizeAuto": "Auto (Empfohlen)",
|
||||
"bufferSizeWarning": "Ihr Gerät hat ${heap}MB Speicher. Ein ${size}MB-Puffer kann Wiedergabeprobleme verursachen.",
|
||||
"subtitleStyling": "Untertitel-Stil",
|
||||
"subtitleStylingDescription": "Aussehen von Untertiteln anpassen",
|
||||
"smallSkipDuration": "Kleine Sprungdauer",
|
||||
@@ -266,7 +269,8 @@
|
||||
"confirmDelete": "Sind Sie sicher, dass Sie dieses Element aus Ihrem Dateisystem löschen möchten?",
|
||||
"deleteMultipleWarning": "Mehrere Elemente können gelöscht werden.",
|
||||
"mediaDeletedSuccessfully": "Medienelement erfolgreich gelöscht",
|
||||
"mediaFailedToDelete": "Löschen des Medienelements fehlgeschlagen"
|
||||
"mediaFailedToDelete": "Löschen des Medienelements fehlgeschlagen",
|
||||
"rate": "Bewerten"
|
||||
},
|
||||
"accessibility": {
|
||||
"mediaCardMovie": "${title}, Film",
|
||||
@@ -320,6 +324,9 @@
|
||||
"versionsButton": "Videoversionen",
|
||||
"pipButton": "Bild-in-Bild Modus",
|
||||
"aspectRatioButton": "Seitenverhältnis",
|
||||
"ambientLighting": "Umgebungsbeleuchtung",
|
||||
"ambientLightingOn": "Umgebungsbeleuchtung aktivieren",
|
||||
"ambientLightingOff": "Umgebungsbeleuchtung deaktivieren",
|
||||
"fullscreenButton": "Vollbild aktivieren",
|
||||
"exitFullscreenButton": "Vollbild verlassen",
|
||||
"alwaysOnTopButton": "Immer im Vordergrund",
|
||||
@@ -336,7 +343,9 @@
|
||||
"unknown": "Ein Fehler ist aufgetreten: ${error}"
|
||||
},
|
||||
"chapters": "Kapitel",
|
||||
"noChaptersAvailable": "Keine Kapitel verfügbar"
|
||||
"noChaptersAvailable": "Keine Kapitel verfügbar",
|
||||
"queue": "Queue",
|
||||
"noQueueItems": "No items in queue"
|
||||
},
|
||||
"userStatus": {
|
||||
"admin": "Eigentümer",
|
||||
@@ -824,5 +833,66 @@
|
||||
"launchFailed": "Externer Player konnte nicht geöffnet werden",
|
||||
"appNotInstalled": "${name} ist nicht installiert",
|
||||
"playInExternalPlayer": "In externem Player abspielen"
|
||||
},
|
||||
"metadataEdit": {
|
||||
"editMetadata": "Bearbeiten...",
|
||||
"screenTitle": "Metadaten bearbeiten",
|
||||
"basicInfo": "Grundlegende Infos",
|
||||
"artwork": "Artwork",
|
||||
"advancedSettings": "Erweiterte Einstellungen",
|
||||
"title": "Titel",
|
||||
"sortTitle": "Sortiertitel",
|
||||
"originalTitle": "Originaltitel",
|
||||
"releaseDate": "Erscheinungsdatum",
|
||||
"contentRating": "Altersfreigabe",
|
||||
"studio": "Studio",
|
||||
"tagline": "Tagline",
|
||||
"summary": "Zusammenfassung",
|
||||
"poster": "Poster",
|
||||
"background": "Hintergrund",
|
||||
"selectPoster": "Poster auswählen",
|
||||
"selectBackground": "Hintergrund auswählen",
|
||||
"fromUrl": "Von URL",
|
||||
"uploadFile": "Datei hochladen",
|
||||
"enterImageUrl": "Bild-URL eingeben",
|
||||
"imageUrl": "Bild-URL",
|
||||
"metadataUpdated": "Metadaten aktualisiert",
|
||||
"metadataUpdateFailed": "Metadaten konnten nicht aktualisiert werden",
|
||||
"artworkUpdated": "Artwork aktualisiert",
|
||||
"artworkUpdateFailed": "Artwork konnte nicht aktualisiert werden",
|
||||
"noArtworkAvailable": "Kein Artwork verfügbar",
|
||||
"notSet": "Nicht festgelegt",
|
||||
"libraryDefault": "Bibliotheksstandard",
|
||||
"accountDefault": "Kontostandard",
|
||||
"seriesDefault": "Serienstandard",
|
||||
"episodeSorting": "Episodensortierung",
|
||||
"oldestFirst": "Älteste zuerst",
|
||||
"newestFirst": "Neueste zuerst",
|
||||
"keep": "Behalten",
|
||||
"allEpisodes": "Alle Episoden",
|
||||
"latestEpisodes": "${count} neueste Episoden",
|
||||
"latestEpisode": "Neueste Episode",
|
||||
"episodesAddedPastDays": "Episoden der letzten ${count} Tage",
|
||||
"deleteAfterPlaying": "Episoden nach Wiedergabe löschen",
|
||||
"never": "Nie",
|
||||
"afterADay": "Nach einem Tag",
|
||||
"afterAWeek": "Nach einer Woche",
|
||||
"afterAMonth": "Nach einem Monat",
|
||||
"onNextRefresh": "Bei nächster Aktualisierung",
|
||||
"seasons": "Staffeln",
|
||||
"show": "Anzeigen",
|
||||
"hide": "Ausblenden",
|
||||
"episodeOrdering": "Episodenreihenfolge",
|
||||
"tmdbAiring": "The Movie Database (Ausgestrahlt)",
|
||||
"tvdbAiring": "TheTVDB (Ausgestrahlt)",
|
||||
"tvdbAbsolute": "TheTVDB (Absolut)",
|
||||
"metadataLanguage": "Metadaten-Sprache",
|
||||
"useOriginalTitle": "Originaltitel verwenden",
|
||||
"preferredAudioLanguage": "Bevorzugte Audiosprache",
|
||||
"preferredSubtitleLanguage": "Bevorzugte Untertitelsprache",
|
||||
"subtitleMode": "Automatische Untertitelauswahl",
|
||||
"manuallySelected": "Manuell ausgewählt",
|
||||
"shownWithForeignAudio": "Bei fremdsprachigem Audio anzeigen",
|
||||
"alwaysEnabled": "Immer aktiviert"
|
||||
}
|
||||
}
|
||||
|
||||
+73
-3
@@ -51,7 +51,8 @@
|
||||
"exitConfirmTitle": "Exit app?",
|
||||
"exitConfirmMessage": "Are you sure you want to exit?",
|
||||
"dontAskAgain": "Don't ask again",
|
||||
"exit": "Exit"
|
||||
"exit": "Exit",
|
||||
"viewAll": "View All"
|
||||
},
|
||||
"screens": {
|
||||
"licenses": "Licenses",
|
||||
@@ -125,6 +126,8 @@
|
||||
"hardwareDecodingDescription": "Use hardware acceleration when available",
|
||||
"bufferSize": "Buffer Size",
|
||||
"bufferSizeMB": "${size}MB",
|
||||
"bufferSizeAuto": "Auto (Recommended)",
|
||||
"bufferSizeWarning": "Your device has ${heap}MB of memory. A ${size}MB buffer may cause playback issues.",
|
||||
"subtitleStyling": "Subtitle Styling",
|
||||
"subtitleStylingDescription": "Customize subtitle appearance",
|
||||
"smallSkipDuration": "Small Skip Duration",
|
||||
@@ -266,7 +269,8 @@
|
||||
"confirmDelete": "Are you sure you want to delete this item from your filesystem?",
|
||||
"deleteMultipleWarning": "Multiple items may be deleted.",
|
||||
"mediaDeletedSuccessfully": "Media item deleted successfully",
|
||||
"mediaFailedToDelete": "Failed to delete media item"
|
||||
"mediaFailedToDelete": "Failed to delete media item",
|
||||
"rate": "Rate"
|
||||
},
|
||||
"accessibility": {
|
||||
"mediaCardMovie": "${title}, movie",
|
||||
@@ -320,6 +324,9 @@
|
||||
"versionsButton": "Video versions",
|
||||
"pipButton": "Picture-in-Picture mode",
|
||||
"aspectRatioButton": "Aspect ratio",
|
||||
"ambientLighting": "Ambient lighting",
|
||||
"ambientLightingOn": "Enable ambient lighting",
|
||||
"ambientLightingOff": "Disable ambient lighting",
|
||||
"fullscreenButton": "Enter fullscreen",
|
||||
"exitFullscreenButton": "Exit fullscreen",
|
||||
"alwaysOnTopButton": "Always on top",
|
||||
@@ -336,7 +343,9 @@
|
||||
"unknown": "An error occurred: ${error}"
|
||||
},
|
||||
"chapters": "Chapters",
|
||||
"noChaptersAvailable": "No chapters available"
|
||||
"noChaptersAvailable": "No chapters available",
|
||||
"queue": "Queue",
|
||||
"noQueueItems": "No items in queue"
|
||||
},
|
||||
"userStatus": {
|
||||
"admin": "Admin",
|
||||
@@ -824,5 +833,66 @@
|
||||
"launchFailed": "Failed to open external player",
|
||||
"appNotInstalled": "${name} is not installed",
|
||||
"playInExternalPlayer": "Play in External Player"
|
||||
},
|
||||
"metadataEdit": {
|
||||
"editMetadata": "Edit...",
|
||||
"screenTitle": "Edit Metadata",
|
||||
"basicInfo": "Basic Info",
|
||||
"artwork": "Artwork",
|
||||
"advancedSettings": "Advanced Settings",
|
||||
"title": "Title",
|
||||
"sortTitle": "Sort Title",
|
||||
"originalTitle": "Original Title",
|
||||
"releaseDate": "Release Date",
|
||||
"contentRating": "Content Rating",
|
||||
"studio": "Studio",
|
||||
"tagline": "Tagline",
|
||||
"summary": "Summary",
|
||||
"poster": "Poster",
|
||||
"background": "Background",
|
||||
"selectPoster": "Select Poster",
|
||||
"selectBackground": "Select Background",
|
||||
"fromUrl": "From URL",
|
||||
"uploadFile": "Upload File",
|
||||
"enterImageUrl": "Enter image URL",
|
||||
"imageUrl": "Image URL",
|
||||
"metadataUpdated": "Metadata updated",
|
||||
"metadataUpdateFailed": "Failed to update metadata",
|
||||
"artworkUpdated": "Artwork updated",
|
||||
"artworkUpdateFailed": "Failed to update artwork",
|
||||
"noArtworkAvailable": "No artwork available",
|
||||
"notSet": "Not set",
|
||||
"libraryDefault": "Library default",
|
||||
"accountDefault": "Account default",
|
||||
"seriesDefault": "Series default",
|
||||
"episodeSorting": "Episode Sorting",
|
||||
"oldestFirst": "Oldest first",
|
||||
"newestFirst": "Newest first",
|
||||
"keep": "Keep",
|
||||
"allEpisodes": "All episodes",
|
||||
"latestEpisodes": "${count} latest episodes",
|
||||
"latestEpisode": "Latest episode",
|
||||
"episodesAddedPastDays": "Episodes added in the past ${count} days",
|
||||
"deleteAfterPlaying": "Delete Episodes After Playing",
|
||||
"never": "Never",
|
||||
"afterADay": "After a day",
|
||||
"afterAWeek": "After a week",
|
||||
"afterAMonth": "After a month",
|
||||
"onNextRefresh": "On next refresh",
|
||||
"seasons": "Seasons",
|
||||
"show": "Show",
|
||||
"hide": "Hide",
|
||||
"episodeOrdering": "Episode Ordering",
|
||||
"tmdbAiring": "The Movie Database (Aired)",
|
||||
"tvdbAiring": "TheTVDB (Aired)",
|
||||
"tvdbAbsolute": "TheTVDB (Absolute)",
|
||||
"metadataLanguage": "Metadata Language",
|
||||
"useOriginalTitle": "Use Original Title",
|
||||
"preferredAudioLanguage": "Preferred Audio Language",
|
||||
"preferredSubtitleLanguage": "Preferred Subtitle Language",
|
||||
"subtitleMode": "Auto-Select Subtitle Mode",
|
||||
"manuallySelected": "Manually selected",
|
||||
"shownWithForeignAudio": "Shown with foreign audio",
|
||||
"alwaysEnabled": "Always enabled"
|
||||
}
|
||||
}
|
||||
|
||||
+74
-4
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"app": {
|
||||
"title": "Plezy"
|
||||
},
|
||||
},
|
||||
"auth": {
|
||||
"signInWithPlex": "Inicia sesión con Plex",
|
||||
"showQRCode": "Mostrar código QR",
|
||||
@@ -51,7 +51,8 @@
|
||||
"exitConfirmTitle": "¿Salir de la app?",
|
||||
"exitConfirmMessage": "¿Estás seguro de que quieres salir?",
|
||||
"dontAskAgain": "No volver a preguntar",
|
||||
"exit": "Salir"
|
||||
"exit": "Salir",
|
||||
"viewAll": "Ver todo"
|
||||
},
|
||||
"screens": {
|
||||
"licenses": "Licencias",
|
||||
@@ -125,6 +126,8 @@
|
||||
"hardwareDecodingDescription": "Usar aceleración por hardware cuando esté disponible",
|
||||
"bufferSize": "Tamaño del Buffer",
|
||||
"bufferSizeMB": "${size}MB",
|
||||
"bufferSizeAuto": "Auto (Recomendado)",
|
||||
"bufferSizeWarning": "Tu dispositivo tiene ${heap}MB de memoria. Un búfer de ${size}MB puede causar problemas de reproducción.",
|
||||
"subtitleStyling": "Estilo de Subtítulos",
|
||||
"subtitleStylingDescription": "Personalizar la apariencia de los subtítulos",
|
||||
"smallSkipDuration": "Salto pequeño",
|
||||
@@ -266,7 +269,8 @@
|
||||
"confirmDelete": "¿Estás seguro de que quieres eliminar este elemento de tu sistema de archivos?",
|
||||
"deleteMultipleWarning": "Es posible que se eliminen varios elementos.",
|
||||
"mediaDeletedSuccessfully": "Elemento multimedia eliminado con éxito",
|
||||
"mediaFailedToDelete": "Error al eliminar el elemento multimedia"
|
||||
"mediaFailedToDelete": "Error al eliminar el elemento multimedia",
|
||||
"rate": "Calificar"
|
||||
},
|
||||
"accessibility": {
|
||||
"mediaCardMovie": "${title}, película",
|
||||
@@ -320,6 +324,9 @@
|
||||
"versionsButton": "Versiones de video",
|
||||
"pipButton": "Modo PiP (Imagen en Imagen)",
|
||||
"aspectRatioButton": "Relación de aspecto",
|
||||
"ambientLighting": "Iluminación ambiental",
|
||||
"ambientLightingOn": "Activar iluminación ambiental",
|
||||
"ambientLightingOff": "Desactivar iluminación ambiental",
|
||||
"fullscreenButton": "Entrar en pantalla completa",
|
||||
"exitFullscreenButton": "Salir de pantalla completa",
|
||||
"alwaysOnTopButton": "Siempre visible",
|
||||
@@ -336,7 +343,9 @@
|
||||
"unknown": "Ocurrió un error: ${error}"
|
||||
},
|
||||
"chapters": "Capítulos",
|
||||
"noChaptersAvailable": "No hay capítulos disponibles"
|
||||
"noChaptersAvailable": "No hay capítulos disponibles",
|
||||
"queue": "Queue",
|
||||
"noQueueItems": "No items in queue"
|
||||
},
|
||||
"userStatus": {
|
||||
"admin": "Administrador",
|
||||
@@ -824,5 +833,66 @@
|
||||
"launchFailed": "No se pudo abrir el reproductor externo",
|
||||
"appNotInstalled": "${name} no está instalado",
|
||||
"playInExternalPlayer": "Reproducir en reproductor externo"
|
||||
},
|
||||
"metadataEdit": {
|
||||
"editMetadata": "Editar...",
|
||||
"screenTitle": "Editar metadatos",
|
||||
"basicInfo": "Información básica",
|
||||
"artwork": "Artwork",
|
||||
"advancedSettings": "Ajustes avanzados",
|
||||
"title": "Título",
|
||||
"sortTitle": "Título de ordenación",
|
||||
"originalTitle": "Título original",
|
||||
"releaseDate": "Fecha de estreno",
|
||||
"contentRating": "Clasificación de contenido",
|
||||
"studio": "Estudio",
|
||||
"tagline": "Eslogan",
|
||||
"summary": "Resumen",
|
||||
"poster": "Póster",
|
||||
"background": "Fondo",
|
||||
"selectPoster": "Seleccionar póster",
|
||||
"selectBackground": "Seleccionar fondo",
|
||||
"fromUrl": "Desde URL",
|
||||
"uploadFile": "Subir archivo",
|
||||
"enterImageUrl": "Introducir URL de imagen",
|
||||
"imageUrl": "URL de imagen",
|
||||
"metadataUpdated": "Metadatos actualizados",
|
||||
"metadataUpdateFailed": "Error al actualizar los metadatos",
|
||||
"artworkUpdated": "Artwork actualizado",
|
||||
"artworkUpdateFailed": "Error al actualizar el artwork",
|
||||
"noArtworkAvailable": "No hay artwork disponible",
|
||||
"notSet": "No establecido",
|
||||
"libraryDefault": "Predeterminado de biblioteca",
|
||||
"accountDefault": "Predeterminado de cuenta",
|
||||
"seriesDefault": "Predeterminado de serie",
|
||||
"episodeSorting": "Orden de episodios",
|
||||
"oldestFirst": "Más antiguos primero",
|
||||
"newestFirst": "Más recientes primero",
|
||||
"keep": "Conservar",
|
||||
"allEpisodes": "Todos los episodios",
|
||||
"latestEpisodes": "${count} episodios más recientes",
|
||||
"latestEpisode": "Episodio más reciente",
|
||||
"episodesAddedPastDays": "Episodios añadidos en los últimos ${count} días",
|
||||
"deleteAfterPlaying": "Eliminar episodios después de reproducir",
|
||||
"never": "Nunca",
|
||||
"afterADay": "Después de un día",
|
||||
"afterAWeek": "Después de una semana",
|
||||
"afterAMonth": "Después de un mes",
|
||||
"onNextRefresh": "En la próxima actualización",
|
||||
"seasons": "Temporadas",
|
||||
"show": "Mostrar",
|
||||
"hide": "Ocultar",
|
||||
"episodeOrdering": "Orden de episodios",
|
||||
"tmdbAiring": "The Movie Database (Emisión)",
|
||||
"tvdbAiring": "TheTVDB (Emisión)",
|
||||
"tvdbAbsolute": "TheTVDB (Absoluto)",
|
||||
"metadataLanguage": "Idioma de metadatos",
|
||||
"useOriginalTitle": "Usar título original",
|
||||
"preferredAudioLanguage": "Idioma de audio preferido",
|
||||
"preferredSubtitleLanguage": "Idioma de subtítulos preferido",
|
||||
"subtitleMode": "Selección automática de subtítulos",
|
||||
"manuallySelected": "Seleccionado manualmente",
|
||||
"shownWithForeignAudio": "Mostrar con audio extranjero",
|
||||
"alwaysEnabled": "Siempre activado"
|
||||
}
|
||||
}
|
||||
|
||||
+74
-4
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"app": {
|
||||
"title": "Plezy"
|
||||
},
|
||||
},
|
||||
"auth": {
|
||||
"signInWithPlex": "S'inscrire avec Plex",
|
||||
"showQRCode": "Afficher le QR Code",
|
||||
@@ -51,7 +51,8 @@
|
||||
"exitConfirmTitle": "Quitter l'application ?",
|
||||
"exitConfirmMessage": "Êtes-vous sûr de vouloir quitter ?",
|
||||
"dontAskAgain": "Ne plus demander",
|
||||
"exit": "Quitter"
|
||||
"exit": "Quitter",
|
||||
"viewAll": "Tout afficher"
|
||||
},
|
||||
"screens": {
|
||||
"licenses": "Licenses",
|
||||
@@ -125,6 +126,8 @@
|
||||
"hardwareDecodingDescription": "Utilisez l'accélération matérielle lorsqu'elle est disponible.",
|
||||
"bufferSize": "Taille du Buffer",
|
||||
"bufferSizeMB": "${size}MB",
|
||||
"bufferSizeAuto": "Auto (Recommandé)",
|
||||
"bufferSizeWarning": "Votre appareil dispose de ${heap}MB de mémoire. Un tampon de ${size}MB peut causer des problèmes de lecture.",
|
||||
"subtitleStyling": "Stylisation des sous-titres",
|
||||
"subtitleStylingDescription": "Personnaliser l'apparence des sous-titres",
|
||||
"smallSkipDuration": "Small Skip Duration",
|
||||
@@ -266,7 +269,8 @@
|
||||
"confirmDelete": "Êtes-vous sûr de vouloir supprimer cet élément de votre système de fichiers?",
|
||||
"deleteMultipleWarning": "Plusieurs éléments peuvent être supprimés.",
|
||||
"mediaDeletedSuccessfully": "Élément média supprimé avec succès",
|
||||
"mediaFailedToDelete": "Échec de la suppression de l'élément média"
|
||||
"mediaFailedToDelete": "Échec de la suppression de l'élément média",
|
||||
"rate": "Noter"
|
||||
},
|
||||
"accessibility": {
|
||||
"mediaCardMovie": "${title}, film",
|
||||
@@ -320,6 +324,9 @@
|
||||
"versionsButton": "Versions vidéo",
|
||||
"pipButton": "Mode PiP (Picture-in-Picture)",
|
||||
"aspectRatioButton": "Format d'image",
|
||||
"ambientLighting": "Éclairage ambiant",
|
||||
"ambientLightingOn": "Activer l'éclairage ambiant",
|
||||
"ambientLightingOff": "Désactiver l'éclairage ambiant",
|
||||
"fullscreenButton": "Passer en mode plein écran",
|
||||
"exitFullscreenButton": "Quitter le mode plein écran",
|
||||
"alwaysOnTopButton": "Always on top",
|
||||
@@ -336,7 +343,9 @@
|
||||
"unknown": "Une erreur s'est produite : ${error}"
|
||||
},
|
||||
"chapters": "Chapitres",
|
||||
"noChaptersAvailable": "Aucun chapitre disponible"
|
||||
"noChaptersAvailable": "Aucun chapitre disponible",
|
||||
"queue": "Queue",
|
||||
"noQueueItems": "No items in queue"
|
||||
},
|
||||
"userStatus": {
|
||||
"admin": "Admin",
|
||||
@@ -824,5 +833,66 @@
|
||||
"launchFailed": "Impossible d'ouvrir le lecteur externe",
|
||||
"appNotInstalled": "${name} n'est pas installé",
|
||||
"playInExternalPlayer": "Lire dans un lecteur externe"
|
||||
},
|
||||
"metadataEdit": {
|
||||
"editMetadata": "Modifier...",
|
||||
"screenTitle": "Modifier les métadonnées",
|
||||
"basicInfo": "Informations de base",
|
||||
"artwork": "Artwork",
|
||||
"advancedSettings": "Paramètres avancés",
|
||||
"title": "Titre",
|
||||
"sortTitle": "Titre de tri",
|
||||
"originalTitle": "Titre original",
|
||||
"releaseDate": "Date de sortie",
|
||||
"contentRating": "Classification",
|
||||
"studio": "Studio",
|
||||
"tagline": "Slogan",
|
||||
"summary": "Résumé",
|
||||
"poster": "Affiche",
|
||||
"background": "Arrière-plan",
|
||||
"selectPoster": "Sélectionner l'affiche",
|
||||
"selectBackground": "Sélectionner l'arrière-plan",
|
||||
"fromUrl": "Depuis une URL",
|
||||
"uploadFile": "Importer un fichier",
|
||||
"enterImageUrl": "Entrer l'URL de l'image",
|
||||
"imageUrl": "URL de l'image",
|
||||
"metadataUpdated": "Métadonnées mises à jour",
|
||||
"metadataUpdateFailed": "Échec de la mise à jour des métadonnées",
|
||||
"artworkUpdated": "Artwork mis à jour",
|
||||
"artworkUpdateFailed": "Échec de la mise à jour de l'artwork",
|
||||
"noArtworkAvailable": "Aucun artwork disponible",
|
||||
"notSet": "Non défini",
|
||||
"libraryDefault": "Par défaut de la bibliothèque",
|
||||
"accountDefault": "Par défaut du compte",
|
||||
"seriesDefault": "Par défaut de la série",
|
||||
"episodeSorting": "Tri des épisodes",
|
||||
"oldestFirst": "Plus anciens en premier",
|
||||
"newestFirst": "Plus récents en premier",
|
||||
"keep": "Conserver",
|
||||
"allEpisodes": "Tous les épisodes",
|
||||
"latestEpisodes": "${count} derniers épisodes",
|
||||
"latestEpisode": "Dernier épisode",
|
||||
"episodesAddedPastDays": "Épisodes ajoutés ces ${count} derniers jours",
|
||||
"deleteAfterPlaying": "Supprimer les épisodes après lecture",
|
||||
"never": "Jamais",
|
||||
"afterADay": "Après un jour",
|
||||
"afterAWeek": "Après une semaine",
|
||||
"afterAMonth": "Après un mois",
|
||||
"onNextRefresh": "Au prochain rafraîchissement",
|
||||
"seasons": "Saisons",
|
||||
"show": "Afficher",
|
||||
"hide": "Masquer",
|
||||
"episodeOrdering": "Ordre des épisodes",
|
||||
"tmdbAiring": "The Movie Database (Diffusion)",
|
||||
"tvdbAiring": "TheTVDB (Diffusion)",
|
||||
"tvdbAbsolute": "TheTVDB (Absolu)",
|
||||
"metadataLanguage": "Langue des métadonnées",
|
||||
"useOriginalTitle": "Utiliser le titre original",
|
||||
"preferredAudioLanguage": "Langue audio préférée",
|
||||
"preferredSubtitleLanguage": "Langue de sous-titres préférée",
|
||||
"subtitleMode": "Sélection automatique des sous-titres",
|
||||
"manuallySelected": "Sélectionné manuellement",
|
||||
"shownWithForeignAudio": "Affichés avec audio étranger",
|
||||
"alwaysEnabled": "Toujours activé"
|
||||
}
|
||||
}
|
||||
|
||||
+74
-4
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"app": {
|
||||
"title": "Plezy"
|
||||
},
|
||||
},
|
||||
"auth": {
|
||||
"signInWithPlex": "Accedi con Plex",
|
||||
"showQRCode": "Mostra QR Code",
|
||||
@@ -51,7 +51,8 @@
|
||||
"exitConfirmTitle": "Uscire dall'app?",
|
||||
"exitConfirmMessage": "Sei sicuro di voler uscire?",
|
||||
"dontAskAgain": "Non chiedere più",
|
||||
"exit": "Esci"
|
||||
"exit": "Esci",
|
||||
"viewAll": "Mostra tutto"
|
||||
},
|
||||
"screens": {
|
||||
"licenses": "Licenze",
|
||||
@@ -125,6 +126,8 @@
|
||||
"hardwareDecodingDescription": "Utilizza l'accelerazione hardware quando disponibile",
|
||||
"bufferSize": "Dimensione buffer",
|
||||
"bufferSizeMB": "${size}MB",
|
||||
"bufferSizeAuto": "Auto (Consigliato)",
|
||||
"bufferSizeWarning": "Il tuo dispositivo ha ${heap}MB di memoria. Un buffer di ${size}MB potrebbe causare problemi di riproduzione.",
|
||||
"subtitleStyling": "Stile sottotitoli",
|
||||
"subtitleStylingDescription": "Personalizza l'aspetto dei sottotitoli",
|
||||
"smallSkipDuration": "Durata skip breve",
|
||||
@@ -266,7 +269,8 @@
|
||||
"confirmDelete": "Sei sicuro di voler eliminare questo elemento dal tuo filesystem?",
|
||||
"deleteMultipleWarning": "Potrebbero essere eliminati più elementi.",
|
||||
"mediaDeletedSuccessfully": "Elemento multimediale eliminato con successo",
|
||||
"mediaFailedToDelete": "Impossibile eliminare l'elemento multimediale"
|
||||
"mediaFailedToDelete": "Impossibile eliminare l'elemento multimediale",
|
||||
"rate": "Valuta"
|
||||
},
|
||||
"accessibility": {
|
||||
"mediaCardMovie": "${title}, film",
|
||||
@@ -320,6 +324,9 @@
|
||||
"versionsButton": "Versioni video",
|
||||
"pipButton": "Modalità Picture-in-Picture",
|
||||
"aspectRatioButton": "Proporzioni",
|
||||
"ambientLighting": "Illuminazione ambientale",
|
||||
"ambientLightingOn": "Attiva illuminazione ambientale",
|
||||
"ambientLightingOff": "Disattiva illuminazione ambientale",
|
||||
"fullscreenButton": "Attiva schermo intero",
|
||||
"exitFullscreenButton": "Esci da schermo intero",
|
||||
"alwaysOnTopButton": "Sempre in primo piano",
|
||||
@@ -336,7 +343,9 @@
|
||||
"unknown": "Si è verificato un errore: ${error}"
|
||||
},
|
||||
"chapters": "Capitoli",
|
||||
"noChaptersAvailable": "Nessun capitolo disponibile"
|
||||
"noChaptersAvailable": "Nessun capitolo disponibile",
|
||||
"queue": "Queue",
|
||||
"noQueueItems": "No items in queue"
|
||||
},
|
||||
"userStatus": {
|
||||
"admin": "Admin",
|
||||
@@ -824,5 +833,66 @@
|
||||
"launchFailed": "Impossibile aprire il lettore esterno",
|
||||
"appNotInstalled": "${name} non è installato",
|
||||
"playInExternalPlayer": "Riproduci in lettore esterno"
|
||||
},
|
||||
"metadataEdit": {
|
||||
"editMetadata": "Modifica...",
|
||||
"screenTitle": "Modifica metadati",
|
||||
"basicInfo": "Informazioni di base",
|
||||
"artwork": "Artwork",
|
||||
"advancedSettings": "Impostazioni avanzate",
|
||||
"title": "Titolo",
|
||||
"sortTitle": "Titolo di ordinamento",
|
||||
"originalTitle": "Titolo originale",
|
||||
"releaseDate": "Data di uscita",
|
||||
"contentRating": "Classificazione",
|
||||
"studio": "Studio",
|
||||
"tagline": "Tagline",
|
||||
"summary": "Trama",
|
||||
"poster": "Poster",
|
||||
"background": "Sfondo",
|
||||
"selectPoster": "Seleziona poster",
|
||||
"selectBackground": "Seleziona sfondo",
|
||||
"fromUrl": "Da URL",
|
||||
"uploadFile": "Carica file",
|
||||
"enterImageUrl": "Inserisci URL immagine",
|
||||
"imageUrl": "URL immagine",
|
||||
"metadataUpdated": "Metadati aggiornati",
|
||||
"metadataUpdateFailed": "Aggiornamento metadati non riuscito",
|
||||
"artworkUpdated": "Artwork aggiornato",
|
||||
"artworkUpdateFailed": "Aggiornamento artwork non riuscito",
|
||||
"noArtworkAvailable": "Nessun artwork disponibile",
|
||||
"notSet": "Non impostato",
|
||||
"libraryDefault": "Predefinito libreria",
|
||||
"accountDefault": "Predefinito account",
|
||||
"seriesDefault": "Predefinito serie",
|
||||
"episodeSorting": "Ordinamento episodi",
|
||||
"oldestFirst": "Più vecchi prima",
|
||||
"newestFirst": "Più recenti prima",
|
||||
"keep": "Conserva",
|
||||
"allEpisodes": "Tutti gli episodi",
|
||||
"latestEpisodes": "${count} episodi più recenti",
|
||||
"latestEpisode": "Episodio più recente",
|
||||
"episodesAddedPastDays": "Episodi aggiunti negli ultimi ${count} giorni",
|
||||
"deleteAfterPlaying": "Elimina episodi dopo la riproduzione",
|
||||
"never": "Mai",
|
||||
"afterADay": "Dopo un giorno",
|
||||
"afterAWeek": "Dopo una settimana",
|
||||
"afterAMonth": "Dopo un mese",
|
||||
"onNextRefresh": "Al prossimo aggiornamento",
|
||||
"seasons": "Stagioni",
|
||||
"show": "Mostra",
|
||||
"hide": "Nascondi",
|
||||
"episodeOrdering": "Ordine episodi",
|
||||
"tmdbAiring": "The Movie Database (In onda)",
|
||||
"tvdbAiring": "TheTVDB (In onda)",
|
||||
"tvdbAbsolute": "TheTVDB (Assoluto)",
|
||||
"metadataLanguage": "Lingua metadati",
|
||||
"useOriginalTitle": "Usa titolo originale",
|
||||
"preferredAudioLanguage": "Lingua audio preferita",
|
||||
"preferredSubtitleLanguage": "Lingua sottotitoli preferita",
|
||||
"subtitleMode": "Selezione automatica sottotitoli",
|
||||
"manuallySelected": "Selezionato manualmente",
|
||||
"shownWithForeignAudio": "Mostrati con audio straniero",
|
||||
"alwaysEnabled": "Sempre attivo"
|
||||
}
|
||||
}
|
||||
|
||||
+74
-4
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"app": {
|
||||
"title": "Plezy"
|
||||
},
|
||||
},
|
||||
"auth": {
|
||||
"signInWithPlex": "Plex 계정으로 로그인",
|
||||
"showQRCode": "QR 코드",
|
||||
@@ -51,7 +51,8 @@
|
||||
"exitConfirmTitle": "앱을 종료하시겠습니까?",
|
||||
"exitConfirmMessage": "정말 종료하시겠습니까?",
|
||||
"dontAskAgain": "다시 묻지 않기",
|
||||
"exit": "종료"
|
||||
"exit": "종료",
|
||||
"viewAll": "모두 보기"
|
||||
},
|
||||
"screens": {
|
||||
"licenses": "라이선스",
|
||||
@@ -125,6 +126,8 @@
|
||||
"hardwareDecodingDescription": "가능한 경우 하드웨어 가속을 사용합니다",
|
||||
"bufferSize": "버퍼 크기",
|
||||
"bufferSizeMB": "${size}MB",
|
||||
"bufferSizeAuto": "자동 (권장)",
|
||||
"bufferSizeWarning": "기기 메모리가 ${heap}MB입니다. ${size}MB 버퍼는 재생 문제를 일으킬 수 있습니다.",
|
||||
"subtitleStyling": "자막 스타일",
|
||||
"subtitleStylingDescription": "자막의 외형을 사용자 설정",
|
||||
"smallSkipDuration": "짧은 건너뛰기 시간",
|
||||
@@ -266,7 +269,8 @@
|
||||
"confirmDelete": "파일 시스템에서 이 항목을 삭제하시겠습니까?",
|
||||
"deleteMultipleWarning": "여러 항목이 삭제될 수 있습니다.",
|
||||
"mediaDeletedSuccessfully": "미디어 항목이 성공적으로 삭제되었습니다",
|
||||
"mediaFailedToDelete": "미디어 항목 삭제 실패"
|
||||
"mediaFailedToDelete": "미디어 항목 삭제 실패",
|
||||
"rate": "평가"
|
||||
},
|
||||
"accessibility": {
|
||||
"mediaCardMovie": "${title}, 영화",
|
||||
@@ -320,6 +324,9 @@
|
||||
"versionsButton": "동영상 버전",
|
||||
"pipButton": "픽처 인 픽처 모드",
|
||||
"aspectRatioButton": "화면비율",
|
||||
"ambientLighting": "주변 조명",
|
||||
"ambientLightingOn": "주변 조명 켜기",
|
||||
"ambientLightingOff": "주변 조명 끄기",
|
||||
"fullscreenButton": "전체화면",
|
||||
"exitFullscreenButton": "전체화면 종료",
|
||||
"alwaysOnTopButton": "창 최상위 고정",
|
||||
@@ -336,7 +343,9 @@
|
||||
"unknown": "오류가 발생했습니다: ${error}"
|
||||
},
|
||||
"chapters": "챕터",
|
||||
"noChaptersAvailable": "사용 가능한 챕터가 없습니다"
|
||||
"noChaptersAvailable": "사용 가능한 챕터가 없습니다",
|
||||
"queue": "Queue",
|
||||
"noQueueItems": "No items in queue"
|
||||
},
|
||||
"userStatus": {
|
||||
"admin": "관리자",
|
||||
@@ -824,5 +833,66 @@
|
||||
"launchFailed": "외부 플레이어를 열 수 없습니다",
|
||||
"appNotInstalled": "${name}이(가) 설치되어 있지 않습니다",
|
||||
"playInExternalPlayer": "외부 플레이어에서 재생"
|
||||
},
|
||||
"metadataEdit": {
|
||||
"editMetadata": "편집...",
|
||||
"screenTitle": "메타데이터 편집",
|
||||
"basicInfo": "기본 정보",
|
||||
"artwork": "아트워크",
|
||||
"advancedSettings": "고급 설정",
|
||||
"title": "제목",
|
||||
"sortTitle": "정렬 제목",
|
||||
"originalTitle": "원제",
|
||||
"releaseDate": "출시일",
|
||||
"contentRating": "콘텐츠 등급",
|
||||
"studio": "스튜디오",
|
||||
"tagline": "태그라인",
|
||||
"summary": "줄거리",
|
||||
"poster": "포스터",
|
||||
"background": "배경",
|
||||
"selectPoster": "포스터 선택",
|
||||
"selectBackground": "배경 선택",
|
||||
"fromUrl": "URL에서",
|
||||
"uploadFile": "파일 업로드",
|
||||
"enterImageUrl": "이미지 URL 입력",
|
||||
"imageUrl": "이미지 URL",
|
||||
"metadataUpdated": "메타데이터가 업데이트되었습니다",
|
||||
"metadataUpdateFailed": "메타데이터 업데이트 실패",
|
||||
"artworkUpdated": "아트워크가 업데이트되었습니다",
|
||||
"artworkUpdateFailed": "아트워크 업데이트 실패",
|
||||
"noArtworkAvailable": "사용 가능한 아트워크 없음",
|
||||
"notSet": "설정되지 않음",
|
||||
"libraryDefault": "라이브러리 기본값",
|
||||
"accountDefault": "계정 기본값",
|
||||
"seriesDefault": "시리즈 기본값",
|
||||
"episodeSorting": "에피소드 정렬",
|
||||
"oldestFirst": "오래된 순",
|
||||
"newestFirst": "최신 순",
|
||||
"keep": "유지",
|
||||
"allEpisodes": "모든 에피소드",
|
||||
"latestEpisodes": "최신 에피소드 ${count}개",
|
||||
"latestEpisode": "최신 에피소드",
|
||||
"episodesAddedPastDays": "최근 ${count}일 내 추가된 에피소드",
|
||||
"deleteAfterPlaying": "재생 후 에피소드 삭제",
|
||||
"never": "안 함",
|
||||
"afterADay": "하루 후",
|
||||
"afterAWeek": "일주일 후",
|
||||
"afterAMonth": "한 달 후",
|
||||
"onNextRefresh": "다음 새로고침 시",
|
||||
"seasons": "시즌",
|
||||
"show": "표시",
|
||||
"hide": "숨기기",
|
||||
"episodeOrdering": "에피소드 순서",
|
||||
"tmdbAiring": "The Movie Database (방영순)",
|
||||
"tvdbAiring": "TheTVDB (방영순)",
|
||||
"tvdbAbsolute": "TheTVDB (절대순)",
|
||||
"metadataLanguage": "메타데이터 언어",
|
||||
"useOriginalTitle": "원제 사용",
|
||||
"preferredAudioLanguage": "선호 오디오 언어",
|
||||
"preferredSubtitleLanguage": "선호 자막 언어",
|
||||
"subtitleMode": "자막 자동 선택 모드",
|
||||
"manuallySelected": "수동 선택",
|
||||
"shownWithForeignAudio": "외국어 오디오 시 표시",
|
||||
"alwaysEnabled": "항상 활성화"
|
||||
}
|
||||
}
|
||||
|
||||
+74
-4
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"app": {
|
||||
"title": "Plezy"
|
||||
},
|
||||
},
|
||||
"auth": {
|
||||
"signInWithPlex": "Inloggen met Plex",
|
||||
"showQRCode": "Toon QR-code",
|
||||
@@ -51,7 +51,8 @@
|
||||
"exitConfirmTitle": "App afsluiten?",
|
||||
"exitConfirmMessage": "Weet je zeker dat je wilt afsluiten?",
|
||||
"dontAskAgain": "Niet meer vragen",
|
||||
"exit": "Afsluiten"
|
||||
"exit": "Afsluiten",
|
||||
"viewAll": "Alles weergeven"
|
||||
},
|
||||
"screens": {
|
||||
"licenses": "Licenties",
|
||||
@@ -125,6 +126,8 @@
|
||||
"hardwareDecodingDescription": "Gebruik hardware versnelling indien beschikbaar",
|
||||
"bufferSize": "Buffer grootte",
|
||||
"bufferSizeMB": "${size}MB",
|
||||
"bufferSizeAuto": "Auto (Aanbevolen)",
|
||||
"bufferSizeWarning": "Je apparaat heeft ${heap}MB geheugen. Een buffer van ${size}MB kan afspeelproblemen veroorzaken.",
|
||||
"subtitleStyling": "Ondertitel opmaak",
|
||||
"subtitleStylingDescription": "Pas ondertitel uiterlijk aan",
|
||||
"smallSkipDuration": "Korte skip duur",
|
||||
@@ -266,7 +269,8 @@
|
||||
"confirmDelete": "Weet je zeker dat je dit item van je bestandssysteem wilt verwijderen?",
|
||||
"deleteMultipleWarning": "Meerdere items kunnen worden verwijderd.",
|
||||
"mediaDeletedSuccessfully": "Media-item succesvol verwijderd",
|
||||
"mediaFailedToDelete": "Verwijderen van media-item mislukt"
|
||||
"mediaFailedToDelete": "Verwijderen van media-item mislukt",
|
||||
"rate": "Beoordelen"
|
||||
},
|
||||
"accessibility": {
|
||||
"mediaCardMovie": "${title}, film",
|
||||
@@ -320,6 +324,9 @@
|
||||
"versionsButton": "Videoversies",
|
||||
"pipButton": "Beeld-in-beeld modus",
|
||||
"aspectRatioButton": "Beeldverhouding",
|
||||
"ambientLighting": "Omgevingsverlichting",
|
||||
"ambientLightingOn": "Omgevingsverlichting inschakelen",
|
||||
"ambientLightingOff": "Omgevingsverlichting uitschakelen",
|
||||
"fullscreenButton": "Volledig scherm activeren",
|
||||
"exitFullscreenButton": "Volledig scherm verlaten",
|
||||
"alwaysOnTopButton": "Altijd bovenop",
|
||||
@@ -336,7 +343,9 @@
|
||||
"unknown": "Er is een fout opgetreden: ${error}"
|
||||
},
|
||||
"chapters": "Hoofdstukken",
|
||||
"noChaptersAvailable": "Geen hoofdstukken beschikbaar"
|
||||
"noChaptersAvailable": "Geen hoofdstukken beschikbaar",
|
||||
"queue": "Queue",
|
||||
"noQueueItems": "No items in queue"
|
||||
},
|
||||
"userStatus": {
|
||||
"admin": "Beheerder",
|
||||
@@ -824,5 +833,66 @@
|
||||
"launchFailed": "Kan externe speler niet openen",
|
||||
"appNotInstalled": "${name} is niet geïnstalleerd",
|
||||
"playInExternalPlayer": "Afspelen in externe speler"
|
||||
},
|
||||
"metadataEdit": {
|
||||
"editMetadata": "Bewerken...",
|
||||
"screenTitle": "Metadata bewerken",
|
||||
"basicInfo": "Basisinformatie",
|
||||
"artwork": "Artwork",
|
||||
"advancedSettings": "Geavanceerde instellingen",
|
||||
"title": "Titel",
|
||||
"sortTitle": "Sorteertitel",
|
||||
"originalTitle": "Oorspronkelijke titel",
|
||||
"releaseDate": "Releasedatum",
|
||||
"contentRating": "Leeftijdsclassificatie",
|
||||
"studio": "Studio",
|
||||
"tagline": "Tagline",
|
||||
"summary": "Samenvatting",
|
||||
"poster": "Poster",
|
||||
"background": "Achtergrond",
|
||||
"selectPoster": "Poster selecteren",
|
||||
"selectBackground": "Achtergrond selecteren",
|
||||
"fromUrl": "Vanaf URL",
|
||||
"uploadFile": "Bestand uploaden",
|
||||
"enterImageUrl": "Voer afbeeldings-URL in",
|
||||
"imageUrl": "Afbeeldings-URL",
|
||||
"metadataUpdated": "Metadata bijgewerkt",
|
||||
"metadataUpdateFailed": "Metadata bijwerken mislukt",
|
||||
"artworkUpdated": "Artwork bijgewerkt",
|
||||
"artworkUpdateFailed": "Artwork bijwerken mislukt",
|
||||
"noArtworkAvailable": "Geen artwork beschikbaar",
|
||||
"notSet": "Niet ingesteld",
|
||||
"libraryDefault": "Bibliotheekstandaard",
|
||||
"accountDefault": "Accountstandaard",
|
||||
"seriesDefault": "Seriestandaard",
|
||||
"episodeSorting": "Afleveringen sorteren",
|
||||
"oldestFirst": "Oudste eerst",
|
||||
"newestFirst": "Nieuwste eerst",
|
||||
"keep": "Bewaren",
|
||||
"allEpisodes": "Alle afleveringen",
|
||||
"latestEpisodes": "${count} nieuwste afleveringen",
|
||||
"latestEpisode": "Nieuwste aflevering",
|
||||
"episodesAddedPastDays": "Afleveringen toegevoegd in de afgelopen ${count} dagen",
|
||||
"deleteAfterPlaying": "Afleveringen verwijderen na afspelen",
|
||||
"never": "Nooit",
|
||||
"afterADay": "Na een dag",
|
||||
"afterAWeek": "Na een week",
|
||||
"afterAMonth": "Na een maand",
|
||||
"onNextRefresh": "Bij volgende verversing",
|
||||
"seasons": "Seizoenen",
|
||||
"show": "Tonen",
|
||||
"hide": "Verbergen",
|
||||
"episodeOrdering": "Afleveringsvolgorde",
|
||||
"tmdbAiring": "The Movie Database (Uitgezonden)",
|
||||
"tvdbAiring": "TheTVDB (Uitgezonden)",
|
||||
"tvdbAbsolute": "TheTVDB (Absoluut)",
|
||||
"metadataLanguage": "Metadatataal",
|
||||
"useOriginalTitle": "Oorspronkelijke titel gebruiken",
|
||||
"preferredAudioLanguage": "Voorkeurstaal audio",
|
||||
"preferredSubtitleLanguage": "Voorkeurstaal ondertiteling",
|
||||
"subtitleMode": "Automatische ondertitelselectie",
|
||||
"manuallySelected": "Handmatig geselecteerd",
|
||||
"shownWithForeignAudio": "Weergeven bij anderstalig geluid",
|
||||
"alwaysEnabled": "Altijd ingeschakeld"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,9 +4,9 @@
|
||||
/// To regenerate, run: `dart run slang`
|
||||
///
|
||||
/// Locales: 9
|
||||
/// Strings: 6642 (738 per locale)
|
||||
/// Strings: 7254 (806 per locale)
|
||||
///
|
||||
/// Built on 2026-02-16 at 00:20 UTC
|
||||
/// Built on 2026-02-23 at 04:30 UTC
|
||||
|
||||
// coverage:ignore-file
|
||||
// ignore_for_file: type=lint, unused_import
|
||||
|
||||
+148
-2
@@ -74,6 +74,7 @@ class TranslationsDe with BaseTranslations<AppLocale, Translations> implements T
|
||||
@override late final _TranslationsCompanionRemoteDe companionRemote = _TranslationsCompanionRemoteDe._(_root);
|
||||
@override late final _TranslationsVideoSettingsDe videoSettings = _TranslationsVideoSettingsDe._(_root);
|
||||
@override late final _TranslationsExternalPlayerDe externalPlayer = _TranslationsExternalPlayerDe._(_root);
|
||||
@override late final _TranslationsMetadataEditDe metadataEdit = _TranslationsMetadataEditDe._(_root);
|
||||
}
|
||||
|
||||
// Path: app
|
||||
@@ -149,6 +150,7 @@ class _TranslationsCommonDe implements TranslationsCommonEn {
|
||||
@override String get exitConfirmMessage => 'Möchtest du die App wirklich beenden?';
|
||||
@override String get dontAskAgain => 'Nicht erneut fragen';
|
||||
@override String get exit => 'Beenden';
|
||||
@override String get viewAll => 'Alle anzeigen';
|
||||
}
|
||||
|
||||
// Path: screens
|
||||
@@ -243,6 +245,8 @@ class _TranslationsSettingsDe implements TranslationsSettingsEn {
|
||||
@override String get hardwareDecodingDescription => 'Hardwarebeschleunigung verwenden, sofern verfügbar';
|
||||
@override String get bufferSize => 'Puffergröße';
|
||||
@override String bufferSizeMB({required Object size}) => '${size}MB';
|
||||
@override String get bufferSizeAuto => 'Auto (Empfohlen)';
|
||||
@override String bufferSizeWarning({required Object heap, required Object size}) => 'Ihr Gerät hat ${heap}MB Speicher. Ein ${size}MB-Puffer kann Wiedergabeprobleme verursachen.';
|
||||
@override String get subtitleStyling => 'Untertitel-Stil';
|
||||
@override String get subtitleStylingDescription => 'Aussehen von Untertiteln anpassen';
|
||||
@override String get smallSkipDuration => 'Kleine Sprungdauer';
|
||||
@@ -400,6 +404,7 @@ class _TranslationsMediaMenuDe implements TranslationsMediaMenuEn {
|
||||
@override String get deleteMultipleWarning => 'Mehrere Elemente können gelöscht werden.';
|
||||
@override String get mediaDeletedSuccessfully => 'Medienelement erfolgreich gelöscht';
|
||||
@override String get mediaFailedToDelete => 'Löschen des Medienelements fehlgeschlagen';
|
||||
@override String get rate => 'Bewerten';
|
||||
}
|
||||
|
||||
// Path: accessibility
|
||||
@@ -474,6 +479,9 @@ class _TranslationsVideoControlsDe implements TranslationsVideoControlsEn {
|
||||
@override String get versionsButton => 'Videoversionen';
|
||||
@override String get pipButton => 'Bild-in-Bild Modus';
|
||||
@override String get aspectRatioButton => 'Seitenverhältnis';
|
||||
@override String get ambientLighting => 'Umgebungsbeleuchtung';
|
||||
@override String get ambientLightingOn => 'Umgebungsbeleuchtung aktivieren';
|
||||
@override String get ambientLightingOff => 'Umgebungsbeleuchtung deaktivieren';
|
||||
@override String get fullscreenButton => 'Vollbild aktivieren';
|
||||
@override String get exitFullscreenButton => 'Vollbild verlassen';
|
||||
@override String get alwaysOnTopButton => 'Immer im Vordergrund';
|
||||
@@ -485,6 +493,8 @@ class _TranslationsVideoControlsDe implements TranslationsVideoControlsEn {
|
||||
@override late final _TranslationsVideoControlsPipErrorsDe pipErrors = _TranslationsVideoControlsPipErrorsDe._(_root);
|
||||
@override String get chapters => 'Kapitel';
|
||||
@override String get noChaptersAvailable => 'Keine Kapitel verfügbar';
|
||||
@override String get queue => 'Queue';
|
||||
@override String get noQueueItems => 'No items in queue';
|
||||
}
|
||||
|
||||
// Path: userStatus
|
||||
@@ -1043,6 +1053,74 @@ class _TranslationsExternalPlayerDe implements TranslationsExternalPlayerEn {
|
||||
@override String get playInExternalPlayer => 'In externem Player abspielen';
|
||||
}
|
||||
|
||||
// Path: metadataEdit
|
||||
class _TranslationsMetadataEditDe implements TranslationsMetadataEditEn {
|
||||
_TranslationsMetadataEditDe._(this._root);
|
||||
|
||||
final TranslationsDe _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get editMetadata => 'Bearbeiten...';
|
||||
@override String get screenTitle => 'Metadaten bearbeiten';
|
||||
@override String get basicInfo => 'Grundlegende Infos';
|
||||
@override String get artwork => 'Artwork';
|
||||
@override String get advancedSettings => 'Erweiterte Einstellungen';
|
||||
@override String get title => 'Titel';
|
||||
@override String get sortTitle => 'Sortiertitel';
|
||||
@override String get originalTitle => 'Originaltitel';
|
||||
@override String get releaseDate => 'Erscheinungsdatum';
|
||||
@override String get contentRating => 'Altersfreigabe';
|
||||
@override String get studio => 'Studio';
|
||||
@override String get tagline => 'Tagline';
|
||||
@override String get summary => 'Zusammenfassung';
|
||||
@override String get poster => 'Poster';
|
||||
@override String get background => 'Hintergrund';
|
||||
@override String get selectPoster => 'Poster auswählen';
|
||||
@override String get selectBackground => 'Hintergrund auswählen';
|
||||
@override String get fromUrl => 'Von URL';
|
||||
@override String get uploadFile => 'Datei hochladen';
|
||||
@override String get enterImageUrl => 'Bild-URL eingeben';
|
||||
@override String get imageUrl => 'Bild-URL';
|
||||
@override String get metadataUpdated => 'Metadaten aktualisiert';
|
||||
@override String get metadataUpdateFailed => 'Metadaten konnten nicht aktualisiert werden';
|
||||
@override String get artworkUpdated => 'Artwork aktualisiert';
|
||||
@override String get artworkUpdateFailed => 'Artwork konnte nicht aktualisiert werden';
|
||||
@override String get noArtworkAvailable => 'Kein Artwork verfügbar';
|
||||
@override String get notSet => 'Nicht festgelegt';
|
||||
@override String get libraryDefault => 'Bibliotheksstandard';
|
||||
@override String get accountDefault => 'Kontostandard';
|
||||
@override String get seriesDefault => 'Serienstandard';
|
||||
@override String get episodeSorting => 'Episodensortierung';
|
||||
@override String get oldestFirst => 'Älteste zuerst';
|
||||
@override String get newestFirst => 'Neueste zuerst';
|
||||
@override String get keep => 'Behalten';
|
||||
@override String get allEpisodes => 'Alle Episoden';
|
||||
@override String latestEpisodes({required Object count}) => '${count} neueste Episoden';
|
||||
@override String get latestEpisode => 'Neueste Episode';
|
||||
@override String episodesAddedPastDays({required Object count}) => 'Episoden der letzten ${count} Tage';
|
||||
@override String get deleteAfterPlaying => 'Episoden nach Wiedergabe löschen';
|
||||
@override String get never => 'Nie';
|
||||
@override String get afterADay => 'Nach einem Tag';
|
||||
@override String get afterAWeek => 'Nach einer Woche';
|
||||
@override String get afterAMonth => 'Nach einem Monat';
|
||||
@override String get onNextRefresh => 'Bei nächster Aktualisierung';
|
||||
@override String get seasons => 'Staffeln';
|
||||
@override String get show => 'Anzeigen';
|
||||
@override String get hide => 'Ausblenden';
|
||||
@override String get episodeOrdering => 'Episodenreihenfolge';
|
||||
@override String get tmdbAiring => 'The Movie Database (Ausgestrahlt)';
|
||||
@override String get tvdbAiring => 'TheTVDB (Ausgestrahlt)';
|
||||
@override String get tvdbAbsolute => 'TheTVDB (Absolut)';
|
||||
@override String get metadataLanguage => 'Metadaten-Sprache';
|
||||
@override String get useOriginalTitle => 'Originaltitel verwenden';
|
||||
@override String get preferredAudioLanguage => 'Bevorzugte Audiosprache';
|
||||
@override String get preferredSubtitleLanguage => 'Bevorzugte Untertitelsprache';
|
||||
@override String get subtitleMode => 'Automatische Untertitelauswahl';
|
||||
@override String get manuallySelected => 'Manuell ausgewählt';
|
||||
@override String get shownWithForeignAudio => 'Bei fremdsprachigem Audio anzeigen';
|
||||
@override String get alwaysEnabled => 'Immer aktiviert';
|
||||
}
|
||||
|
||||
// Path: hotkeys.actions
|
||||
class _TranslationsHotkeysActionsDe implements TranslationsHotkeysActionsEn {
|
||||
_TranslationsHotkeysActionsDe._(this._root);
|
||||
@@ -1273,6 +1351,7 @@ extension on TranslationsDe {
|
||||
'common.exitConfirmMessage' => 'Möchtest du die App wirklich beenden?',
|
||||
'common.dontAskAgain' => 'Nicht erneut fragen',
|
||||
'common.exit' => 'Beenden',
|
||||
'common.viewAll' => 'Alle anzeigen',
|
||||
'screens.licenses' => 'Lizenzen',
|
||||
'screens.switchProfile' => 'Profil wechseln',
|
||||
'screens.subtitleStyling' => 'Untertitel-Stil',
|
||||
@@ -1340,6 +1419,8 @@ extension on TranslationsDe {
|
||||
'settings.hardwareDecodingDescription' => 'Hardwarebeschleunigung verwenden, sofern verfügbar',
|
||||
'settings.bufferSize' => 'Puffergröße',
|
||||
'settings.bufferSizeMB' => ({required Object size}) => '${size}MB',
|
||||
'settings.bufferSizeAuto' => 'Auto (Empfohlen)',
|
||||
'settings.bufferSizeWarning' => ({required Object heap, required Object size}) => 'Ihr Gerät hat ${heap}MB Speicher. Ein ${size}MB-Puffer kann Wiedergabeprobleme verursachen.',
|
||||
'settings.subtitleStyling' => 'Untertitel-Stil',
|
||||
'settings.subtitleStylingDescription' => 'Aussehen von Untertiteln anpassen',
|
||||
'settings.smallSkipDuration' => 'Kleine Sprungdauer',
|
||||
@@ -1470,6 +1551,7 @@ extension on TranslationsDe {
|
||||
'mediaMenu.deleteMultipleWarning' => 'Mehrere Elemente können gelöscht werden.',
|
||||
'mediaMenu.mediaDeletedSuccessfully' => 'Medienelement erfolgreich gelöscht',
|
||||
'mediaMenu.mediaFailedToDelete' => 'Löschen des Medienelements fehlgeschlagen',
|
||||
'mediaMenu.rate' => 'Bewerten',
|
||||
'accessibility.mediaCardMovie' => ({required Object title}) => '${title}, Film',
|
||||
'accessibility.mediaCardShow' => ({required Object title}) => '${title}, Serie',
|
||||
'accessibility.mediaCardEpisode' => ({required Object title, required Object episodeInfo}) => '${title}, ${episodeInfo}',
|
||||
@@ -1517,6 +1599,9 @@ extension on TranslationsDe {
|
||||
'videoControls.versionsButton' => 'Videoversionen',
|
||||
'videoControls.pipButton' => 'Bild-in-Bild Modus',
|
||||
'videoControls.aspectRatioButton' => 'Seitenverhältnis',
|
||||
'videoControls.ambientLighting' => 'Umgebungsbeleuchtung',
|
||||
'videoControls.ambientLightingOn' => 'Umgebungsbeleuchtung aktivieren',
|
||||
'videoControls.ambientLightingOff' => 'Umgebungsbeleuchtung deaktivieren',
|
||||
'videoControls.fullscreenButton' => 'Vollbild aktivieren',
|
||||
'videoControls.exitFullscreenButton' => 'Vollbild verlassen',
|
||||
'videoControls.alwaysOnTopButton' => 'Immer im Vordergrund',
|
||||
@@ -1532,6 +1617,8 @@ extension on TranslationsDe {
|
||||
'videoControls.pipErrors.unknown' => ({required Object error}) => 'Ein Fehler ist aufgetreten: ${error}',
|
||||
'videoControls.chapters' => 'Kapitel',
|
||||
'videoControls.noChaptersAvailable' => 'Keine Kapitel verfügbar',
|
||||
'videoControls.queue' => 'Queue',
|
||||
'videoControls.noQueueItems' => 'No items in queue',
|
||||
'userStatus.admin' => 'Eigentümer',
|
||||
'userStatus.restricted' => 'Eingeschränkt',
|
||||
'userStatus.protected' => 'Geschützt',
|
||||
@@ -1728,6 +1815,8 @@ extension on TranslationsDe {
|
||||
'liveTv.reloadGuide' => 'Programmführer neu laden',
|
||||
'liveTv.guideReloaded' => 'Programmdaten neu geladen',
|
||||
'liveTv.allChannels' => 'Alle Kanäle',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.now' => 'Jetzt',
|
||||
'liveTv.today' => 'Heute',
|
||||
'liveTv.midnight' => 'Mitternacht',
|
||||
@@ -1737,8 +1826,6 @@ extension on TranslationsDe {
|
||||
'liveTv.evening' => 'Abend',
|
||||
'liveTv.lateNight' => 'Spätnacht',
|
||||
'liveTv.whatsOn' => 'Jetzt im TV',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.watchChannel' => 'Kanal ansehen',
|
||||
'downloads.title' => 'Downloads',
|
||||
'downloads.manage' => 'Verwalten',
|
||||
@@ -1965,6 +2052,65 @@ extension on TranslationsDe {
|
||||
'externalPlayer.launchFailed' => 'Externer Player konnte nicht geöffnet werden',
|
||||
'externalPlayer.appNotInstalled' => ({required Object name}) => '${name} ist nicht installiert',
|
||||
'externalPlayer.playInExternalPlayer' => 'In externem Player abspielen',
|
||||
'metadataEdit.editMetadata' => 'Bearbeiten...',
|
||||
'metadataEdit.screenTitle' => 'Metadaten bearbeiten',
|
||||
'metadataEdit.basicInfo' => 'Grundlegende Infos',
|
||||
'metadataEdit.artwork' => 'Artwork',
|
||||
'metadataEdit.advancedSettings' => 'Erweiterte Einstellungen',
|
||||
'metadataEdit.title' => 'Titel',
|
||||
'metadataEdit.sortTitle' => 'Sortiertitel',
|
||||
'metadataEdit.originalTitle' => 'Originaltitel',
|
||||
'metadataEdit.releaseDate' => 'Erscheinungsdatum',
|
||||
'metadataEdit.contentRating' => 'Altersfreigabe',
|
||||
'metadataEdit.studio' => 'Studio',
|
||||
'metadataEdit.tagline' => 'Tagline',
|
||||
'metadataEdit.summary' => 'Zusammenfassung',
|
||||
'metadataEdit.poster' => 'Poster',
|
||||
'metadataEdit.background' => 'Hintergrund',
|
||||
'metadataEdit.selectPoster' => 'Poster auswählen',
|
||||
'metadataEdit.selectBackground' => 'Hintergrund auswählen',
|
||||
'metadataEdit.fromUrl' => 'Von URL',
|
||||
'metadataEdit.uploadFile' => 'Datei hochladen',
|
||||
'metadataEdit.enterImageUrl' => 'Bild-URL eingeben',
|
||||
'metadataEdit.imageUrl' => 'Bild-URL',
|
||||
'metadataEdit.metadataUpdated' => 'Metadaten aktualisiert',
|
||||
'metadataEdit.metadataUpdateFailed' => 'Metadaten konnten nicht aktualisiert werden',
|
||||
'metadataEdit.artworkUpdated' => 'Artwork aktualisiert',
|
||||
'metadataEdit.artworkUpdateFailed' => 'Artwork konnte nicht aktualisiert werden',
|
||||
'metadataEdit.noArtworkAvailable' => 'Kein Artwork verfügbar',
|
||||
'metadataEdit.notSet' => 'Nicht festgelegt',
|
||||
'metadataEdit.libraryDefault' => 'Bibliotheksstandard',
|
||||
'metadataEdit.accountDefault' => 'Kontostandard',
|
||||
'metadataEdit.seriesDefault' => 'Serienstandard',
|
||||
'metadataEdit.episodeSorting' => 'Episodensortierung',
|
||||
'metadataEdit.oldestFirst' => 'Älteste zuerst',
|
||||
'metadataEdit.newestFirst' => 'Neueste zuerst',
|
||||
'metadataEdit.keep' => 'Behalten',
|
||||
'metadataEdit.allEpisodes' => 'Alle Episoden',
|
||||
'metadataEdit.latestEpisodes' => ({required Object count}) => '${count} neueste Episoden',
|
||||
'metadataEdit.latestEpisode' => 'Neueste Episode',
|
||||
'metadataEdit.episodesAddedPastDays' => ({required Object count}) => 'Episoden der letzten ${count} Tage',
|
||||
'metadataEdit.deleteAfterPlaying' => 'Episoden nach Wiedergabe löschen',
|
||||
'metadataEdit.never' => 'Nie',
|
||||
'metadataEdit.afterADay' => 'Nach einem Tag',
|
||||
'metadataEdit.afterAWeek' => 'Nach einer Woche',
|
||||
'metadataEdit.afterAMonth' => 'Nach einem Monat',
|
||||
'metadataEdit.onNextRefresh' => 'Bei nächster Aktualisierung',
|
||||
'metadataEdit.seasons' => 'Staffeln',
|
||||
'metadataEdit.show' => 'Anzeigen',
|
||||
'metadataEdit.hide' => 'Ausblenden',
|
||||
'metadataEdit.episodeOrdering' => 'Episodenreihenfolge',
|
||||
'metadataEdit.tmdbAiring' => 'The Movie Database (Ausgestrahlt)',
|
||||
'metadataEdit.tvdbAiring' => 'TheTVDB (Ausgestrahlt)',
|
||||
'metadataEdit.tvdbAbsolute' => 'TheTVDB (Absolut)',
|
||||
'metadataEdit.metadataLanguage' => 'Metadaten-Sprache',
|
||||
'metadataEdit.useOriginalTitle' => 'Originaltitel verwenden',
|
||||
'metadataEdit.preferredAudioLanguage' => 'Bevorzugte Audiosprache',
|
||||
'metadataEdit.preferredSubtitleLanguage' => 'Bevorzugte Untertitelsprache',
|
||||
'metadataEdit.subtitleMode' => 'Automatische Untertitelauswahl',
|
||||
'metadataEdit.manuallySelected' => 'Manuell ausgewählt',
|
||||
'metadataEdit.shownWithForeignAudio' => 'Bei fremdsprachigem Audio anzeigen',
|
||||
'metadataEdit.alwaysEnabled' => 'Immer aktiviert',
|
||||
_ => null,
|
||||
};
|
||||
}
|
||||
|
||||
+284
-2
@@ -77,6 +77,7 @@ class Translations with BaseTranslations<AppLocale, Translations> {
|
||||
late final TranslationsCompanionRemoteEn companionRemote = TranslationsCompanionRemoteEn._(_root);
|
||||
late final TranslationsVideoSettingsEn videoSettings = TranslationsVideoSettingsEn._(_root);
|
||||
late final TranslationsExternalPlayerEn externalPlayer = TranslationsExternalPlayerEn._(_root);
|
||||
late final TranslationsMetadataEditEn metadataEdit = TranslationsMetadataEditEn._(_root);
|
||||
}
|
||||
|
||||
// Path: app
|
||||
@@ -248,6 +249,9 @@ class TranslationsCommonEn {
|
||||
|
||||
/// en: 'Exit'
|
||||
String get exit => 'Exit';
|
||||
|
||||
/// en: 'View All'
|
||||
String get viewAll => 'View All';
|
||||
}
|
||||
|
||||
// Path: screens
|
||||
@@ -477,6 +481,12 @@ class TranslationsSettingsEn {
|
||||
/// en: '${size}MB'
|
||||
String bufferSizeMB({required Object size}) => '${size}MB';
|
||||
|
||||
/// en: 'Auto (Recommended)'
|
||||
String get bufferSizeAuto => 'Auto (Recommended)';
|
||||
|
||||
/// en: 'Your device has ${heap}MB of memory. A ${size}MB buffer may cause playback issues.'
|
||||
String bufferSizeWarning({required Object heap, required Object size}) => 'Your device has ${heap}MB of memory. A ${size}MB buffer may cause playback issues.';
|
||||
|
||||
/// en: 'Subtitle Styling'
|
||||
String get subtitleStyling => 'Subtitle Styling';
|
||||
|
||||
@@ -856,6 +866,9 @@ class TranslationsMediaMenuEn {
|
||||
|
||||
/// en: 'Failed to delete media item'
|
||||
String get mediaFailedToDelete => 'Failed to delete media item';
|
||||
|
||||
/// en: 'Rate'
|
||||
String get rate => 'Rate';
|
||||
}
|
||||
|
||||
// Path: accessibility
|
||||
@@ -1025,6 +1038,15 @@ class TranslationsVideoControlsEn {
|
||||
/// en: 'Aspect ratio'
|
||||
String get aspectRatioButton => 'Aspect ratio';
|
||||
|
||||
/// en: 'Ambient lighting'
|
||||
String get ambientLighting => 'Ambient lighting';
|
||||
|
||||
/// en: 'Enable ambient lighting'
|
||||
String get ambientLightingOn => 'Enable ambient lighting';
|
||||
|
||||
/// en: 'Disable ambient lighting'
|
||||
String get ambientLightingOff => 'Disable ambient lighting';
|
||||
|
||||
/// en: 'Enter fullscreen'
|
||||
String get fullscreenButton => 'Enter fullscreen';
|
||||
|
||||
@@ -1056,6 +1078,12 @@ class TranslationsVideoControlsEn {
|
||||
|
||||
/// en: 'No chapters available'
|
||||
String get noChaptersAvailable => 'No chapters available';
|
||||
|
||||
/// en: 'Queue'
|
||||
String get queue => 'Queue';
|
||||
|
||||
/// en: 'No items in queue'
|
||||
String get noQueueItems => 'No items in queue';
|
||||
}
|
||||
|
||||
// Path: userStatus
|
||||
@@ -2304,6 +2332,192 @@ class TranslationsExternalPlayerEn {
|
||||
String get playInExternalPlayer => 'Play in External Player';
|
||||
}
|
||||
|
||||
// Path: metadataEdit
|
||||
class TranslationsMetadataEditEn {
|
||||
TranslationsMetadataEditEn._(this._root);
|
||||
|
||||
final Translations _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
|
||||
/// en: 'Edit...'
|
||||
String get editMetadata => 'Edit...';
|
||||
|
||||
/// en: 'Edit Metadata'
|
||||
String get screenTitle => 'Edit Metadata';
|
||||
|
||||
/// en: 'Basic Info'
|
||||
String get basicInfo => 'Basic Info';
|
||||
|
||||
/// en: 'Artwork'
|
||||
String get artwork => 'Artwork';
|
||||
|
||||
/// en: 'Advanced Settings'
|
||||
String get advancedSettings => 'Advanced Settings';
|
||||
|
||||
/// en: 'Title'
|
||||
String get title => 'Title';
|
||||
|
||||
/// en: 'Sort Title'
|
||||
String get sortTitle => 'Sort Title';
|
||||
|
||||
/// en: 'Original Title'
|
||||
String get originalTitle => 'Original Title';
|
||||
|
||||
/// en: 'Release Date'
|
||||
String get releaseDate => 'Release Date';
|
||||
|
||||
/// en: 'Content Rating'
|
||||
String get contentRating => 'Content Rating';
|
||||
|
||||
/// en: 'Studio'
|
||||
String get studio => 'Studio';
|
||||
|
||||
/// en: 'Tagline'
|
||||
String get tagline => 'Tagline';
|
||||
|
||||
/// en: 'Summary'
|
||||
String get summary => 'Summary';
|
||||
|
||||
/// en: 'Poster'
|
||||
String get poster => 'Poster';
|
||||
|
||||
/// en: 'Background'
|
||||
String get background => 'Background';
|
||||
|
||||
/// en: 'Select Poster'
|
||||
String get selectPoster => 'Select Poster';
|
||||
|
||||
/// en: 'Select Background'
|
||||
String get selectBackground => 'Select Background';
|
||||
|
||||
/// en: 'From URL'
|
||||
String get fromUrl => 'From URL';
|
||||
|
||||
/// en: 'Upload File'
|
||||
String get uploadFile => 'Upload File';
|
||||
|
||||
/// en: 'Enter image URL'
|
||||
String get enterImageUrl => 'Enter image URL';
|
||||
|
||||
/// en: 'Image URL'
|
||||
String get imageUrl => 'Image URL';
|
||||
|
||||
/// en: 'Metadata updated'
|
||||
String get metadataUpdated => 'Metadata updated';
|
||||
|
||||
/// en: 'Failed to update metadata'
|
||||
String get metadataUpdateFailed => 'Failed to update metadata';
|
||||
|
||||
/// en: 'Artwork updated'
|
||||
String get artworkUpdated => 'Artwork updated';
|
||||
|
||||
/// en: 'Failed to update artwork'
|
||||
String get artworkUpdateFailed => 'Failed to update artwork';
|
||||
|
||||
/// en: 'No artwork available'
|
||||
String get noArtworkAvailable => 'No artwork available';
|
||||
|
||||
/// en: 'Not set'
|
||||
String get notSet => 'Not set';
|
||||
|
||||
/// en: 'Library default'
|
||||
String get libraryDefault => 'Library default';
|
||||
|
||||
/// en: 'Account default'
|
||||
String get accountDefault => 'Account default';
|
||||
|
||||
/// en: 'Series default'
|
||||
String get seriesDefault => 'Series default';
|
||||
|
||||
/// en: 'Episode Sorting'
|
||||
String get episodeSorting => 'Episode Sorting';
|
||||
|
||||
/// en: 'Oldest first'
|
||||
String get oldestFirst => 'Oldest first';
|
||||
|
||||
/// en: 'Newest first'
|
||||
String get newestFirst => 'Newest first';
|
||||
|
||||
/// en: 'Keep'
|
||||
String get keep => 'Keep';
|
||||
|
||||
/// en: 'All episodes'
|
||||
String get allEpisodes => 'All episodes';
|
||||
|
||||
/// en: '${count} latest episodes'
|
||||
String latestEpisodes({required Object count}) => '${count} latest episodes';
|
||||
|
||||
/// en: 'Latest episode'
|
||||
String get latestEpisode => 'Latest episode';
|
||||
|
||||
/// en: 'Episodes added in the past ${count} days'
|
||||
String episodesAddedPastDays({required Object count}) => 'Episodes added in the past ${count} days';
|
||||
|
||||
/// en: 'Delete Episodes After Playing'
|
||||
String get deleteAfterPlaying => 'Delete Episodes After Playing';
|
||||
|
||||
/// en: 'Never'
|
||||
String get never => 'Never';
|
||||
|
||||
/// en: 'After a day'
|
||||
String get afterADay => 'After a day';
|
||||
|
||||
/// en: 'After a week'
|
||||
String get afterAWeek => 'After a week';
|
||||
|
||||
/// en: 'After a month'
|
||||
String get afterAMonth => 'After a month';
|
||||
|
||||
/// en: 'On next refresh'
|
||||
String get onNextRefresh => 'On next refresh';
|
||||
|
||||
/// en: 'Seasons'
|
||||
String get seasons => 'Seasons';
|
||||
|
||||
/// en: 'Show'
|
||||
String get show => 'Show';
|
||||
|
||||
/// en: 'Hide'
|
||||
String get hide => 'Hide';
|
||||
|
||||
/// en: 'Episode Ordering'
|
||||
String get episodeOrdering => 'Episode Ordering';
|
||||
|
||||
/// en: 'The Movie Database (Aired)'
|
||||
String get tmdbAiring => 'The Movie Database (Aired)';
|
||||
|
||||
/// en: 'TheTVDB (Aired)'
|
||||
String get tvdbAiring => 'TheTVDB (Aired)';
|
||||
|
||||
/// en: 'TheTVDB (Absolute)'
|
||||
String get tvdbAbsolute => 'TheTVDB (Absolute)';
|
||||
|
||||
/// en: 'Metadata Language'
|
||||
String get metadataLanguage => 'Metadata Language';
|
||||
|
||||
/// en: 'Use Original Title'
|
||||
String get useOriginalTitle => 'Use Original Title';
|
||||
|
||||
/// en: 'Preferred Audio Language'
|
||||
String get preferredAudioLanguage => 'Preferred Audio Language';
|
||||
|
||||
/// en: 'Preferred Subtitle Language'
|
||||
String get preferredSubtitleLanguage => 'Preferred Subtitle Language';
|
||||
|
||||
/// en: 'Auto-Select Subtitle Mode'
|
||||
String get subtitleMode => 'Auto-Select Subtitle Mode';
|
||||
|
||||
/// en: 'Manually selected'
|
||||
String get manuallySelected => 'Manually selected';
|
||||
|
||||
/// en: 'Shown with foreign audio'
|
||||
String get shownWithForeignAudio => 'Shown with foreign audio';
|
||||
|
||||
/// en: 'Always enabled'
|
||||
String get alwaysEnabled => 'Always enabled';
|
||||
}
|
||||
|
||||
// Path: hotkeys.actions
|
||||
class TranslationsHotkeysActionsEn {
|
||||
TranslationsHotkeysActionsEn._(this._root);
|
||||
@@ -2756,6 +2970,7 @@ extension on Translations {
|
||||
'common.exitConfirmMessage' => 'Are you sure you want to exit?',
|
||||
'common.dontAskAgain' => 'Don\'t ask again',
|
||||
'common.exit' => 'Exit',
|
||||
'common.viewAll' => 'View All',
|
||||
'screens.licenses' => 'Licenses',
|
||||
'screens.switchProfile' => 'Switch Profile',
|
||||
'screens.subtitleStyling' => 'Subtitle Styling',
|
||||
@@ -2823,6 +3038,8 @@ extension on Translations {
|
||||
'settings.hardwareDecodingDescription' => 'Use hardware acceleration when available',
|
||||
'settings.bufferSize' => 'Buffer Size',
|
||||
'settings.bufferSizeMB' => ({required Object size}) => '${size}MB',
|
||||
'settings.bufferSizeAuto' => 'Auto (Recommended)',
|
||||
'settings.bufferSizeWarning' => ({required Object heap, required Object size}) => 'Your device has ${heap}MB of memory. A ${size}MB buffer may cause playback issues.',
|
||||
'settings.subtitleStyling' => 'Subtitle Styling',
|
||||
'settings.subtitleStylingDescription' => 'Customize subtitle appearance',
|
||||
'settings.smallSkipDuration' => 'Small Skip Duration',
|
||||
@@ -2953,6 +3170,7 @@ extension on Translations {
|
||||
'mediaMenu.deleteMultipleWarning' => 'Multiple items may be deleted.',
|
||||
'mediaMenu.mediaDeletedSuccessfully' => 'Media item deleted successfully',
|
||||
'mediaMenu.mediaFailedToDelete' => 'Failed to delete media item',
|
||||
'mediaMenu.rate' => 'Rate',
|
||||
'accessibility.mediaCardMovie' => ({required Object title}) => '${title}, movie',
|
||||
'accessibility.mediaCardShow' => ({required Object title}) => '${title}, TV show',
|
||||
'accessibility.mediaCardEpisode' => ({required Object title, required Object episodeInfo}) => '${title}, ${episodeInfo}',
|
||||
@@ -3000,6 +3218,9 @@ extension on Translations {
|
||||
'videoControls.versionsButton' => 'Video versions',
|
||||
'videoControls.pipButton' => 'Picture-in-Picture mode',
|
||||
'videoControls.aspectRatioButton' => 'Aspect ratio',
|
||||
'videoControls.ambientLighting' => 'Ambient lighting',
|
||||
'videoControls.ambientLightingOn' => 'Enable ambient lighting',
|
||||
'videoControls.ambientLightingOff' => 'Disable ambient lighting',
|
||||
'videoControls.fullscreenButton' => 'Enter fullscreen',
|
||||
'videoControls.exitFullscreenButton' => 'Exit fullscreen',
|
||||
'videoControls.alwaysOnTopButton' => 'Always on top',
|
||||
@@ -3015,6 +3236,8 @@ extension on Translations {
|
||||
'videoControls.pipErrors.unknown' => ({required Object error}) => 'An error occurred: ${error}',
|
||||
'videoControls.chapters' => 'Chapters',
|
||||
'videoControls.noChaptersAvailable' => 'No chapters available',
|
||||
'videoControls.queue' => 'Queue',
|
||||
'videoControls.noQueueItems' => 'No items in queue',
|
||||
'userStatus.admin' => 'Admin',
|
||||
'userStatus.restricted' => 'Restricted',
|
||||
'userStatus.protected' => 'Protected',
|
||||
@@ -3211,6 +3434,8 @@ extension on Translations {
|
||||
'liveTv.reloadGuide' => 'Reload Guide',
|
||||
'liveTv.guideReloaded' => 'Guide data reloaded',
|
||||
'liveTv.allChannels' => 'All Channels',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.now' => 'Now',
|
||||
'liveTv.today' => 'Today',
|
||||
'liveTv.midnight' => 'Midnight',
|
||||
@@ -3220,8 +3445,6 @@ extension on Translations {
|
||||
'liveTv.evening' => 'Evening',
|
||||
'liveTv.lateNight' => 'Late Night',
|
||||
'liveTv.whatsOn' => 'What\'s On',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.watchChannel' => 'Watch Channel',
|
||||
'collections.title' => 'Collections',
|
||||
'collections.collection' => 'Collection',
|
||||
@@ -3448,6 +3671,65 @@ extension on Translations {
|
||||
'externalPlayer.launchFailed' => 'Failed to open external player',
|
||||
'externalPlayer.appNotInstalled' => ({required Object name}) => '${name} is not installed',
|
||||
'externalPlayer.playInExternalPlayer' => 'Play in External Player',
|
||||
'metadataEdit.editMetadata' => 'Edit...',
|
||||
'metadataEdit.screenTitle' => 'Edit Metadata',
|
||||
'metadataEdit.basicInfo' => 'Basic Info',
|
||||
'metadataEdit.artwork' => 'Artwork',
|
||||
'metadataEdit.advancedSettings' => 'Advanced Settings',
|
||||
'metadataEdit.title' => 'Title',
|
||||
'metadataEdit.sortTitle' => 'Sort Title',
|
||||
'metadataEdit.originalTitle' => 'Original Title',
|
||||
'metadataEdit.releaseDate' => 'Release Date',
|
||||
'metadataEdit.contentRating' => 'Content Rating',
|
||||
'metadataEdit.studio' => 'Studio',
|
||||
'metadataEdit.tagline' => 'Tagline',
|
||||
'metadataEdit.summary' => 'Summary',
|
||||
'metadataEdit.poster' => 'Poster',
|
||||
'metadataEdit.background' => 'Background',
|
||||
'metadataEdit.selectPoster' => 'Select Poster',
|
||||
'metadataEdit.selectBackground' => 'Select Background',
|
||||
'metadataEdit.fromUrl' => 'From URL',
|
||||
'metadataEdit.uploadFile' => 'Upload File',
|
||||
'metadataEdit.enterImageUrl' => 'Enter image URL',
|
||||
'metadataEdit.imageUrl' => 'Image URL',
|
||||
'metadataEdit.metadataUpdated' => 'Metadata updated',
|
||||
'metadataEdit.metadataUpdateFailed' => 'Failed to update metadata',
|
||||
'metadataEdit.artworkUpdated' => 'Artwork updated',
|
||||
'metadataEdit.artworkUpdateFailed' => 'Failed to update artwork',
|
||||
'metadataEdit.noArtworkAvailable' => 'No artwork available',
|
||||
'metadataEdit.notSet' => 'Not set',
|
||||
'metadataEdit.libraryDefault' => 'Library default',
|
||||
'metadataEdit.accountDefault' => 'Account default',
|
||||
'metadataEdit.seriesDefault' => 'Series default',
|
||||
'metadataEdit.episodeSorting' => 'Episode Sorting',
|
||||
'metadataEdit.oldestFirst' => 'Oldest first',
|
||||
'metadataEdit.newestFirst' => 'Newest first',
|
||||
'metadataEdit.keep' => 'Keep',
|
||||
'metadataEdit.allEpisodes' => 'All episodes',
|
||||
'metadataEdit.latestEpisodes' => ({required Object count}) => '${count} latest episodes',
|
||||
'metadataEdit.latestEpisode' => 'Latest episode',
|
||||
'metadataEdit.episodesAddedPastDays' => ({required Object count}) => 'Episodes added in the past ${count} days',
|
||||
'metadataEdit.deleteAfterPlaying' => 'Delete Episodes After Playing',
|
||||
'metadataEdit.never' => 'Never',
|
||||
'metadataEdit.afterADay' => 'After a day',
|
||||
'metadataEdit.afterAWeek' => 'After a week',
|
||||
'metadataEdit.afterAMonth' => 'After a month',
|
||||
'metadataEdit.onNextRefresh' => 'On next refresh',
|
||||
'metadataEdit.seasons' => 'Seasons',
|
||||
'metadataEdit.show' => 'Show',
|
||||
'metadataEdit.hide' => 'Hide',
|
||||
'metadataEdit.episodeOrdering' => 'Episode Ordering',
|
||||
'metadataEdit.tmdbAiring' => 'The Movie Database (Aired)',
|
||||
'metadataEdit.tvdbAiring' => 'TheTVDB (Aired)',
|
||||
'metadataEdit.tvdbAbsolute' => 'TheTVDB (Absolute)',
|
||||
'metadataEdit.metadataLanguage' => 'Metadata Language',
|
||||
'metadataEdit.useOriginalTitle' => 'Use Original Title',
|
||||
'metadataEdit.preferredAudioLanguage' => 'Preferred Audio Language',
|
||||
'metadataEdit.preferredSubtitleLanguage' => 'Preferred Subtitle Language',
|
||||
'metadataEdit.subtitleMode' => 'Auto-Select Subtitle Mode',
|
||||
'metadataEdit.manuallySelected' => 'Manually selected',
|
||||
'metadataEdit.shownWithForeignAudio' => 'Shown with foreign audio',
|
||||
'metadataEdit.alwaysEnabled' => 'Always enabled',
|
||||
_ => null,
|
||||
};
|
||||
}
|
||||
|
||||
+148
-2
@@ -74,6 +74,7 @@ class TranslationsEs with BaseTranslations<AppLocale, Translations> implements T
|
||||
@override late final _TranslationsCompanionRemoteEs companionRemote = _TranslationsCompanionRemoteEs._(_root);
|
||||
@override late final _TranslationsVideoSettingsEs videoSettings = _TranslationsVideoSettingsEs._(_root);
|
||||
@override late final _TranslationsExternalPlayerEs externalPlayer = _TranslationsExternalPlayerEs._(_root);
|
||||
@override late final _TranslationsMetadataEditEs metadataEdit = _TranslationsMetadataEditEs._(_root);
|
||||
}
|
||||
|
||||
// Path: app
|
||||
@@ -149,6 +150,7 @@ class _TranslationsCommonEs implements TranslationsCommonEn {
|
||||
@override String get exitConfirmMessage => '¿Estás seguro de que quieres salir?';
|
||||
@override String get dontAskAgain => 'No volver a preguntar';
|
||||
@override String get exit => 'Salir';
|
||||
@override String get viewAll => 'Ver todo';
|
||||
}
|
||||
|
||||
// Path: screens
|
||||
@@ -243,6 +245,8 @@ class _TranslationsSettingsEs implements TranslationsSettingsEn {
|
||||
@override String get hardwareDecodingDescription => 'Usar aceleración por hardware cuando esté disponible';
|
||||
@override String get bufferSize => 'Tamaño del Buffer';
|
||||
@override String bufferSizeMB({required Object size}) => '${size}MB';
|
||||
@override String get bufferSizeAuto => 'Auto (Recomendado)';
|
||||
@override String bufferSizeWarning({required Object heap, required Object size}) => 'Tu dispositivo tiene ${heap}MB de memoria. Un búfer de ${size}MB puede causar problemas de reproducción.';
|
||||
@override String get subtitleStyling => 'Estilo de Subtítulos';
|
||||
@override String get subtitleStylingDescription => 'Personalizar la apariencia de los subtítulos';
|
||||
@override String get smallSkipDuration => 'Salto pequeño';
|
||||
@@ -400,6 +404,7 @@ class _TranslationsMediaMenuEs implements TranslationsMediaMenuEn {
|
||||
@override String get deleteMultipleWarning => 'Es posible que se eliminen varios elementos.';
|
||||
@override String get mediaDeletedSuccessfully => 'Elemento multimedia eliminado con éxito';
|
||||
@override String get mediaFailedToDelete => 'Error al eliminar el elemento multimedia';
|
||||
@override String get rate => 'Calificar';
|
||||
}
|
||||
|
||||
// Path: accessibility
|
||||
@@ -474,6 +479,9 @@ class _TranslationsVideoControlsEs implements TranslationsVideoControlsEn {
|
||||
@override String get versionsButton => 'Versiones de video';
|
||||
@override String get pipButton => 'Modo PiP (Imagen en Imagen)';
|
||||
@override String get aspectRatioButton => 'Relación de aspecto';
|
||||
@override String get ambientLighting => 'Iluminación ambiental';
|
||||
@override String get ambientLightingOn => 'Activar iluminación ambiental';
|
||||
@override String get ambientLightingOff => 'Desactivar iluminación ambiental';
|
||||
@override String get fullscreenButton => 'Entrar en pantalla completa';
|
||||
@override String get exitFullscreenButton => 'Salir de pantalla completa';
|
||||
@override String get alwaysOnTopButton => 'Siempre visible';
|
||||
@@ -485,6 +493,8 @@ class _TranslationsVideoControlsEs implements TranslationsVideoControlsEn {
|
||||
@override late final _TranslationsVideoControlsPipErrorsEs pipErrors = _TranslationsVideoControlsPipErrorsEs._(_root);
|
||||
@override String get chapters => 'Capítulos';
|
||||
@override String get noChaptersAvailable => 'No hay capítulos disponibles';
|
||||
@override String get queue => 'Queue';
|
||||
@override String get noQueueItems => 'No items in queue';
|
||||
}
|
||||
|
||||
// Path: userStatus
|
||||
@@ -1043,6 +1053,74 @@ class _TranslationsExternalPlayerEs implements TranslationsExternalPlayerEn {
|
||||
@override String get playInExternalPlayer => 'Reproducir en reproductor externo';
|
||||
}
|
||||
|
||||
// Path: metadataEdit
|
||||
class _TranslationsMetadataEditEs implements TranslationsMetadataEditEn {
|
||||
_TranslationsMetadataEditEs._(this._root);
|
||||
|
||||
final TranslationsEs _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get editMetadata => 'Editar...';
|
||||
@override String get screenTitle => 'Editar metadatos';
|
||||
@override String get basicInfo => 'Información básica';
|
||||
@override String get artwork => 'Artwork';
|
||||
@override String get advancedSettings => 'Ajustes avanzados';
|
||||
@override String get title => 'Título';
|
||||
@override String get sortTitle => 'Título de ordenación';
|
||||
@override String get originalTitle => 'Título original';
|
||||
@override String get releaseDate => 'Fecha de estreno';
|
||||
@override String get contentRating => 'Clasificación de contenido';
|
||||
@override String get studio => 'Estudio';
|
||||
@override String get tagline => 'Eslogan';
|
||||
@override String get summary => 'Resumen';
|
||||
@override String get poster => 'Póster';
|
||||
@override String get background => 'Fondo';
|
||||
@override String get selectPoster => 'Seleccionar póster';
|
||||
@override String get selectBackground => 'Seleccionar fondo';
|
||||
@override String get fromUrl => 'Desde URL';
|
||||
@override String get uploadFile => 'Subir archivo';
|
||||
@override String get enterImageUrl => 'Introducir URL de imagen';
|
||||
@override String get imageUrl => 'URL de imagen';
|
||||
@override String get metadataUpdated => 'Metadatos actualizados';
|
||||
@override String get metadataUpdateFailed => 'Error al actualizar los metadatos';
|
||||
@override String get artworkUpdated => 'Artwork actualizado';
|
||||
@override String get artworkUpdateFailed => 'Error al actualizar el artwork';
|
||||
@override String get noArtworkAvailable => 'No hay artwork disponible';
|
||||
@override String get notSet => 'No establecido';
|
||||
@override String get libraryDefault => 'Predeterminado de biblioteca';
|
||||
@override String get accountDefault => 'Predeterminado de cuenta';
|
||||
@override String get seriesDefault => 'Predeterminado de serie';
|
||||
@override String get episodeSorting => 'Orden de episodios';
|
||||
@override String get oldestFirst => 'Más antiguos primero';
|
||||
@override String get newestFirst => 'Más recientes primero';
|
||||
@override String get keep => 'Conservar';
|
||||
@override String get allEpisodes => 'Todos los episodios';
|
||||
@override String latestEpisodes({required Object count}) => '${count} episodios más recientes';
|
||||
@override String get latestEpisode => 'Episodio más reciente';
|
||||
@override String episodesAddedPastDays({required Object count}) => 'Episodios añadidos en los últimos ${count} días';
|
||||
@override String get deleteAfterPlaying => 'Eliminar episodios después de reproducir';
|
||||
@override String get never => 'Nunca';
|
||||
@override String get afterADay => 'Después de un día';
|
||||
@override String get afterAWeek => 'Después de una semana';
|
||||
@override String get afterAMonth => 'Después de un mes';
|
||||
@override String get onNextRefresh => 'En la próxima actualización';
|
||||
@override String get seasons => 'Temporadas';
|
||||
@override String get show => 'Mostrar';
|
||||
@override String get hide => 'Ocultar';
|
||||
@override String get episodeOrdering => 'Orden de episodios';
|
||||
@override String get tmdbAiring => 'The Movie Database (Emisión)';
|
||||
@override String get tvdbAiring => 'TheTVDB (Emisión)';
|
||||
@override String get tvdbAbsolute => 'TheTVDB (Absoluto)';
|
||||
@override String get metadataLanguage => 'Idioma de metadatos';
|
||||
@override String get useOriginalTitle => 'Usar título original';
|
||||
@override String get preferredAudioLanguage => 'Idioma de audio preferido';
|
||||
@override String get preferredSubtitleLanguage => 'Idioma de subtítulos preferido';
|
||||
@override String get subtitleMode => 'Selección automática de subtítulos';
|
||||
@override String get manuallySelected => 'Seleccionado manualmente';
|
||||
@override String get shownWithForeignAudio => 'Mostrar con audio extranjero';
|
||||
@override String get alwaysEnabled => 'Siempre activado';
|
||||
}
|
||||
|
||||
// Path: hotkeys.actions
|
||||
class _TranslationsHotkeysActionsEs implements TranslationsHotkeysActionsEn {
|
||||
_TranslationsHotkeysActionsEs._(this._root);
|
||||
@@ -1273,6 +1351,7 @@ extension on TranslationsEs {
|
||||
'common.exitConfirmMessage' => '¿Estás seguro de que quieres salir?',
|
||||
'common.dontAskAgain' => 'No volver a preguntar',
|
||||
'common.exit' => 'Salir',
|
||||
'common.viewAll' => 'Ver todo',
|
||||
'screens.licenses' => 'Licencias',
|
||||
'screens.switchProfile' => 'Cambiar Perfil',
|
||||
'screens.subtitleStyling' => 'Estilo de Subtítulos',
|
||||
@@ -1340,6 +1419,8 @@ extension on TranslationsEs {
|
||||
'settings.hardwareDecodingDescription' => 'Usar aceleración por hardware cuando esté disponible',
|
||||
'settings.bufferSize' => 'Tamaño del Buffer',
|
||||
'settings.bufferSizeMB' => ({required Object size}) => '${size}MB',
|
||||
'settings.bufferSizeAuto' => 'Auto (Recomendado)',
|
||||
'settings.bufferSizeWarning' => ({required Object heap, required Object size}) => 'Tu dispositivo tiene ${heap}MB de memoria. Un búfer de ${size}MB puede causar problemas de reproducción.',
|
||||
'settings.subtitleStyling' => 'Estilo de Subtítulos',
|
||||
'settings.subtitleStylingDescription' => 'Personalizar la apariencia de los subtítulos',
|
||||
'settings.smallSkipDuration' => 'Salto pequeño',
|
||||
@@ -1470,6 +1551,7 @@ extension on TranslationsEs {
|
||||
'mediaMenu.deleteMultipleWarning' => 'Es posible que se eliminen varios elementos.',
|
||||
'mediaMenu.mediaDeletedSuccessfully' => 'Elemento multimedia eliminado con éxito',
|
||||
'mediaMenu.mediaFailedToDelete' => 'Error al eliminar el elemento multimedia',
|
||||
'mediaMenu.rate' => 'Calificar',
|
||||
'accessibility.mediaCardMovie' => ({required Object title}) => '${title}, película',
|
||||
'accessibility.mediaCardShow' => ({required Object title}) => '${title}, serie de TV',
|
||||
'accessibility.mediaCardEpisode' => ({required Object title, required Object episodeInfo}) => '${title}, ${episodeInfo}',
|
||||
@@ -1517,6 +1599,9 @@ extension on TranslationsEs {
|
||||
'videoControls.versionsButton' => 'Versiones de video',
|
||||
'videoControls.pipButton' => 'Modo PiP (Imagen en Imagen)',
|
||||
'videoControls.aspectRatioButton' => 'Relación de aspecto',
|
||||
'videoControls.ambientLighting' => 'Iluminación ambiental',
|
||||
'videoControls.ambientLightingOn' => 'Activar iluminación ambiental',
|
||||
'videoControls.ambientLightingOff' => 'Desactivar iluminación ambiental',
|
||||
'videoControls.fullscreenButton' => 'Entrar en pantalla completa',
|
||||
'videoControls.exitFullscreenButton' => 'Salir de pantalla completa',
|
||||
'videoControls.alwaysOnTopButton' => 'Siempre visible',
|
||||
@@ -1532,6 +1617,8 @@ extension on TranslationsEs {
|
||||
'videoControls.pipErrors.unknown' => ({required Object error}) => 'Ocurrió un error: ${error}',
|
||||
'videoControls.chapters' => 'Capítulos',
|
||||
'videoControls.noChaptersAvailable' => 'No hay capítulos disponibles',
|
||||
'videoControls.queue' => 'Queue',
|
||||
'videoControls.noQueueItems' => 'No items in queue',
|
||||
'userStatus.admin' => 'Administrador',
|
||||
'userStatus.restricted' => 'Restringido',
|
||||
'userStatus.protected' => 'Protegido',
|
||||
@@ -1728,6 +1815,8 @@ extension on TranslationsEs {
|
||||
'liveTv.reloadGuide' => 'Recargar guía',
|
||||
'liveTv.guideReloaded' => 'Datos de la guía recargados',
|
||||
'liveTv.allChannels' => 'Todos los canales',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.now' => 'Ahora',
|
||||
'liveTv.today' => 'Hoy',
|
||||
'liveTv.midnight' => 'Medianoche',
|
||||
@@ -1737,8 +1826,6 @@ extension on TranslationsEs {
|
||||
'liveTv.evening' => 'Noche',
|
||||
'liveTv.lateNight' => 'Trasnoche',
|
||||
'liveTv.whatsOn' => 'En emisión',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.watchChannel' => 'Ver canal',
|
||||
'collections.title' => 'Colecciones',
|
||||
'collections.collection' => 'Colección',
|
||||
@@ -1965,6 +2052,65 @@ extension on TranslationsEs {
|
||||
'externalPlayer.launchFailed' => 'No se pudo abrir el reproductor externo',
|
||||
'externalPlayer.appNotInstalled' => ({required Object name}) => '${name} no está instalado',
|
||||
'externalPlayer.playInExternalPlayer' => 'Reproducir en reproductor externo',
|
||||
'metadataEdit.editMetadata' => 'Editar...',
|
||||
'metadataEdit.screenTitle' => 'Editar metadatos',
|
||||
'metadataEdit.basicInfo' => 'Información básica',
|
||||
'metadataEdit.artwork' => 'Artwork',
|
||||
'metadataEdit.advancedSettings' => 'Ajustes avanzados',
|
||||
'metadataEdit.title' => 'Título',
|
||||
'metadataEdit.sortTitle' => 'Título de ordenación',
|
||||
'metadataEdit.originalTitle' => 'Título original',
|
||||
'metadataEdit.releaseDate' => 'Fecha de estreno',
|
||||
'metadataEdit.contentRating' => 'Clasificación de contenido',
|
||||
'metadataEdit.studio' => 'Estudio',
|
||||
'metadataEdit.tagline' => 'Eslogan',
|
||||
'metadataEdit.summary' => 'Resumen',
|
||||
'metadataEdit.poster' => 'Póster',
|
||||
'metadataEdit.background' => 'Fondo',
|
||||
'metadataEdit.selectPoster' => 'Seleccionar póster',
|
||||
'metadataEdit.selectBackground' => 'Seleccionar fondo',
|
||||
'metadataEdit.fromUrl' => 'Desde URL',
|
||||
'metadataEdit.uploadFile' => 'Subir archivo',
|
||||
'metadataEdit.enterImageUrl' => 'Introducir URL de imagen',
|
||||
'metadataEdit.imageUrl' => 'URL de imagen',
|
||||
'metadataEdit.metadataUpdated' => 'Metadatos actualizados',
|
||||
'metadataEdit.metadataUpdateFailed' => 'Error al actualizar los metadatos',
|
||||
'metadataEdit.artworkUpdated' => 'Artwork actualizado',
|
||||
'metadataEdit.artworkUpdateFailed' => 'Error al actualizar el artwork',
|
||||
'metadataEdit.noArtworkAvailable' => 'No hay artwork disponible',
|
||||
'metadataEdit.notSet' => 'No establecido',
|
||||
'metadataEdit.libraryDefault' => 'Predeterminado de biblioteca',
|
||||
'metadataEdit.accountDefault' => 'Predeterminado de cuenta',
|
||||
'metadataEdit.seriesDefault' => 'Predeterminado de serie',
|
||||
'metadataEdit.episodeSorting' => 'Orden de episodios',
|
||||
'metadataEdit.oldestFirst' => 'Más antiguos primero',
|
||||
'metadataEdit.newestFirst' => 'Más recientes primero',
|
||||
'metadataEdit.keep' => 'Conservar',
|
||||
'metadataEdit.allEpisodes' => 'Todos los episodios',
|
||||
'metadataEdit.latestEpisodes' => ({required Object count}) => '${count} episodios más recientes',
|
||||
'metadataEdit.latestEpisode' => 'Episodio más reciente',
|
||||
'metadataEdit.episodesAddedPastDays' => ({required Object count}) => 'Episodios añadidos en los últimos ${count} días',
|
||||
'metadataEdit.deleteAfterPlaying' => 'Eliminar episodios después de reproducir',
|
||||
'metadataEdit.never' => 'Nunca',
|
||||
'metadataEdit.afterADay' => 'Después de un día',
|
||||
'metadataEdit.afterAWeek' => 'Después de una semana',
|
||||
'metadataEdit.afterAMonth' => 'Después de un mes',
|
||||
'metadataEdit.onNextRefresh' => 'En la próxima actualización',
|
||||
'metadataEdit.seasons' => 'Temporadas',
|
||||
'metadataEdit.show' => 'Mostrar',
|
||||
'metadataEdit.hide' => 'Ocultar',
|
||||
'metadataEdit.episodeOrdering' => 'Orden de episodios',
|
||||
'metadataEdit.tmdbAiring' => 'The Movie Database (Emisión)',
|
||||
'metadataEdit.tvdbAiring' => 'TheTVDB (Emisión)',
|
||||
'metadataEdit.tvdbAbsolute' => 'TheTVDB (Absoluto)',
|
||||
'metadataEdit.metadataLanguage' => 'Idioma de metadatos',
|
||||
'metadataEdit.useOriginalTitle' => 'Usar título original',
|
||||
'metadataEdit.preferredAudioLanguage' => 'Idioma de audio preferido',
|
||||
'metadataEdit.preferredSubtitleLanguage' => 'Idioma de subtítulos preferido',
|
||||
'metadataEdit.subtitleMode' => 'Selección automática de subtítulos',
|
||||
'metadataEdit.manuallySelected' => 'Seleccionado manualmente',
|
||||
'metadataEdit.shownWithForeignAudio' => 'Mostrar con audio extranjero',
|
||||
'metadataEdit.alwaysEnabled' => 'Siempre activado',
|
||||
_ => null,
|
||||
};
|
||||
}
|
||||
|
||||
+148
-2
@@ -74,6 +74,7 @@ class TranslationsFr with BaseTranslations<AppLocale, Translations> implements T
|
||||
@override late final _TranslationsCompanionRemoteFr companionRemote = _TranslationsCompanionRemoteFr._(_root);
|
||||
@override late final _TranslationsVideoSettingsFr videoSettings = _TranslationsVideoSettingsFr._(_root);
|
||||
@override late final _TranslationsExternalPlayerFr externalPlayer = _TranslationsExternalPlayerFr._(_root);
|
||||
@override late final _TranslationsMetadataEditFr metadataEdit = _TranslationsMetadataEditFr._(_root);
|
||||
}
|
||||
|
||||
// Path: app
|
||||
@@ -149,6 +150,7 @@ class _TranslationsCommonFr implements TranslationsCommonEn {
|
||||
@override String get exitConfirmMessage => 'Êtes-vous sûr de vouloir quitter ?';
|
||||
@override String get dontAskAgain => 'Ne plus demander';
|
||||
@override String get exit => 'Quitter';
|
||||
@override String get viewAll => 'Tout afficher';
|
||||
}
|
||||
|
||||
// Path: screens
|
||||
@@ -243,6 +245,8 @@ class _TranslationsSettingsFr implements TranslationsSettingsEn {
|
||||
@override String get hardwareDecodingDescription => 'Utilisez l\'accélération matérielle lorsqu\'elle est disponible.';
|
||||
@override String get bufferSize => 'Taille du Buffer';
|
||||
@override String bufferSizeMB({required Object size}) => '${size}MB';
|
||||
@override String get bufferSizeAuto => 'Auto (Recommandé)';
|
||||
@override String bufferSizeWarning({required Object heap, required Object size}) => 'Votre appareil dispose de ${heap}MB de mémoire. Un tampon de ${size}MB peut causer des problèmes de lecture.';
|
||||
@override String get subtitleStyling => 'Stylisation des sous-titres';
|
||||
@override String get subtitleStylingDescription => 'Personnaliser l\'apparence des sous-titres';
|
||||
@override String get smallSkipDuration => 'Small Skip Duration';
|
||||
@@ -400,6 +404,7 @@ class _TranslationsMediaMenuFr implements TranslationsMediaMenuEn {
|
||||
@override String get deleteMultipleWarning => 'Plusieurs éléments peuvent être supprimés.';
|
||||
@override String get mediaDeletedSuccessfully => 'Élément média supprimé avec succès';
|
||||
@override String get mediaFailedToDelete => 'Échec de la suppression de l\'élément média';
|
||||
@override String get rate => 'Noter';
|
||||
}
|
||||
|
||||
// Path: accessibility
|
||||
@@ -474,6 +479,9 @@ class _TranslationsVideoControlsFr implements TranslationsVideoControlsEn {
|
||||
@override String get versionsButton => 'Versions vidéo';
|
||||
@override String get pipButton => 'Mode PiP (Picture-in-Picture)';
|
||||
@override String get aspectRatioButton => 'Format d\'image';
|
||||
@override String get ambientLighting => 'Éclairage ambiant';
|
||||
@override String get ambientLightingOn => 'Activer l\'éclairage ambiant';
|
||||
@override String get ambientLightingOff => 'Désactiver l\'éclairage ambiant';
|
||||
@override String get fullscreenButton => 'Passer en mode plein écran';
|
||||
@override String get exitFullscreenButton => 'Quitter le mode plein écran';
|
||||
@override String get alwaysOnTopButton => 'Always on top';
|
||||
@@ -485,6 +493,8 @@ class _TranslationsVideoControlsFr implements TranslationsVideoControlsEn {
|
||||
@override late final _TranslationsVideoControlsPipErrorsFr pipErrors = _TranslationsVideoControlsPipErrorsFr._(_root);
|
||||
@override String get chapters => 'Chapitres';
|
||||
@override String get noChaptersAvailable => 'Aucun chapitre disponible';
|
||||
@override String get queue => 'Queue';
|
||||
@override String get noQueueItems => 'No items in queue';
|
||||
}
|
||||
|
||||
// Path: userStatus
|
||||
@@ -1043,6 +1053,74 @@ class _TranslationsExternalPlayerFr implements TranslationsExternalPlayerEn {
|
||||
@override String get playInExternalPlayer => 'Lire dans un lecteur externe';
|
||||
}
|
||||
|
||||
// Path: metadataEdit
|
||||
class _TranslationsMetadataEditFr implements TranslationsMetadataEditEn {
|
||||
_TranslationsMetadataEditFr._(this._root);
|
||||
|
||||
final TranslationsFr _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get editMetadata => 'Modifier...';
|
||||
@override String get screenTitle => 'Modifier les métadonnées';
|
||||
@override String get basicInfo => 'Informations de base';
|
||||
@override String get artwork => 'Artwork';
|
||||
@override String get advancedSettings => 'Paramètres avancés';
|
||||
@override String get title => 'Titre';
|
||||
@override String get sortTitle => 'Titre de tri';
|
||||
@override String get originalTitle => 'Titre original';
|
||||
@override String get releaseDate => 'Date de sortie';
|
||||
@override String get contentRating => 'Classification';
|
||||
@override String get studio => 'Studio';
|
||||
@override String get tagline => 'Slogan';
|
||||
@override String get summary => 'Résumé';
|
||||
@override String get poster => 'Affiche';
|
||||
@override String get background => 'Arrière-plan';
|
||||
@override String get selectPoster => 'Sélectionner l\'affiche';
|
||||
@override String get selectBackground => 'Sélectionner l\'arrière-plan';
|
||||
@override String get fromUrl => 'Depuis une URL';
|
||||
@override String get uploadFile => 'Importer un fichier';
|
||||
@override String get enterImageUrl => 'Entrer l\'URL de l\'image';
|
||||
@override String get imageUrl => 'URL de l\'image';
|
||||
@override String get metadataUpdated => 'Métadonnées mises à jour';
|
||||
@override String get metadataUpdateFailed => 'Échec de la mise à jour des métadonnées';
|
||||
@override String get artworkUpdated => 'Artwork mis à jour';
|
||||
@override String get artworkUpdateFailed => 'Échec de la mise à jour de l\'artwork';
|
||||
@override String get noArtworkAvailable => 'Aucun artwork disponible';
|
||||
@override String get notSet => 'Non défini';
|
||||
@override String get libraryDefault => 'Par défaut de la bibliothèque';
|
||||
@override String get accountDefault => 'Par défaut du compte';
|
||||
@override String get seriesDefault => 'Par défaut de la série';
|
||||
@override String get episodeSorting => 'Tri des épisodes';
|
||||
@override String get oldestFirst => 'Plus anciens en premier';
|
||||
@override String get newestFirst => 'Plus récents en premier';
|
||||
@override String get keep => 'Conserver';
|
||||
@override String get allEpisodes => 'Tous les épisodes';
|
||||
@override String latestEpisodes({required Object count}) => '${count} derniers épisodes';
|
||||
@override String get latestEpisode => 'Dernier épisode';
|
||||
@override String episodesAddedPastDays({required Object count}) => 'Épisodes ajoutés ces ${count} derniers jours';
|
||||
@override String get deleteAfterPlaying => 'Supprimer les épisodes après lecture';
|
||||
@override String get never => 'Jamais';
|
||||
@override String get afterADay => 'Après un jour';
|
||||
@override String get afterAWeek => 'Après une semaine';
|
||||
@override String get afterAMonth => 'Après un mois';
|
||||
@override String get onNextRefresh => 'Au prochain rafraîchissement';
|
||||
@override String get seasons => 'Saisons';
|
||||
@override String get show => 'Afficher';
|
||||
@override String get hide => 'Masquer';
|
||||
@override String get episodeOrdering => 'Ordre des épisodes';
|
||||
@override String get tmdbAiring => 'The Movie Database (Diffusion)';
|
||||
@override String get tvdbAiring => 'TheTVDB (Diffusion)';
|
||||
@override String get tvdbAbsolute => 'TheTVDB (Absolu)';
|
||||
@override String get metadataLanguage => 'Langue des métadonnées';
|
||||
@override String get useOriginalTitle => 'Utiliser le titre original';
|
||||
@override String get preferredAudioLanguage => 'Langue audio préférée';
|
||||
@override String get preferredSubtitleLanguage => 'Langue de sous-titres préférée';
|
||||
@override String get subtitleMode => 'Sélection automatique des sous-titres';
|
||||
@override String get manuallySelected => 'Sélectionné manuellement';
|
||||
@override String get shownWithForeignAudio => 'Affichés avec audio étranger';
|
||||
@override String get alwaysEnabled => 'Toujours activé';
|
||||
}
|
||||
|
||||
// Path: hotkeys.actions
|
||||
class _TranslationsHotkeysActionsFr implements TranslationsHotkeysActionsEn {
|
||||
_TranslationsHotkeysActionsFr._(this._root);
|
||||
@@ -1273,6 +1351,7 @@ extension on TranslationsFr {
|
||||
'common.exitConfirmMessage' => 'Êtes-vous sûr de vouloir quitter ?',
|
||||
'common.dontAskAgain' => 'Ne plus demander',
|
||||
'common.exit' => 'Quitter',
|
||||
'common.viewAll' => 'Tout afficher',
|
||||
'screens.licenses' => 'Licenses',
|
||||
'screens.switchProfile' => 'Changer de profil',
|
||||
'screens.subtitleStyling' => 'Configuration des sous-titres',
|
||||
@@ -1340,6 +1419,8 @@ extension on TranslationsFr {
|
||||
'settings.hardwareDecodingDescription' => 'Utilisez l\'accélération matérielle lorsqu\'elle est disponible.',
|
||||
'settings.bufferSize' => 'Taille du Buffer',
|
||||
'settings.bufferSizeMB' => ({required Object size}) => '${size}MB',
|
||||
'settings.bufferSizeAuto' => 'Auto (Recommandé)',
|
||||
'settings.bufferSizeWarning' => ({required Object heap, required Object size}) => 'Votre appareil dispose de ${heap}MB de mémoire. Un tampon de ${size}MB peut causer des problèmes de lecture.',
|
||||
'settings.subtitleStyling' => 'Stylisation des sous-titres',
|
||||
'settings.subtitleStylingDescription' => 'Personnaliser l\'apparence des sous-titres',
|
||||
'settings.smallSkipDuration' => 'Small Skip Duration',
|
||||
@@ -1470,6 +1551,7 @@ extension on TranslationsFr {
|
||||
'mediaMenu.deleteMultipleWarning' => 'Plusieurs éléments peuvent être supprimés.',
|
||||
'mediaMenu.mediaDeletedSuccessfully' => 'Élément média supprimé avec succès',
|
||||
'mediaMenu.mediaFailedToDelete' => 'Échec de la suppression de l\'élément média',
|
||||
'mediaMenu.rate' => 'Noter',
|
||||
'accessibility.mediaCardMovie' => ({required Object title}) => '${title}, film',
|
||||
'accessibility.mediaCardShow' => ({required Object title}) => '${title}, show TV',
|
||||
'accessibility.mediaCardEpisode' => ({required Object title, required Object episodeInfo}) => '${title}, ${episodeInfo}',
|
||||
@@ -1517,6 +1599,9 @@ extension on TranslationsFr {
|
||||
'videoControls.versionsButton' => 'Versions vidéo',
|
||||
'videoControls.pipButton' => 'Mode PiP (Picture-in-Picture)',
|
||||
'videoControls.aspectRatioButton' => 'Format d\'image',
|
||||
'videoControls.ambientLighting' => 'Éclairage ambiant',
|
||||
'videoControls.ambientLightingOn' => 'Activer l\'éclairage ambiant',
|
||||
'videoControls.ambientLightingOff' => 'Désactiver l\'éclairage ambiant',
|
||||
'videoControls.fullscreenButton' => 'Passer en mode plein écran',
|
||||
'videoControls.exitFullscreenButton' => 'Quitter le mode plein écran',
|
||||
'videoControls.alwaysOnTopButton' => 'Always on top',
|
||||
@@ -1532,6 +1617,8 @@ extension on TranslationsFr {
|
||||
'videoControls.pipErrors.unknown' => ({required Object error}) => 'Une erreur s\'est produite : ${error}',
|
||||
'videoControls.chapters' => 'Chapitres',
|
||||
'videoControls.noChaptersAvailable' => 'Aucun chapitre disponible',
|
||||
'videoControls.queue' => 'Queue',
|
||||
'videoControls.noQueueItems' => 'No items in queue',
|
||||
'userStatus.admin' => 'Admin',
|
||||
'userStatus.restricted' => 'Restreint',
|
||||
'userStatus.protected' => 'Protégé',
|
||||
@@ -1728,6 +1815,8 @@ extension on TranslationsFr {
|
||||
'liveTv.reloadGuide' => 'Recharger le guide',
|
||||
'liveTv.guideReloaded' => 'Données du guide rechargées',
|
||||
'liveTv.allChannels' => 'Toutes les chaînes',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.now' => 'Maintenant',
|
||||
'liveTv.today' => 'Aujourd\'hui',
|
||||
'liveTv.midnight' => 'Minuit',
|
||||
@@ -1737,8 +1826,6 @@ extension on TranslationsFr {
|
||||
'liveTv.evening' => 'Soirée',
|
||||
'liveTv.lateNight' => 'Nuit tardive',
|
||||
'liveTv.whatsOn' => 'En ce moment',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.watchChannel' => 'Regarder la chaîne',
|
||||
'collections.title' => 'Collections',
|
||||
'collections.collection' => 'Collection',
|
||||
@@ -1965,6 +2052,65 @@ extension on TranslationsFr {
|
||||
'externalPlayer.launchFailed' => 'Impossible d\'ouvrir le lecteur externe',
|
||||
'externalPlayer.appNotInstalled' => ({required Object name}) => '${name} n\'est pas installé',
|
||||
'externalPlayer.playInExternalPlayer' => 'Lire dans un lecteur externe',
|
||||
'metadataEdit.editMetadata' => 'Modifier...',
|
||||
'metadataEdit.screenTitle' => 'Modifier les métadonnées',
|
||||
'metadataEdit.basicInfo' => 'Informations de base',
|
||||
'metadataEdit.artwork' => 'Artwork',
|
||||
'metadataEdit.advancedSettings' => 'Paramètres avancés',
|
||||
'metadataEdit.title' => 'Titre',
|
||||
'metadataEdit.sortTitle' => 'Titre de tri',
|
||||
'metadataEdit.originalTitle' => 'Titre original',
|
||||
'metadataEdit.releaseDate' => 'Date de sortie',
|
||||
'metadataEdit.contentRating' => 'Classification',
|
||||
'metadataEdit.studio' => 'Studio',
|
||||
'metadataEdit.tagline' => 'Slogan',
|
||||
'metadataEdit.summary' => 'Résumé',
|
||||
'metadataEdit.poster' => 'Affiche',
|
||||
'metadataEdit.background' => 'Arrière-plan',
|
||||
'metadataEdit.selectPoster' => 'Sélectionner l\'affiche',
|
||||
'metadataEdit.selectBackground' => 'Sélectionner l\'arrière-plan',
|
||||
'metadataEdit.fromUrl' => 'Depuis une URL',
|
||||
'metadataEdit.uploadFile' => 'Importer un fichier',
|
||||
'metadataEdit.enterImageUrl' => 'Entrer l\'URL de l\'image',
|
||||
'metadataEdit.imageUrl' => 'URL de l\'image',
|
||||
'metadataEdit.metadataUpdated' => 'Métadonnées mises à jour',
|
||||
'metadataEdit.metadataUpdateFailed' => 'Échec de la mise à jour des métadonnées',
|
||||
'metadataEdit.artworkUpdated' => 'Artwork mis à jour',
|
||||
'metadataEdit.artworkUpdateFailed' => 'Échec de la mise à jour de l\'artwork',
|
||||
'metadataEdit.noArtworkAvailable' => 'Aucun artwork disponible',
|
||||
'metadataEdit.notSet' => 'Non défini',
|
||||
'metadataEdit.libraryDefault' => 'Par défaut de la bibliothèque',
|
||||
'metadataEdit.accountDefault' => 'Par défaut du compte',
|
||||
'metadataEdit.seriesDefault' => 'Par défaut de la série',
|
||||
'metadataEdit.episodeSorting' => 'Tri des épisodes',
|
||||
'metadataEdit.oldestFirst' => 'Plus anciens en premier',
|
||||
'metadataEdit.newestFirst' => 'Plus récents en premier',
|
||||
'metadataEdit.keep' => 'Conserver',
|
||||
'metadataEdit.allEpisodes' => 'Tous les épisodes',
|
||||
'metadataEdit.latestEpisodes' => ({required Object count}) => '${count} derniers épisodes',
|
||||
'metadataEdit.latestEpisode' => 'Dernier épisode',
|
||||
'metadataEdit.episodesAddedPastDays' => ({required Object count}) => 'Épisodes ajoutés ces ${count} derniers jours',
|
||||
'metadataEdit.deleteAfterPlaying' => 'Supprimer les épisodes après lecture',
|
||||
'metadataEdit.never' => 'Jamais',
|
||||
'metadataEdit.afterADay' => 'Après un jour',
|
||||
'metadataEdit.afterAWeek' => 'Après une semaine',
|
||||
'metadataEdit.afterAMonth' => 'Après un mois',
|
||||
'metadataEdit.onNextRefresh' => 'Au prochain rafraîchissement',
|
||||
'metadataEdit.seasons' => 'Saisons',
|
||||
'metadataEdit.show' => 'Afficher',
|
||||
'metadataEdit.hide' => 'Masquer',
|
||||
'metadataEdit.episodeOrdering' => 'Ordre des épisodes',
|
||||
'metadataEdit.tmdbAiring' => 'The Movie Database (Diffusion)',
|
||||
'metadataEdit.tvdbAiring' => 'TheTVDB (Diffusion)',
|
||||
'metadataEdit.tvdbAbsolute' => 'TheTVDB (Absolu)',
|
||||
'metadataEdit.metadataLanguage' => 'Langue des métadonnées',
|
||||
'metadataEdit.useOriginalTitle' => 'Utiliser le titre original',
|
||||
'metadataEdit.preferredAudioLanguage' => 'Langue audio préférée',
|
||||
'metadataEdit.preferredSubtitleLanguage' => 'Langue de sous-titres préférée',
|
||||
'metadataEdit.subtitleMode' => 'Sélection automatique des sous-titres',
|
||||
'metadataEdit.manuallySelected' => 'Sélectionné manuellement',
|
||||
'metadataEdit.shownWithForeignAudio' => 'Affichés avec audio étranger',
|
||||
'metadataEdit.alwaysEnabled' => 'Toujours activé',
|
||||
_ => null,
|
||||
};
|
||||
}
|
||||
|
||||
+148
-2
@@ -74,6 +74,7 @@ class TranslationsIt with BaseTranslations<AppLocale, Translations> implements T
|
||||
@override late final _TranslationsCompanionRemoteIt companionRemote = _TranslationsCompanionRemoteIt._(_root);
|
||||
@override late final _TranslationsVideoSettingsIt videoSettings = _TranslationsVideoSettingsIt._(_root);
|
||||
@override late final _TranslationsExternalPlayerIt externalPlayer = _TranslationsExternalPlayerIt._(_root);
|
||||
@override late final _TranslationsMetadataEditIt metadataEdit = _TranslationsMetadataEditIt._(_root);
|
||||
}
|
||||
|
||||
// Path: app
|
||||
@@ -149,6 +150,7 @@ class _TranslationsCommonIt implements TranslationsCommonEn {
|
||||
@override String get exitConfirmMessage => 'Sei sicuro di voler uscire?';
|
||||
@override String get dontAskAgain => 'Non chiedere più';
|
||||
@override String get exit => 'Esci';
|
||||
@override String get viewAll => 'Mostra tutto';
|
||||
}
|
||||
|
||||
// Path: screens
|
||||
@@ -243,6 +245,8 @@ class _TranslationsSettingsIt implements TranslationsSettingsEn {
|
||||
@override String get hardwareDecodingDescription => 'Utilizza l\'accelerazione hardware quando disponibile';
|
||||
@override String get bufferSize => 'Dimensione buffer';
|
||||
@override String bufferSizeMB({required Object size}) => '${size}MB';
|
||||
@override String get bufferSizeAuto => 'Auto (Consigliato)';
|
||||
@override String bufferSizeWarning({required Object heap, required Object size}) => 'Il tuo dispositivo ha ${heap}MB di memoria. Un buffer di ${size}MB potrebbe causare problemi di riproduzione.';
|
||||
@override String get subtitleStyling => 'Stile sottotitoli';
|
||||
@override String get subtitleStylingDescription => 'Personalizza l\'aspetto dei sottotitoli';
|
||||
@override String get smallSkipDuration => 'Durata skip breve';
|
||||
@@ -400,6 +404,7 @@ class _TranslationsMediaMenuIt implements TranslationsMediaMenuEn {
|
||||
@override String get deleteMultipleWarning => 'Potrebbero essere eliminati più elementi.';
|
||||
@override String get mediaDeletedSuccessfully => 'Elemento multimediale eliminato con successo';
|
||||
@override String get mediaFailedToDelete => 'Impossibile eliminare l\'elemento multimediale';
|
||||
@override String get rate => 'Valuta';
|
||||
}
|
||||
|
||||
// Path: accessibility
|
||||
@@ -474,6 +479,9 @@ class _TranslationsVideoControlsIt implements TranslationsVideoControlsEn {
|
||||
@override String get versionsButton => 'Versioni video';
|
||||
@override String get pipButton => 'Modalità Picture-in-Picture';
|
||||
@override String get aspectRatioButton => 'Proporzioni';
|
||||
@override String get ambientLighting => 'Illuminazione ambientale';
|
||||
@override String get ambientLightingOn => 'Attiva illuminazione ambientale';
|
||||
@override String get ambientLightingOff => 'Disattiva illuminazione ambientale';
|
||||
@override String get fullscreenButton => 'Attiva schermo intero';
|
||||
@override String get exitFullscreenButton => 'Esci da schermo intero';
|
||||
@override String get alwaysOnTopButton => 'Sempre in primo piano';
|
||||
@@ -485,6 +493,8 @@ class _TranslationsVideoControlsIt implements TranslationsVideoControlsEn {
|
||||
@override late final _TranslationsVideoControlsPipErrorsIt pipErrors = _TranslationsVideoControlsPipErrorsIt._(_root);
|
||||
@override String get chapters => 'Capitoli';
|
||||
@override String get noChaptersAvailable => 'Nessun capitolo disponibile';
|
||||
@override String get queue => 'Queue';
|
||||
@override String get noQueueItems => 'No items in queue';
|
||||
}
|
||||
|
||||
// Path: userStatus
|
||||
@@ -1043,6 +1053,74 @@ class _TranslationsExternalPlayerIt implements TranslationsExternalPlayerEn {
|
||||
@override String get playInExternalPlayer => 'Riproduci in lettore esterno';
|
||||
}
|
||||
|
||||
// Path: metadataEdit
|
||||
class _TranslationsMetadataEditIt implements TranslationsMetadataEditEn {
|
||||
_TranslationsMetadataEditIt._(this._root);
|
||||
|
||||
final TranslationsIt _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get editMetadata => 'Modifica...';
|
||||
@override String get screenTitle => 'Modifica metadati';
|
||||
@override String get basicInfo => 'Informazioni di base';
|
||||
@override String get artwork => 'Artwork';
|
||||
@override String get advancedSettings => 'Impostazioni avanzate';
|
||||
@override String get title => 'Titolo';
|
||||
@override String get sortTitle => 'Titolo di ordinamento';
|
||||
@override String get originalTitle => 'Titolo originale';
|
||||
@override String get releaseDate => 'Data di uscita';
|
||||
@override String get contentRating => 'Classificazione';
|
||||
@override String get studio => 'Studio';
|
||||
@override String get tagline => 'Tagline';
|
||||
@override String get summary => 'Trama';
|
||||
@override String get poster => 'Poster';
|
||||
@override String get background => 'Sfondo';
|
||||
@override String get selectPoster => 'Seleziona poster';
|
||||
@override String get selectBackground => 'Seleziona sfondo';
|
||||
@override String get fromUrl => 'Da URL';
|
||||
@override String get uploadFile => 'Carica file';
|
||||
@override String get enterImageUrl => 'Inserisci URL immagine';
|
||||
@override String get imageUrl => 'URL immagine';
|
||||
@override String get metadataUpdated => 'Metadati aggiornati';
|
||||
@override String get metadataUpdateFailed => 'Aggiornamento metadati non riuscito';
|
||||
@override String get artworkUpdated => 'Artwork aggiornato';
|
||||
@override String get artworkUpdateFailed => 'Aggiornamento artwork non riuscito';
|
||||
@override String get noArtworkAvailable => 'Nessun artwork disponibile';
|
||||
@override String get notSet => 'Non impostato';
|
||||
@override String get libraryDefault => 'Predefinito libreria';
|
||||
@override String get accountDefault => 'Predefinito account';
|
||||
@override String get seriesDefault => 'Predefinito serie';
|
||||
@override String get episodeSorting => 'Ordinamento episodi';
|
||||
@override String get oldestFirst => 'Più vecchi prima';
|
||||
@override String get newestFirst => 'Più recenti prima';
|
||||
@override String get keep => 'Conserva';
|
||||
@override String get allEpisodes => 'Tutti gli episodi';
|
||||
@override String latestEpisodes({required Object count}) => '${count} episodi più recenti';
|
||||
@override String get latestEpisode => 'Episodio più recente';
|
||||
@override String episodesAddedPastDays({required Object count}) => 'Episodi aggiunti negli ultimi ${count} giorni';
|
||||
@override String get deleteAfterPlaying => 'Elimina episodi dopo la riproduzione';
|
||||
@override String get never => 'Mai';
|
||||
@override String get afterADay => 'Dopo un giorno';
|
||||
@override String get afterAWeek => 'Dopo una settimana';
|
||||
@override String get afterAMonth => 'Dopo un mese';
|
||||
@override String get onNextRefresh => 'Al prossimo aggiornamento';
|
||||
@override String get seasons => 'Stagioni';
|
||||
@override String get show => 'Mostra';
|
||||
@override String get hide => 'Nascondi';
|
||||
@override String get episodeOrdering => 'Ordine episodi';
|
||||
@override String get tmdbAiring => 'The Movie Database (In onda)';
|
||||
@override String get tvdbAiring => 'TheTVDB (In onda)';
|
||||
@override String get tvdbAbsolute => 'TheTVDB (Assoluto)';
|
||||
@override String get metadataLanguage => 'Lingua metadati';
|
||||
@override String get useOriginalTitle => 'Usa titolo originale';
|
||||
@override String get preferredAudioLanguage => 'Lingua audio preferita';
|
||||
@override String get preferredSubtitleLanguage => 'Lingua sottotitoli preferita';
|
||||
@override String get subtitleMode => 'Selezione automatica sottotitoli';
|
||||
@override String get manuallySelected => 'Selezionato manualmente';
|
||||
@override String get shownWithForeignAudio => 'Mostrati con audio straniero';
|
||||
@override String get alwaysEnabled => 'Sempre attivo';
|
||||
}
|
||||
|
||||
// Path: hotkeys.actions
|
||||
class _TranslationsHotkeysActionsIt implements TranslationsHotkeysActionsEn {
|
||||
_TranslationsHotkeysActionsIt._(this._root);
|
||||
@@ -1273,6 +1351,7 @@ extension on TranslationsIt {
|
||||
'common.exitConfirmMessage' => 'Sei sicuro di voler uscire?',
|
||||
'common.dontAskAgain' => 'Non chiedere più',
|
||||
'common.exit' => 'Esci',
|
||||
'common.viewAll' => 'Mostra tutto',
|
||||
'screens.licenses' => 'Licenze',
|
||||
'screens.switchProfile' => 'Cambia profilo',
|
||||
'screens.subtitleStyling' => 'Stile sottotitoli',
|
||||
@@ -1340,6 +1419,8 @@ extension on TranslationsIt {
|
||||
'settings.hardwareDecodingDescription' => 'Utilizza l\'accelerazione hardware quando disponibile',
|
||||
'settings.bufferSize' => 'Dimensione buffer',
|
||||
'settings.bufferSizeMB' => ({required Object size}) => '${size}MB',
|
||||
'settings.bufferSizeAuto' => 'Auto (Consigliato)',
|
||||
'settings.bufferSizeWarning' => ({required Object heap, required Object size}) => 'Il tuo dispositivo ha ${heap}MB di memoria. Un buffer di ${size}MB potrebbe causare problemi di riproduzione.',
|
||||
'settings.subtitleStyling' => 'Stile sottotitoli',
|
||||
'settings.subtitleStylingDescription' => 'Personalizza l\'aspetto dei sottotitoli',
|
||||
'settings.smallSkipDuration' => 'Durata skip breve',
|
||||
@@ -1470,6 +1551,7 @@ extension on TranslationsIt {
|
||||
'mediaMenu.deleteMultipleWarning' => 'Potrebbero essere eliminati più elementi.',
|
||||
'mediaMenu.mediaDeletedSuccessfully' => 'Elemento multimediale eliminato con successo',
|
||||
'mediaMenu.mediaFailedToDelete' => 'Impossibile eliminare l\'elemento multimediale',
|
||||
'mediaMenu.rate' => 'Valuta',
|
||||
'accessibility.mediaCardMovie' => ({required Object title}) => '${title}, film',
|
||||
'accessibility.mediaCardShow' => ({required Object title}) => '${title}, serie TV',
|
||||
'accessibility.mediaCardEpisode' => ({required Object title, required Object episodeInfo}) => '${title}, ${episodeInfo}',
|
||||
@@ -1517,6 +1599,9 @@ extension on TranslationsIt {
|
||||
'videoControls.versionsButton' => 'Versioni video',
|
||||
'videoControls.pipButton' => 'Modalità Picture-in-Picture',
|
||||
'videoControls.aspectRatioButton' => 'Proporzioni',
|
||||
'videoControls.ambientLighting' => 'Illuminazione ambientale',
|
||||
'videoControls.ambientLightingOn' => 'Attiva illuminazione ambientale',
|
||||
'videoControls.ambientLightingOff' => 'Disattiva illuminazione ambientale',
|
||||
'videoControls.fullscreenButton' => 'Attiva schermo intero',
|
||||
'videoControls.exitFullscreenButton' => 'Esci da schermo intero',
|
||||
'videoControls.alwaysOnTopButton' => 'Sempre in primo piano',
|
||||
@@ -1532,6 +1617,8 @@ extension on TranslationsIt {
|
||||
'videoControls.pipErrors.unknown' => ({required Object error}) => 'Si è verificato un errore: ${error}',
|
||||
'videoControls.chapters' => 'Capitoli',
|
||||
'videoControls.noChaptersAvailable' => 'Nessun capitolo disponibile',
|
||||
'videoControls.queue' => 'Queue',
|
||||
'videoControls.noQueueItems' => 'No items in queue',
|
||||
'userStatus.admin' => 'Admin',
|
||||
'userStatus.restricted' => 'Limitato',
|
||||
'userStatus.protected' => 'Protetto',
|
||||
@@ -1728,6 +1815,8 @@ extension on TranslationsIt {
|
||||
'liveTv.reloadGuide' => 'Ricarica guida',
|
||||
'liveTv.guideReloaded' => 'Dati della guida ricaricati',
|
||||
'liveTv.allChannels' => 'Tutti i canali',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.now' => 'Ora',
|
||||
'liveTv.today' => 'Oggi',
|
||||
'liveTv.midnight' => 'Mezzanotte',
|
||||
@@ -1737,8 +1826,6 @@ extension on TranslationsIt {
|
||||
'liveTv.evening' => 'Sera',
|
||||
'liveTv.lateNight' => 'Notte tarda',
|
||||
'liveTv.whatsOn' => 'In onda ora',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.watchChannel' => 'Guarda canale',
|
||||
'downloads.title' => 'Download',
|
||||
'downloads.manage' => 'Gestisci',
|
||||
@@ -1965,6 +2052,65 @@ extension on TranslationsIt {
|
||||
'externalPlayer.launchFailed' => 'Impossibile aprire il lettore esterno',
|
||||
'externalPlayer.appNotInstalled' => ({required Object name}) => '${name} non è installato',
|
||||
'externalPlayer.playInExternalPlayer' => 'Riproduci in lettore esterno',
|
||||
'metadataEdit.editMetadata' => 'Modifica...',
|
||||
'metadataEdit.screenTitle' => 'Modifica metadati',
|
||||
'metadataEdit.basicInfo' => 'Informazioni di base',
|
||||
'metadataEdit.artwork' => 'Artwork',
|
||||
'metadataEdit.advancedSettings' => 'Impostazioni avanzate',
|
||||
'metadataEdit.title' => 'Titolo',
|
||||
'metadataEdit.sortTitle' => 'Titolo di ordinamento',
|
||||
'metadataEdit.originalTitle' => 'Titolo originale',
|
||||
'metadataEdit.releaseDate' => 'Data di uscita',
|
||||
'metadataEdit.contentRating' => 'Classificazione',
|
||||
'metadataEdit.studio' => 'Studio',
|
||||
'metadataEdit.tagline' => 'Tagline',
|
||||
'metadataEdit.summary' => 'Trama',
|
||||
'metadataEdit.poster' => 'Poster',
|
||||
'metadataEdit.background' => 'Sfondo',
|
||||
'metadataEdit.selectPoster' => 'Seleziona poster',
|
||||
'metadataEdit.selectBackground' => 'Seleziona sfondo',
|
||||
'metadataEdit.fromUrl' => 'Da URL',
|
||||
'metadataEdit.uploadFile' => 'Carica file',
|
||||
'metadataEdit.enterImageUrl' => 'Inserisci URL immagine',
|
||||
'metadataEdit.imageUrl' => 'URL immagine',
|
||||
'metadataEdit.metadataUpdated' => 'Metadati aggiornati',
|
||||
'metadataEdit.metadataUpdateFailed' => 'Aggiornamento metadati non riuscito',
|
||||
'metadataEdit.artworkUpdated' => 'Artwork aggiornato',
|
||||
'metadataEdit.artworkUpdateFailed' => 'Aggiornamento artwork non riuscito',
|
||||
'metadataEdit.noArtworkAvailable' => 'Nessun artwork disponibile',
|
||||
'metadataEdit.notSet' => 'Non impostato',
|
||||
'metadataEdit.libraryDefault' => 'Predefinito libreria',
|
||||
'metadataEdit.accountDefault' => 'Predefinito account',
|
||||
'metadataEdit.seriesDefault' => 'Predefinito serie',
|
||||
'metadataEdit.episodeSorting' => 'Ordinamento episodi',
|
||||
'metadataEdit.oldestFirst' => 'Più vecchi prima',
|
||||
'metadataEdit.newestFirst' => 'Più recenti prima',
|
||||
'metadataEdit.keep' => 'Conserva',
|
||||
'metadataEdit.allEpisodes' => 'Tutti gli episodi',
|
||||
'metadataEdit.latestEpisodes' => ({required Object count}) => '${count} episodi più recenti',
|
||||
'metadataEdit.latestEpisode' => 'Episodio più recente',
|
||||
'metadataEdit.episodesAddedPastDays' => ({required Object count}) => 'Episodi aggiunti negli ultimi ${count} giorni',
|
||||
'metadataEdit.deleteAfterPlaying' => 'Elimina episodi dopo la riproduzione',
|
||||
'metadataEdit.never' => 'Mai',
|
||||
'metadataEdit.afterADay' => 'Dopo un giorno',
|
||||
'metadataEdit.afterAWeek' => 'Dopo una settimana',
|
||||
'metadataEdit.afterAMonth' => 'Dopo un mese',
|
||||
'metadataEdit.onNextRefresh' => 'Al prossimo aggiornamento',
|
||||
'metadataEdit.seasons' => 'Stagioni',
|
||||
'metadataEdit.show' => 'Mostra',
|
||||
'metadataEdit.hide' => 'Nascondi',
|
||||
'metadataEdit.episodeOrdering' => 'Ordine episodi',
|
||||
'metadataEdit.tmdbAiring' => 'The Movie Database (In onda)',
|
||||
'metadataEdit.tvdbAiring' => 'TheTVDB (In onda)',
|
||||
'metadataEdit.tvdbAbsolute' => 'TheTVDB (Assoluto)',
|
||||
'metadataEdit.metadataLanguage' => 'Lingua metadati',
|
||||
'metadataEdit.useOriginalTitle' => 'Usa titolo originale',
|
||||
'metadataEdit.preferredAudioLanguage' => 'Lingua audio preferita',
|
||||
'metadataEdit.preferredSubtitleLanguage' => 'Lingua sottotitoli preferita',
|
||||
'metadataEdit.subtitleMode' => 'Selezione automatica sottotitoli',
|
||||
'metadataEdit.manuallySelected' => 'Selezionato manualmente',
|
||||
'metadataEdit.shownWithForeignAudio' => 'Mostrati con audio straniero',
|
||||
'metadataEdit.alwaysEnabled' => 'Sempre attivo',
|
||||
_ => null,
|
||||
};
|
||||
}
|
||||
|
||||
+148
-2
@@ -74,6 +74,7 @@ class TranslationsKo with BaseTranslations<AppLocale, Translations> implements T
|
||||
@override late final _TranslationsCompanionRemoteKo companionRemote = _TranslationsCompanionRemoteKo._(_root);
|
||||
@override late final _TranslationsVideoSettingsKo videoSettings = _TranslationsVideoSettingsKo._(_root);
|
||||
@override late final _TranslationsExternalPlayerKo externalPlayer = _TranslationsExternalPlayerKo._(_root);
|
||||
@override late final _TranslationsMetadataEditKo metadataEdit = _TranslationsMetadataEditKo._(_root);
|
||||
}
|
||||
|
||||
// Path: app
|
||||
@@ -149,6 +150,7 @@ class _TranslationsCommonKo implements TranslationsCommonEn {
|
||||
@override String get exitConfirmMessage => '정말 종료하시겠습니까?';
|
||||
@override String get dontAskAgain => '다시 묻지 않기';
|
||||
@override String get exit => '종료';
|
||||
@override String get viewAll => '모두 보기';
|
||||
}
|
||||
|
||||
// Path: screens
|
||||
@@ -243,6 +245,8 @@ class _TranslationsSettingsKo implements TranslationsSettingsEn {
|
||||
@override String get hardwareDecodingDescription => '가능한 경우 하드웨어 가속을 사용합니다';
|
||||
@override String get bufferSize => '버퍼 크기';
|
||||
@override String bufferSizeMB({required Object size}) => '${size}MB';
|
||||
@override String get bufferSizeAuto => '자동 (권장)';
|
||||
@override String bufferSizeWarning({required Object heap, required Object size}) => '기기 메모리가 ${heap}MB입니다. ${size}MB 버퍼는 재생 문제를 일으킬 수 있습니다.';
|
||||
@override String get subtitleStyling => '자막 스타일';
|
||||
@override String get subtitleStylingDescription => '자막의 외형을 사용자 설정';
|
||||
@override String get smallSkipDuration => '짧은 건너뛰기 시간';
|
||||
@@ -400,6 +404,7 @@ class _TranslationsMediaMenuKo implements TranslationsMediaMenuEn {
|
||||
@override String get deleteMultipleWarning => '여러 항목이 삭제될 수 있습니다.';
|
||||
@override String get mediaDeletedSuccessfully => '미디어 항목이 성공적으로 삭제되었습니다';
|
||||
@override String get mediaFailedToDelete => '미디어 항목 삭제 실패';
|
||||
@override String get rate => '평가';
|
||||
}
|
||||
|
||||
// Path: accessibility
|
||||
@@ -474,6 +479,9 @@ class _TranslationsVideoControlsKo implements TranslationsVideoControlsEn {
|
||||
@override String get versionsButton => '동영상 버전';
|
||||
@override String get pipButton => '픽처 인 픽처 모드';
|
||||
@override String get aspectRatioButton => '화면비율';
|
||||
@override String get ambientLighting => '주변 조명';
|
||||
@override String get ambientLightingOn => '주변 조명 켜기';
|
||||
@override String get ambientLightingOff => '주변 조명 끄기';
|
||||
@override String get fullscreenButton => '전체화면';
|
||||
@override String get exitFullscreenButton => '전체화면 종료';
|
||||
@override String get alwaysOnTopButton => '창 최상위 고정';
|
||||
@@ -485,6 +493,8 @@ class _TranslationsVideoControlsKo implements TranslationsVideoControlsEn {
|
||||
@override late final _TranslationsVideoControlsPipErrorsKo pipErrors = _TranslationsVideoControlsPipErrorsKo._(_root);
|
||||
@override String get chapters => '챕터';
|
||||
@override String get noChaptersAvailable => '사용 가능한 챕터가 없습니다';
|
||||
@override String get queue => 'Queue';
|
||||
@override String get noQueueItems => 'No items in queue';
|
||||
}
|
||||
|
||||
// Path: userStatus
|
||||
@@ -1043,6 +1053,74 @@ class _TranslationsExternalPlayerKo implements TranslationsExternalPlayerEn {
|
||||
@override String get playInExternalPlayer => '외부 플레이어에서 재생';
|
||||
}
|
||||
|
||||
// Path: metadataEdit
|
||||
class _TranslationsMetadataEditKo implements TranslationsMetadataEditEn {
|
||||
_TranslationsMetadataEditKo._(this._root);
|
||||
|
||||
final TranslationsKo _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get editMetadata => '편집...';
|
||||
@override String get screenTitle => '메타데이터 편집';
|
||||
@override String get basicInfo => '기본 정보';
|
||||
@override String get artwork => '아트워크';
|
||||
@override String get advancedSettings => '고급 설정';
|
||||
@override String get title => '제목';
|
||||
@override String get sortTitle => '정렬 제목';
|
||||
@override String get originalTitle => '원제';
|
||||
@override String get releaseDate => '출시일';
|
||||
@override String get contentRating => '콘텐츠 등급';
|
||||
@override String get studio => '스튜디오';
|
||||
@override String get tagline => '태그라인';
|
||||
@override String get summary => '줄거리';
|
||||
@override String get poster => '포스터';
|
||||
@override String get background => '배경';
|
||||
@override String get selectPoster => '포스터 선택';
|
||||
@override String get selectBackground => '배경 선택';
|
||||
@override String get fromUrl => 'URL에서';
|
||||
@override String get uploadFile => '파일 업로드';
|
||||
@override String get enterImageUrl => '이미지 URL 입력';
|
||||
@override String get imageUrl => '이미지 URL';
|
||||
@override String get metadataUpdated => '메타데이터가 업데이트되었습니다';
|
||||
@override String get metadataUpdateFailed => '메타데이터 업데이트 실패';
|
||||
@override String get artworkUpdated => '아트워크가 업데이트되었습니다';
|
||||
@override String get artworkUpdateFailed => '아트워크 업데이트 실패';
|
||||
@override String get noArtworkAvailable => '사용 가능한 아트워크 없음';
|
||||
@override String get notSet => '설정되지 않음';
|
||||
@override String get libraryDefault => '라이브러리 기본값';
|
||||
@override String get accountDefault => '계정 기본값';
|
||||
@override String get seriesDefault => '시리즈 기본값';
|
||||
@override String get episodeSorting => '에피소드 정렬';
|
||||
@override String get oldestFirst => '오래된 순';
|
||||
@override String get newestFirst => '최신 순';
|
||||
@override String get keep => '유지';
|
||||
@override String get allEpisodes => '모든 에피소드';
|
||||
@override String latestEpisodes({required Object count}) => '최신 에피소드 ${count}개';
|
||||
@override String get latestEpisode => '최신 에피소드';
|
||||
@override String episodesAddedPastDays({required Object count}) => '최근 ${count}일 내 추가된 에피소드';
|
||||
@override String get deleteAfterPlaying => '재생 후 에피소드 삭제';
|
||||
@override String get never => '안 함';
|
||||
@override String get afterADay => '하루 후';
|
||||
@override String get afterAWeek => '일주일 후';
|
||||
@override String get afterAMonth => '한 달 후';
|
||||
@override String get onNextRefresh => '다음 새로고침 시';
|
||||
@override String get seasons => '시즌';
|
||||
@override String get show => '표시';
|
||||
@override String get hide => '숨기기';
|
||||
@override String get episodeOrdering => '에피소드 순서';
|
||||
@override String get tmdbAiring => 'The Movie Database (방영순)';
|
||||
@override String get tvdbAiring => 'TheTVDB (방영순)';
|
||||
@override String get tvdbAbsolute => 'TheTVDB (절대순)';
|
||||
@override String get metadataLanguage => '메타데이터 언어';
|
||||
@override String get useOriginalTitle => '원제 사용';
|
||||
@override String get preferredAudioLanguage => '선호 오디오 언어';
|
||||
@override String get preferredSubtitleLanguage => '선호 자막 언어';
|
||||
@override String get subtitleMode => '자막 자동 선택 모드';
|
||||
@override String get manuallySelected => '수동 선택';
|
||||
@override String get shownWithForeignAudio => '외국어 오디오 시 표시';
|
||||
@override String get alwaysEnabled => '항상 활성화';
|
||||
}
|
||||
|
||||
// Path: hotkeys.actions
|
||||
class _TranslationsHotkeysActionsKo implements TranslationsHotkeysActionsEn {
|
||||
_TranslationsHotkeysActionsKo._(this._root);
|
||||
@@ -1273,6 +1351,7 @@ extension on TranslationsKo {
|
||||
'common.exitConfirmMessage' => '정말 종료하시겠습니까?',
|
||||
'common.dontAskAgain' => '다시 묻지 않기',
|
||||
'common.exit' => '종료',
|
||||
'common.viewAll' => '모두 보기',
|
||||
'screens.licenses' => '라이선스',
|
||||
'screens.switchProfile' => '프로필 전환',
|
||||
'screens.subtitleStyling' => '자막 스타일 설정',
|
||||
@@ -1340,6 +1419,8 @@ extension on TranslationsKo {
|
||||
'settings.hardwareDecodingDescription' => '가능한 경우 하드웨어 가속을 사용합니다',
|
||||
'settings.bufferSize' => '버퍼 크기',
|
||||
'settings.bufferSizeMB' => ({required Object size}) => '${size}MB',
|
||||
'settings.bufferSizeAuto' => '자동 (권장)',
|
||||
'settings.bufferSizeWarning' => ({required Object heap, required Object size}) => '기기 메모리가 ${heap}MB입니다. ${size}MB 버퍼는 재생 문제를 일으킬 수 있습니다.',
|
||||
'settings.subtitleStyling' => '자막 스타일',
|
||||
'settings.subtitleStylingDescription' => '자막의 외형을 사용자 설정',
|
||||
'settings.smallSkipDuration' => '짧은 건너뛰기 시간',
|
||||
@@ -1470,6 +1551,7 @@ extension on TranslationsKo {
|
||||
'mediaMenu.deleteMultipleWarning' => '여러 항목이 삭제될 수 있습니다.',
|
||||
'mediaMenu.mediaDeletedSuccessfully' => '미디어 항목이 성공적으로 삭제되었습니다',
|
||||
'mediaMenu.mediaFailedToDelete' => '미디어 항목 삭제 실패',
|
||||
'mediaMenu.rate' => '평가',
|
||||
'accessibility.mediaCardMovie' => ({required Object title}) => '${title}, 영화',
|
||||
'accessibility.mediaCardShow' => ({required Object title}) => '${title}, TV 프로그램',
|
||||
'accessibility.mediaCardEpisode' => ({required Object title, required Object episodeInfo}) => '${title}, ${episodeInfo}',
|
||||
@@ -1517,6 +1599,9 @@ extension on TranslationsKo {
|
||||
'videoControls.versionsButton' => '동영상 버전',
|
||||
'videoControls.pipButton' => '픽처 인 픽처 모드',
|
||||
'videoControls.aspectRatioButton' => '화면비율',
|
||||
'videoControls.ambientLighting' => '주변 조명',
|
||||
'videoControls.ambientLightingOn' => '주변 조명 켜기',
|
||||
'videoControls.ambientLightingOff' => '주변 조명 끄기',
|
||||
'videoControls.fullscreenButton' => '전체화면',
|
||||
'videoControls.exitFullscreenButton' => '전체화면 종료',
|
||||
'videoControls.alwaysOnTopButton' => '창 최상위 고정',
|
||||
@@ -1532,6 +1617,8 @@ extension on TranslationsKo {
|
||||
'videoControls.pipErrors.unknown' => ({required Object error}) => '오류가 발생했습니다: ${error}',
|
||||
'videoControls.chapters' => '챕터',
|
||||
'videoControls.noChaptersAvailable' => '사용 가능한 챕터가 없습니다',
|
||||
'videoControls.queue' => 'Queue',
|
||||
'videoControls.noQueueItems' => 'No items in queue',
|
||||
'userStatus.admin' => '관리자',
|
||||
'userStatus.restricted' => '제한됨',
|
||||
'userStatus.protected' => '보호됨',
|
||||
@@ -1728,6 +1815,8 @@ extension on TranslationsKo {
|
||||
'liveTv.reloadGuide' => '편성표 새로고침',
|
||||
'liveTv.guideReloaded' => '편성표 데이터가 새로고침되었습니다',
|
||||
'liveTv.allChannels' => '전체 채널',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.now' => '지금',
|
||||
'liveTv.today' => '오늘',
|
||||
'liveTv.midnight' => '자정',
|
||||
@@ -1737,8 +1826,6 @@ extension on TranslationsKo {
|
||||
'liveTv.evening' => '저녁',
|
||||
'liveTv.lateNight' => '심야 방송',
|
||||
'liveTv.whatsOn' => '지금 방송 중',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.watchChannel' => '채널 시청',
|
||||
'collections.title' => '컬렉션',
|
||||
'collections.collection' => '컬렉션',
|
||||
@@ -1965,6 +2052,65 @@ extension on TranslationsKo {
|
||||
'externalPlayer.launchFailed' => '외부 플레이어를 열 수 없습니다',
|
||||
'externalPlayer.appNotInstalled' => ({required Object name}) => '${name}이(가) 설치되어 있지 않습니다',
|
||||
'externalPlayer.playInExternalPlayer' => '외부 플레이어에서 재생',
|
||||
'metadataEdit.editMetadata' => '편집...',
|
||||
'metadataEdit.screenTitle' => '메타데이터 편집',
|
||||
'metadataEdit.basicInfo' => '기본 정보',
|
||||
'metadataEdit.artwork' => '아트워크',
|
||||
'metadataEdit.advancedSettings' => '고급 설정',
|
||||
'metadataEdit.title' => '제목',
|
||||
'metadataEdit.sortTitle' => '정렬 제목',
|
||||
'metadataEdit.originalTitle' => '원제',
|
||||
'metadataEdit.releaseDate' => '출시일',
|
||||
'metadataEdit.contentRating' => '콘텐츠 등급',
|
||||
'metadataEdit.studio' => '스튜디오',
|
||||
'metadataEdit.tagline' => '태그라인',
|
||||
'metadataEdit.summary' => '줄거리',
|
||||
'metadataEdit.poster' => '포스터',
|
||||
'metadataEdit.background' => '배경',
|
||||
'metadataEdit.selectPoster' => '포스터 선택',
|
||||
'metadataEdit.selectBackground' => '배경 선택',
|
||||
'metadataEdit.fromUrl' => 'URL에서',
|
||||
'metadataEdit.uploadFile' => '파일 업로드',
|
||||
'metadataEdit.enterImageUrl' => '이미지 URL 입력',
|
||||
'metadataEdit.imageUrl' => '이미지 URL',
|
||||
'metadataEdit.metadataUpdated' => '메타데이터가 업데이트되었습니다',
|
||||
'metadataEdit.metadataUpdateFailed' => '메타데이터 업데이트 실패',
|
||||
'metadataEdit.artworkUpdated' => '아트워크가 업데이트되었습니다',
|
||||
'metadataEdit.artworkUpdateFailed' => '아트워크 업데이트 실패',
|
||||
'metadataEdit.noArtworkAvailable' => '사용 가능한 아트워크 없음',
|
||||
'metadataEdit.notSet' => '설정되지 않음',
|
||||
'metadataEdit.libraryDefault' => '라이브러리 기본값',
|
||||
'metadataEdit.accountDefault' => '계정 기본값',
|
||||
'metadataEdit.seriesDefault' => '시리즈 기본값',
|
||||
'metadataEdit.episodeSorting' => '에피소드 정렬',
|
||||
'metadataEdit.oldestFirst' => '오래된 순',
|
||||
'metadataEdit.newestFirst' => '최신 순',
|
||||
'metadataEdit.keep' => '유지',
|
||||
'metadataEdit.allEpisodes' => '모든 에피소드',
|
||||
'metadataEdit.latestEpisodes' => ({required Object count}) => '최신 에피소드 ${count}개',
|
||||
'metadataEdit.latestEpisode' => '최신 에피소드',
|
||||
'metadataEdit.episodesAddedPastDays' => ({required Object count}) => '최근 ${count}일 내 추가된 에피소드',
|
||||
'metadataEdit.deleteAfterPlaying' => '재생 후 에피소드 삭제',
|
||||
'metadataEdit.never' => '안 함',
|
||||
'metadataEdit.afterADay' => '하루 후',
|
||||
'metadataEdit.afterAWeek' => '일주일 후',
|
||||
'metadataEdit.afterAMonth' => '한 달 후',
|
||||
'metadataEdit.onNextRefresh' => '다음 새로고침 시',
|
||||
'metadataEdit.seasons' => '시즌',
|
||||
'metadataEdit.show' => '표시',
|
||||
'metadataEdit.hide' => '숨기기',
|
||||
'metadataEdit.episodeOrdering' => '에피소드 순서',
|
||||
'metadataEdit.tmdbAiring' => 'The Movie Database (방영순)',
|
||||
'metadataEdit.tvdbAiring' => 'TheTVDB (방영순)',
|
||||
'metadataEdit.tvdbAbsolute' => 'TheTVDB (절대순)',
|
||||
'metadataEdit.metadataLanguage' => '메타데이터 언어',
|
||||
'metadataEdit.useOriginalTitle' => '원제 사용',
|
||||
'metadataEdit.preferredAudioLanguage' => '선호 오디오 언어',
|
||||
'metadataEdit.preferredSubtitleLanguage' => '선호 자막 언어',
|
||||
'metadataEdit.subtitleMode' => '자막 자동 선택 모드',
|
||||
'metadataEdit.manuallySelected' => '수동 선택',
|
||||
'metadataEdit.shownWithForeignAudio' => '외국어 오디오 시 표시',
|
||||
'metadataEdit.alwaysEnabled' => '항상 활성화',
|
||||
_ => null,
|
||||
};
|
||||
}
|
||||
|
||||
+148
-2
@@ -74,6 +74,7 @@ class TranslationsNl with BaseTranslations<AppLocale, Translations> implements T
|
||||
@override late final _TranslationsCompanionRemoteNl companionRemote = _TranslationsCompanionRemoteNl._(_root);
|
||||
@override late final _TranslationsVideoSettingsNl videoSettings = _TranslationsVideoSettingsNl._(_root);
|
||||
@override late final _TranslationsExternalPlayerNl externalPlayer = _TranslationsExternalPlayerNl._(_root);
|
||||
@override late final _TranslationsMetadataEditNl metadataEdit = _TranslationsMetadataEditNl._(_root);
|
||||
}
|
||||
|
||||
// Path: app
|
||||
@@ -149,6 +150,7 @@ class _TranslationsCommonNl implements TranslationsCommonEn {
|
||||
@override String get exitConfirmMessage => 'Weet je zeker dat je wilt afsluiten?';
|
||||
@override String get dontAskAgain => 'Niet meer vragen';
|
||||
@override String get exit => 'Afsluiten';
|
||||
@override String get viewAll => 'Alles weergeven';
|
||||
}
|
||||
|
||||
// Path: screens
|
||||
@@ -243,6 +245,8 @@ class _TranslationsSettingsNl implements TranslationsSettingsEn {
|
||||
@override String get hardwareDecodingDescription => 'Gebruik hardware versnelling indien beschikbaar';
|
||||
@override String get bufferSize => 'Buffer grootte';
|
||||
@override String bufferSizeMB({required Object size}) => '${size}MB';
|
||||
@override String get bufferSizeAuto => 'Auto (Aanbevolen)';
|
||||
@override String bufferSizeWarning({required Object heap, required Object size}) => 'Je apparaat heeft ${heap}MB geheugen. Een buffer van ${size}MB kan afspeelproblemen veroorzaken.';
|
||||
@override String get subtitleStyling => 'Ondertitel opmaak';
|
||||
@override String get subtitleStylingDescription => 'Pas ondertitel uiterlijk aan';
|
||||
@override String get smallSkipDuration => 'Korte skip duur';
|
||||
@@ -400,6 +404,7 @@ class _TranslationsMediaMenuNl implements TranslationsMediaMenuEn {
|
||||
@override String get deleteMultipleWarning => 'Meerdere items kunnen worden verwijderd.';
|
||||
@override String get mediaDeletedSuccessfully => 'Media-item succesvol verwijderd';
|
||||
@override String get mediaFailedToDelete => 'Verwijderen van media-item mislukt';
|
||||
@override String get rate => 'Beoordelen';
|
||||
}
|
||||
|
||||
// Path: accessibility
|
||||
@@ -474,6 +479,9 @@ class _TranslationsVideoControlsNl implements TranslationsVideoControlsEn {
|
||||
@override String get versionsButton => 'Videoversies';
|
||||
@override String get pipButton => 'Beeld-in-beeld modus';
|
||||
@override String get aspectRatioButton => 'Beeldverhouding';
|
||||
@override String get ambientLighting => 'Omgevingsverlichting';
|
||||
@override String get ambientLightingOn => 'Omgevingsverlichting inschakelen';
|
||||
@override String get ambientLightingOff => 'Omgevingsverlichting uitschakelen';
|
||||
@override String get fullscreenButton => 'Volledig scherm activeren';
|
||||
@override String get exitFullscreenButton => 'Volledig scherm verlaten';
|
||||
@override String get alwaysOnTopButton => 'Altijd bovenop';
|
||||
@@ -485,6 +493,8 @@ class _TranslationsVideoControlsNl implements TranslationsVideoControlsEn {
|
||||
@override late final _TranslationsVideoControlsPipErrorsNl pipErrors = _TranslationsVideoControlsPipErrorsNl._(_root);
|
||||
@override String get chapters => 'Hoofdstukken';
|
||||
@override String get noChaptersAvailable => 'Geen hoofdstukken beschikbaar';
|
||||
@override String get queue => 'Queue';
|
||||
@override String get noQueueItems => 'No items in queue';
|
||||
}
|
||||
|
||||
// Path: userStatus
|
||||
@@ -1043,6 +1053,74 @@ class _TranslationsExternalPlayerNl implements TranslationsExternalPlayerEn {
|
||||
@override String get playInExternalPlayer => 'Afspelen in externe speler';
|
||||
}
|
||||
|
||||
// Path: metadataEdit
|
||||
class _TranslationsMetadataEditNl implements TranslationsMetadataEditEn {
|
||||
_TranslationsMetadataEditNl._(this._root);
|
||||
|
||||
final TranslationsNl _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get editMetadata => 'Bewerken...';
|
||||
@override String get screenTitle => 'Metadata bewerken';
|
||||
@override String get basicInfo => 'Basisinformatie';
|
||||
@override String get artwork => 'Artwork';
|
||||
@override String get advancedSettings => 'Geavanceerde instellingen';
|
||||
@override String get title => 'Titel';
|
||||
@override String get sortTitle => 'Sorteertitel';
|
||||
@override String get originalTitle => 'Oorspronkelijke titel';
|
||||
@override String get releaseDate => 'Releasedatum';
|
||||
@override String get contentRating => 'Leeftijdsclassificatie';
|
||||
@override String get studio => 'Studio';
|
||||
@override String get tagline => 'Tagline';
|
||||
@override String get summary => 'Samenvatting';
|
||||
@override String get poster => 'Poster';
|
||||
@override String get background => 'Achtergrond';
|
||||
@override String get selectPoster => 'Poster selecteren';
|
||||
@override String get selectBackground => 'Achtergrond selecteren';
|
||||
@override String get fromUrl => 'Vanaf URL';
|
||||
@override String get uploadFile => 'Bestand uploaden';
|
||||
@override String get enterImageUrl => 'Voer afbeeldings-URL in';
|
||||
@override String get imageUrl => 'Afbeeldings-URL';
|
||||
@override String get metadataUpdated => 'Metadata bijgewerkt';
|
||||
@override String get metadataUpdateFailed => 'Metadata bijwerken mislukt';
|
||||
@override String get artworkUpdated => 'Artwork bijgewerkt';
|
||||
@override String get artworkUpdateFailed => 'Artwork bijwerken mislukt';
|
||||
@override String get noArtworkAvailable => 'Geen artwork beschikbaar';
|
||||
@override String get notSet => 'Niet ingesteld';
|
||||
@override String get libraryDefault => 'Bibliotheekstandaard';
|
||||
@override String get accountDefault => 'Accountstandaard';
|
||||
@override String get seriesDefault => 'Seriestandaard';
|
||||
@override String get episodeSorting => 'Afleveringen sorteren';
|
||||
@override String get oldestFirst => 'Oudste eerst';
|
||||
@override String get newestFirst => 'Nieuwste eerst';
|
||||
@override String get keep => 'Bewaren';
|
||||
@override String get allEpisodes => 'Alle afleveringen';
|
||||
@override String latestEpisodes({required Object count}) => '${count} nieuwste afleveringen';
|
||||
@override String get latestEpisode => 'Nieuwste aflevering';
|
||||
@override String episodesAddedPastDays({required Object count}) => 'Afleveringen toegevoegd in de afgelopen ${count} dagen';
|
||||
@override String get deleteAfterPlaying => 'Afleveringen verwijderen na afspelen';
|
||||
@override String get never => 'Nooit';
|
||||
@override String get afterADay => 'Na een dag';
|
||||
@override String get afterAWeek => 'Na een week';
|
||||
@override String get afterAMonth => 'Na een maand';
|
||||
@override String get onNextRefresh => 'Bij volgende verversing';
|
||||
@override String get seasons => 'Seizoenen';
|
||||
@override String get show => 'Tonen';
|
||||
@override String get hide => 'Verbergen';
|
||||
@override String get episodeOrdering => 'Afleveringsvolgorde';
|
||||
@override String get tmdbAiring => 'The Movie Database (Uitgezonden)';
|
||||
@override String get tvdbAiring => 'TheTVDB (Uitgezonden)';
|
||||
@override String get tvdbAbsolute => 'TheTVDB (Absoluut)';
|
||||
@override String get metadataLanguage => 'Metadatataal';
|
||||
@override String get useOriginalTitle => 'Oorspronkelijke titel gebruiken';
|
||||
@override String get preferredAudioLanguage => 'Voorkeurstaal audio';
|
||||
@override String get preferredSubtitleLanguage => 'Voorkeurstaal ondertiteling';
|
||||
@override String get subtitleMode => 'Automatische ondertitelselectie';
|
||||
@override String get manuallySelected => 'Handmatig geselecteerd';
|
||||
@override String get shownWithForeignAudio => 'Weergeven bij anderstalig geluid';
|
||||
@override String get alwaysEnabled => 'Altijd ingeschakeld';
|
||||
}
|
||||
|
||||
// Path: hotkeys.actions
|
||||
class _TranslationsHotkeysActionsNl implements TranslationsHotkeysActionsEn {
|
||||
_TranslationsHotkeysActionsNl._(this._root);
|
||||
@@ -1273,6 +1351,7 @@ extension on TranslationsNl {
|
||||
'common.exitConfirmMessage' => 'Weet je zeker dat je wilt afsluiten?',
|
||||
'common.dontAskAgain' => 'Niet meer vragen',
|
||||
'common.exit' => 'Afsluiten',
|
||||
'common.viewAll' => 'Alles weergeven',
|
||||
'screens.licenses' => 'Licenties',
|
||||
'screens.switchProfile' => 'Wissel van profiel',
|
||||
'screens.subtitleStyling' => 'Ondertitel opmaak',
|
||||
@@ -1340,6 +1419,8 @@ extension on TranslationsNl {
|
||||
'settings.hardwareDecodingDescription' => 'Gebruik hardware versnelling indien beschikbaar',
|
||||
'settings.bufferSize' => 'Buffer grootte',
|
||||
'settings.bufferSizeMB' => ({required Object size}) => '${size}MB',
|
||||
'settings.bufferSizeAuto' => 'Auto (Aanbevolen)',
|
||||
'settings.bufferSizeWarning' => ({required Object heap, required Object size}) => 'Je apparaat heeft ${heap}MB geheugen. Een buffer van ${size}MB kan afspeelproblemen veroorzaken.',
|
||||
'settings.subtitleStyling' => 'Ondertitel opmaak',
|
||||
'settings.subtitleStylingDescription' => 'Pas ondertitel uiterlijk aan',
|
||||
'settings.smallSkipDuration' => 'Korte skip duur',
|
||||
@@ -1470,6 +1551,7 @@ extension on TranslationsNl {
|
||||
'mediaMenu.deleteMultipleWarning' => 'Meerdere items kunnen worden verwijderd.',
|
||||
'mediaMenu.mediaDeletedSuccessfully' => 'Media-item succesvol verwijderd',
|
||||
'mediaMenu.mediaFailedToDelete' => 'Verwijderen van media-item mislukt',
|
||||
'mediaMenu.rate' => 'Beoordelen',
|
||||
'accessibility.mediaCardMovie' => ({required Object title}) => '${title}, film',
|
||||
'accessibility.mediaCardShow' => ({required Object title}) => '${title}, TV-serie',
|
||||
'accessibility.mediaCardEpisode' => ({required Object title, required Object episodeInfo}) => '${title}, ${episodeInfo}',
|
||||
@@ -1517,6 +1599,9 @@ extension on TranslationsNl {
|
||||
'videoControls.versionsButton' => 'Videoversies',
|
||||
'videoControls.pipButton' => 'Beeld-in-beeld modus',
|
||||
'videoControls.aspectRatioButton' => 'Beeldverhouding',
|
||||
'videoControls.ambientLighting' => 'Omgevingsverlichting',
|
||||
'videoControls.ambientLightingOn' => 'Omgevingsverlichting inschakelen',
|
||||
'videoControls.ambientLightingOff' => 'Omgevingsverlichting uitschakelen',
|
||||
'videoControls.fullscreenButton' => 'Volledig scherm activeren',
|
||||
'videoControls.exitFullscreenButton' => 'Volledig scherm verlaten',
|
||||
'videoControls.alwaysOnTopButton' => 'Altijd bovenop',
|
||||
@@ -1532,6 +1617,8 @@ extension on TranslationsNl {
|
||||
'videoControls.pipErrors.unknown' => ({required Object error}) => 'Er is een fout opgetreden: ${error}',
|
||||
'videoControls.chapters' => 'Hoofdstukken',
|
||||
'videoControls.noChaptersAvailable' => 'Geen hoofdstukken beschikbaar',
|
||||
'videoControls.queue' => 'Queue',
|
||||
'videoControls.noQueueItems' => 'No items in queue',
|
||||
'userStatus.admin' => 'Beheerder',
|
||||
'userStatus.restricted' => 'Beperkt',
|
||||
'userStatus.protected' => 'Beschermd',
|
||||
@@ -1728,6 +1815,8 @@ extension on TranslationsNl {
|
||||
'liveTv.reloadGuide' => 'Gids herladen',
|
||||
'liveTv.guideReloaded' => 'Gidsgegevens herladen',
|
||||
'liveTv.allChannels' => 'Alle zenders',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.now' => 'Nu',
|
||||
'liveTv.today' => 'Vandaag',
|
||||
'liveTv.midnight' => 'Middernacht',
|
||||
@@ -1737,8 +1826,6 @@ extension on TranslationsNl {
|
||||
'liveTv.evening' => 'Avond',
|
||||
'liveTv.lateNight' => 'Late avond',
|
||||
'liveTv.whatsOn' => 'Nu op TV',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.watchChannel' => 'Kanaal bekijken',
|
||||
'downloads.title' => 'Downloads',
|
||||
'downloads.manage' => 'Beheren',
|
||||
@@ -1965,6 +2052,65 @@ extension on TranslationsNl {
|
||||
'externalPlayer.launchFailed' => 'Kan externe speler niet openen',
|
||||
'externalPlayer.appNotInstalled' => ({required Object name}) => '${name} is niet geïnstalleerd',
|
||||
'externalPlayer.playInExternalPlayer' => 'Afspelen in externe speler',
|
||||
'metadataEdit.editMetadata' => 'Bewerken...',
|
||||
'metadataEdit.screenTitle' => 'Metadata bewerken',
|
||||
'metadataEdit.basicInfo' => 'Basisinformatie',
|
||||
'metadataEdit.artwork' => 'Artwork',
|
||||
'metadataEdit.advancedSettings' => 'Geavanceerde instellingen',
|
||||
'metadataEdit.title' => 'Titel',
|
||||
'metadataEdit.sortTitle' => 'Sorteertitel',
|
||||
'metadataEdit.originalTitle' => 'Oorspronkelijke titel',
|
||||
'metadataEdit.releaseDate' => 'Releasedatum',
|
||||
'metadataEdit.contentRating' => 'Leeftijdsclassificatie',
|
||||
'metadataEdit.studio' => 'Studio',
|
||||
'metadataEdit.tagline' => 'Tagline',
|
||||
'metadataEdit.summary' => 'Samenvatting',
|
||||
'metadataEdit.poster' => 'Poster',
|
||||
'metadataEdit.background' => 'Achtergrond',
|
||||
'metadataEdit.selectPoster' => 'Poster selecteren',
|
||||
'metadataEdit.selectBackground' => 'Achtergrond selecteren',
|
||||
'metadataEdit.fromUrl' => 'Vanaf URL',
|
||||
'metadataEdit.uploadFile' => 'Bestand uploaden',
|
||||
'metadataEdit.enterImageUrl' => 'Voer afbeeldings-URL in',
|
||||
'metadataEdit.imageUrl' => 'Afbeeldings-URL',
|
||||
'metadataEdit.metadataUpdated' => 'Metadata bijgewerkt',
|
||||
'metadataEdit.metadataUpdateFailed' => 'Metadata bijwerken mislukt',
|
||||
'metadataEdit.artworkUpdated' => 'Artwork bijgewerkt',
|
||||
'metadataEdit.artworkUpdateFailed' => 'Artwork bijwerken mislukt',
|
||||
'metadataEdit.noArtworkAvailable' => 'Geen artwork beschikbaar',
|
||||
'metadataEdit.notSet' => 'Niet ingesteld',
|
||||
'metadataEdit.libraryDefault' => 'Bibliotheekstandaard',
|
||||
'metadataEdit.accountDefault' => 'Accountstandaard',
|
||||
'metadataEdit.seriesDefault' => 'Seriestandaard',
|
||||
'metadataEdit.episodeSorting' => 'Afleveringen sorteren',
|
||||
'metadataEdit.oldestFirst' => 'Oudste eerst',
|
||||
'metadataEdit.newestFirst' => 'Nieuwste eerst',
|
||||
'metadataEdit.keep' => 'Bewaren',
|
||||
'metadataEdit.allEpisodes' => 'Alle afleveringen',
|
||||
'metadataEdit.latestEpisodes' => ({required Object count}) => '${count} nieuwste afleveringen',
|
||||
'metadataEdit.latestEpisode' => 'Nieuwste aflevering',
|
||||
'metadataEdit.episodesAddedPastDays' => ({required Object count}) => 'Afleveringen toegevoegd in de afgelopen ${count} dagen',
|
||||
'metadataEdit.deleteAfterPlaying' => 'Afleveringen verwijderen na afspelen',
|
||||
'metadataEdit.never' => 'Nooit',
|
||||
'metadataEdit.afterADay' => 'Na een dag',
|
||||
'metadataEdit.afterAWeek' => 'Na een week',
|
||||
'metadataEdit.afterAMonth' => 'Na een maand',
|
||||
'metadataEdit.onNextRefresh' => 'Bij volgende verversing',
|
||||
'metadataEdit.seasons' => 'Seizoenen',
|
||||
'metadataEdit.show' => 'Tonen',
|
||||
'metadataEdit.hide' => 'Verbergen',
|
||||
'metadataEdit.episodeOrdering' => 'Afleveringsvolgorde',
|
||||
'metadataEdit.tmdbAiring' => 'The Movie Database (Uitgezonden)',
|
||||
'metadataEdit.tvdbAiring' => 'TheTVDB (Uitgezonden)',
|
||||
'metadataEdit.tvdbAbsolute' => 'TheTVDB (Absoluut)',
|
||||
'metadataEdit.metadataLanguage' => 'Metadatataal',
|
||||
'metadataEdit.useOriginalTitle' => 'Oorspronkelijke titel gebruiken',
|
||||
'metadataEdit.preferredAudioLanguage' => 'Voorkeurstaal audio',
|
||||
'metadataEdit.preferredSubtitleLanguage' => 'Voorkeurstaal ondertiteling',
|
||||
'metadataEdit.subtitleMode' => 'Automatische ondertitelselectie',
|
||||
'metadataEdit.manuallySelected' => 'Handmatig geselecteerd',
|
||||
'metadataEdit.shownWithForeignAudio' => 'Weergeven bij anderstalig geluid',
|
||||
'metadataEdit.alwaysEnabled' => 'Altijd ingeschakeld',
|
||||
_ => null,
|
||||
};
|
||||
}
|
||||
|
||||
+148
-2
@@ -74,6 +74,7 @@ class TranslationsSv with BaseTranslations<AppLocale, Translations> implements T
|
||||
@override late final _TranslationsCompanionRemoteSv companionRemote = _TranslationsCompanionRemoteSv._(_root);
|
||||
@override late final _TranslationsVideoSettingsSv videoSettings = _TranslationsVideoSettingsSv._(_root);
|
||||
@override late final _TranslationsExternalPlayerSv externalPlayer = _TranslationsExternalPlayerSv._(_root);
|
||||
@override late final _TranslationsMetadataEditSv metadataEdit = _TranslationsMetadataEditSv._(_root);
|
||||
}
|
||||
|
||||
// Path: app
|
||||
@@ -149,6 +150,7 @@ class _TranslationsCommonSv implements TranslationsCommonEn {
|
||||
@override String get exitConfirmMessage => 'Är du säker på att du vill avsluta?';
|
||||
@override String get dontAskAgain => 'Fråga inte igen';
|
||||
@override String get exit => 'Avsluta';
|
||||
@override String get viewAll => 'Visa alla';
|
||||
}
|
||||
|
||||
// Path: screens
|
||||
@@ -243,6 +245,8 @@ class _TranslationsSettingsSv implements TranslationsSettingsEn {
|
||||
@override String get hardwareDecodingDescription => 'Använd hårdvaruacceleration när tillgängligt';
|
||||
@override String get bufferSize => 'Bufferstorlek';
|
||||
@override String bufferSizeMB({required Object size}) => '${size}MB';
|
||||
@override String get bufferSizeAuto => 'Auto (Rekommenderat)';
|
||||
@override String bufferSizeWarning({required Object heap, required Object size}) => 'Din enhet har ${heap}MB minne. En buffert på ${size}MB kan orsaka uppspelningsproblem.';
|
||||
@override String get subtitleStyling => 'Undertext-styling';
|
||||
@override String get subtitleStylingDescription => 'Anpassa undertextutseende';
|
||||
@override String get smallSkipDuration => 'Kort hoppvaraktighet';
|
||||
@@ -400,6 +404,7 @@ class _TranslationsMediaMenuSv implements TranslationsMediaMenuEn {
|
||||
@override String get deleteMultipleWarning => 'Flera objekt kan komma att tas bort.';
|
||||
@override String get mediaDeletedSuccessfully => 'Mediaobjekt borttaget';
|
||||
@override String get mediaFailedToDelete => 'Kunde inte ta bort mediaobjekt';
|
||||
@override String get rate => 'Betygsätt';
|
||||
}
|
||||
|
||||
// Path: accessibility
|
||||
@@ -474,6 +479,9 @@ class _TranslationsVideoControlsSv implements TranslationsVideoControlsEn {
|
||||
@override String get versionsButton => 'Videoversioner';
|
||||
@override String get pipButton => 'Bild-i-bild läge';
|
||||
@override String get aspectRatioButton => 'Bildförhållande';
|
||||
@override String get ambientLighting => 'Ambientbelysning';
|
||||
@override String get ambientLightingOn => 'Aktivera ambientbelysning';
|
||||
@override String get ambientLightingOff => 'Inaktivera ambientbelysning';
|
||||
@override String get fullscreenButton => 'Aktivera helskärm';
|
||||
@override String get exitFullscreenButton => 'Avsluta helskärm';
|
||||
@override String get alwaysOnTopButton => 'Alltid överst';
|
||||
@@ -485,6 +493,8 @@ class _TranslationsVideoControlsSv implements TranslationsVideoControlsEn {
|
||||
@override late final _TranslationsVideoControlsPipErrorsSv pipErrors = _TranslationsVideoControlsPipErrorsSv._(_root);
|
||||
@override String get chapters => 'Kapitel';
|
||||
@override String get noChaptersAvailable => 'Inga kapitel tillgängliga';
|
||||
@override String get queue => 'Queue';
|
||||
@override String get noQueueItems => 'No items in queue';
|
||||
}
|
||||
|
||||
// Path: userStatus
|
||||
@@ -1043,6 +1053,74 @@ class _TranslationsExternalPlayerSv implements TranslationsExternalPlayerEn {
|
||||
@override String get playInExternalPlayer => 'Spela i extern spelare';
|
||||
}
|
||||
|
||||
// Path: metadataEdit
|
||||
class _TranslationsMetadataEditSv implements TranslationsMetadataEditEn {
|
||||
_TranslationsMetadataEditSv._(this._root);
|
||||
|
||||
final TranslationsSv _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get editMetadata => 'Redigera...';
|
||||
@override String get screenTitle => 'Redigera metadata';
|
||||
@override String get basicInfo => 'Grundläggande info';
|
||||
@override String get artwork => 'Artwork';
|
||||
@override String get advancedSettings => 'Avancerade inställningar';
|
||||
@override String get title => 'Titel';
|
||||
@override String get sortTitle => 'Sorteringstitel';
|
||||
@override String get originalTitle => 'Originaltitel';
|
||||
@override String get releaseDate => 'Utgivningsdatum';
|
||||
@override String get contentRating => 'Åldersgräns';
|
||||
@override String get studio => 'Studio';
|
||||
@override String get tagline => 'Tagline';
|
||||
@override String get summary => 'Sammanfattning';
|
||||
@override String get poster => 'Poster';
|
||||
@override String get background => 'Bakgrund';
|
||||
@override String get selectPoster => 'Välj poster';
|
||||
@override String get selectBackground => 'Välj bakgrund';
|
||||
@override String get fromUrl => 'Från URL';
|
||||
@override String get uploadFile => 'Ladda upp fil';
|
||||
@override String get enterImageUrl => 'Ange bild-URL';
|
||||
@override String get imageUrl => 'Bild-URL';
|
||||
@override String get metadataUpdated => 'Metadata uppdaterad';
|
||||
@override String get metadataUpdateFailed => 'Kunde inte uppdatera metadata';
|
||||
@override String get artworkUpdated => 'Artwork uppdaterad';
|
||||
@override String get artworkUpdateFailed => 'Kunde inte uppdatera artwork';
|
||||
@override String get noArtworkAvailable => 'Ingen artwork tillgänglig';
|
||||
@override String get notSet => 'Inte angiven';
|
||||
@override String get libraryDefault => 'Biblioteksstandard';
|
||||
@override String get accountDefault => 'Kontostandard';
|
||||
@override String get seriesDefault => 'Seriestandard';
|
||||
@override String get episodeSorting => 'Avsnittsortering';
|
||||
@override String get oldestFirst => 'Äldst först';
|
||||
@override String get newestFirst => 'Nyast först';
|
||||
@override String get keep => 'Behåll';
|
||||
@override String get allEpisodes => 'Alla avsnitt';
|
||||
@override String latestEpisodes({required Object count}) => '${count} senaste avsnitten';
|
||||
@override String get latestEpisode => 'Senaste avsnittet';
|
||||
@override String episodesAddedPastDays({required Object count}) => 'Avsnitt tillagda de senaste ${count} dagarna';
|
||||
@override String get deleteAfterPlaying => 'Ta bort avsnitt efter uppspelning';
|
||||
@override String get never => 'Aldrig';
|
||||
@override String get afterADay => 'Efter en dag';
|
||||
@override String get afterAWeek => 'Efter en vecka';
|
||||
@override String get afterAMonth => 'Efter en månad';
|
||||
@override String get onNextRefresh => 'Vid nästa uppdatering';
|
||||
@override String get seasons => 'Säsonger';
|
||||
@override String get show => 'Visa';
|
||||
@override String get hide => 'Dölj';
|
||||
@override String get episodeOrdering => 'Avsnittsordning';
|
||||
@override String get tmdbAiring => 'The Movie Database (Sändning)';
|
||||
@override String get tvdbAiring => 'TheTVDB (Sändning)';
|
||||
@override String get tvdbAbsolute => 'TheTVDB (Absolut)';
|
||||
@override String get metadataLanguage => 'Metadataspråk';
|
||||
@override String get useOriginalTitle => 'Använd originaltitel';
|
||||
@override String get preferredAudioLanguage => 'Föredraget ljudspråk';
|
||||
@override String get preferredSubtitleLanguage => 'Föredraget undertextspråk';
|
||||
@override String get subtitleMode => 'Automatiskt val av undertexter';
|
||||
@override String get manuallySelected => 'Manuellt vald';
|
||||
@override String get shownWithForeignAudio => 'Visas vid främmande ljud';
|
||||
@override String get alwaysEnabled => 'Alltid aktiverad';
|
||||
}
|
||||
|
||||
// Path: hotkeys.actions
|
||||
class _TranslationsHotkeysActionsSv implements TranslationsHotkeysActionsEn {
|
||||
_TranslationsHotkeysActionsSv._(this._root);
|
||||
@@ -1273,6 +1351,7 @@ extension on TranslationsSv {
|
||||
'common.exitConfirmMessage' => 'Är du säker på att du vill avsluta?',
|
||||
'common.dontAskAgain' => 'Fråga inte igen',
|
||||
'common.exit' => 'Avsluta',
|
||||
'common.viewAll' => 'Visa alla',
|
||||
'screens.licenses' => 'Licenser',
|
||||
'screens.switchProfile' => 'Byt profil',
|
||||
'screens.subtitleStyling' => 'Undertext-styling',
|
||||
@@ -1340,6 +1419,8 @@ extension on TranslationsSv {
|
||||
'settings.hardwareDecodingDescription' => 'Använd hårdvaruacceleration när tillgängligt',
|
||||
'settings.bufferSize' => 'Bufferstorlek',
|
||||
'settings.bufferSizeMB' => ({required Object size}) => '${size}MB',
|
||||
'settings.bufferSizeAuto' => 'Auto (Rekommenderat)',
|
||||
'settings.bufferSizeWarning' => ({required Object heap, required Object size}) => 'Din enhet har ${heap}MB minne. En buffert på ${size}MB kan orsaka uppspelningsproblem.',
|
||||
'settings.subtitleStyling' => 'Undertext-styling',
|
||||
'settings.subtitleStylingDescription' => 'Anpassa undertextutseende',
|
||||
'settings.smallSkipDuration' => 'Kort hoppvaraktighet',
|
||||
@@ -1470,6 +1551,7 @@ extension on TranslationsSv {
|
||||
'mediaMenu.deleteMultipleWarning' => 'Flera objekt kan komma att tas bort.',
|
||||
'mediaMenu.mediaDeletedSuccessfully' => 'Mediaobjekt borttaget',
|
||||
'mediaMenu.mediaFailedToDelete' => 'Kunde inte ta bort mediaobjekt',
|
||||
'mediaMenu.rate' => 'Betygsätt',
|
||||
'accessibility.mediaCardMovie' => ({required Object title}) => '${title}, film',
|
||||
'accessibility.mediaCardShow' => ({required Object title}) => '${title}, TV-serie',
|
||||
'accessibility.mediaCardEpisode' => ({required Object title, required Object episodeInfo}) => '${title}, ${episodeInfo}',
|
||||
@@ -1517,6 +1599,9 @@ extension on TranslationsSv {
|
||||
'videoControls.versionsButton' => 'Videoversioner',
|
||||
'videoControls.pipButton' => 'Bild-i-bild läge',
|
||||
'videoControls.aspectRatioButton' => 'Bildförhållande',
|
||||
'videoControls.ambientLighting' => 'Ambientbelysning',
|
||||
'videoControls.ambientLightingOn' => 'Aktivera ambientbelysning',
|
||||
'videoControls.ambientLightingOff' => 'Inaktivera ambientbelysning',
|
||||
'videoControls.fullscreenButton' => 'Aktivera helskärm',
|
||||
'videoControls.exitFullscreenButton' => 'Avsluta helskärm',
|
||||
'videoControls.alwaysOnTopButton' => 'Alltid överst',
|
||||
@@ -1532,6 +1617,8 @@ extension on TranslationsSv {
|
||||
'videoControls.pipErrors.unknown' => ({required Object error}) => 'Ett fel uppstod: ${error}',
|
||||
'videoControls.chapters' => 'Kapitel',
|
||||
'videoControls.noChaptersAvailable' => 'Inga kapitel tillgängliga',
|
||||
'videoControls.queue' => 'Queue',
|
||||
'videoControls.noQueueItems' => 'No items in queue',
|
||||
'userStatus.admin' => 'Admin',
|
||||
'userStatus.restricted' => 'Begränsad',
|
||||
'userStatus.protected' => 'Skyddad',
|
||||
@@ -1728,6 +1815,8 @@ extension on TranslationsSv {
|
||||
'liveTv.reloadGuide' => 'Ladda om programguide',
|
||||
'liveTv.guideReloaded' => 'Programdata omladdad',
|
||||
'liveTv.allChannels' => 'Alla kanaler',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.now' => 'Nu',
|
||||
'liveTv.today' => 'Idag',
|
||||
'liveTv.midnight' => 'Midnatt',
|
||||
@@ -1737,8 +1826,6 @@ extension on TranslationsSv {
|
||||
'liveTv.evening' => 'Kväll',
|
||||
'liveTv.lateNight' => 'Sen kväll',
|
||||
'liveTv.whatsOn' => 'På TV nu',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.watchChannel' => 'Titta på kanal',
|
||||
'downloads.title' => 'Nedladdningar',
|
||||
'downloads.manage' => 'Hantera',
|
||||
@@ -1965,6 +2052,65 @@ extension on TranslationsSv {
|
||||
'externalPlayer.launchFailed' => 'Kunde inte öppna extern spelare',
|
||||
'externalPlayer.appNotInstalled' => ({required Object name}) => '${name} är inte installerad',
|
||||
'externalPlayer.playInExternalPlayer' => 'Spela i extern spelare',
|
||||
'metadataEdit.editMetadata' => 'Redigera...',
|
||||
'metadataEdit.screenTitle' => 'Redigera metadata',
|
||||
'metadataEdit.basicInfo' => 'Grundläggande info',
|
||||
'metadataEdit.artwork' => 'Artwork',
|
||||
'metadataEdit.advancedSettings' => 'Avancerade inställningar',
|
||||
'metadataEdit.title' => 'Titel',
|
||||
'metadataEdit.sortTitle' => 'Sorteringstitel',
|
||||
'metadataEdit.originalTitle' => 'Originaltitel',
|
||||
'metadataEdit.releaseDate' => 'Utgivningsdatum',
|
||||
'metadataEdit.contentRating' => 'Åldersgräns',
|
||||
'metadataEdit.studio' => 'Studio',
|
||||
'metadataEdit.tagline' => 'Tagline',
|
||||
'metadataEdit.summary' => 'Sammanfattning',
|
||||
'metadataEdit.poster' => 'Poster',
|
||||
'metadataEdit.background' => 'Bakgrund',
|
||||
'metadataEdit.selectPoster' => 'Välj poster',
|
||||
'metadataEdit.selectBackground' => 'Välj bakgrund',
|
||||
'metadataEdit.fromUrl' => 'Från URL',
|
||||
'metadataEdit.uploadFile' => 'Ladda upp fil',
|
||||
'metadataEdit.enterImageUrl' => 'Ange bild-URL',
|
||||
'metadataEdit.imageUrl' => 'Bild-URL',
|
||||
'metadataEdit.metadataUpdated' => 'Metadata uppdaterad',
|
||||
'metadataEdit.metadataUpdateFailed' => 'Kunde inte uppdatera metadata',
|
||||
'metadataEdit.artworkUpdated' => 'Artwork uppdaterad',
|
||||
'metadataEdit.artworkUpdateFailed' => 'Kunde inte uppdatera artwork',
|
||||
'metadataEdit.noArtworkAvailable' => 'Ingen artwork tillgänglig',
|
||||
'metadataEdit.notSet' => 'Inte angiven',
|
||||
'metadataEdit.libraryDefault' => 'Biblioteksstandard',
|
||||
'metadataEdit.accountDefault' => 'Kontostandard',
|
||||
'metadataEdit.seriesDefault' => 'Seriestandard',
|
||||
'metadataEdit.episodeSorting' => 'Avsnittsortering',
|
||||
'metadataEdit.oldestFirst' => 'Äldst först',
|
||||
'metadataEdit.newestFirst' => 'Nyast först',
|
||||
'metadataEdit.keep' => 'Behåll',
|
||||
'metadataEdit.allEpisodes' => 'Alla avsnitt',
|
||||
'metadataEdit.latestEpisodes' => ({required Object count}) => '${count} senaste avsnitten',
|
||||
'metadataEdit.latestEpisode' => 'Senaste avsnittet',
|
||||
'metadataEdit.episodesAddedPastDays' => ({required Object count}) => 'Avsnitt tillagda de senaste ${count} dagarna',
|
||||
'metadataEdit.deleteAfterPlaying' => 'Ta bort avsnitt efter uppspelning',
|
||||
'metadataEdit.never' => 'Aldrig',
|
||||
'metadataEdit.afterADay' => 'Efter en dag',
|
||||
'metadataEdit.afterAWeek' => 'Efter en vecka',
|
||||
'metadataEdit.afterAMonth' => 'Efter en månad',
|
||||
'metadataEdit.onNextRefresh' => 'Vid nästa uppdatering',
|
||||
'metadataEdit.seasons' => 'Säsonger',
|
||||
'metadataEdit.show' => 'Visa',
|
||||
'metadataEdit.hide' => 'Dölj',
|
||||
'metadataEdit.episodeOrdering' => 'Avsnittsordning',
|
||||
'metadataEdit.tmdbAiring' => 'The Movie Database (Sändning)',
|
||||
'metadataEdit.tvdbAiring' => 'TheTVDB (Sändning)',
|
||||
'metadataEdit.tvdbAbsolute' => 'TheTVDB (Absolut)',
|
||||
'metadataEdit.metadataLanguage' => 'Metadataspråk',
|
||||
'metadataEdit.useOriginalTitle' => 'Använd originaltitel',
|
||||
'metadataEdit.preferredAudioLanguage' => 'Föredraget ljudspråk',
|
||||
'metadataEdit.preferredSubtitleLanguage' => 'Föredraget undertextspråk',
|
||||
'metadataEdit.subtitleMode' => 'Automatiskt val av undertexter',
|
||||
'metadataEdit.manuallySelected' => 'Manuellt vald',
|
||||
'metadataEdit.shownWithForeignAudio' => 'Visas vid främmande ljud',
|
||||
'metadataEdit.alwaysEnabled' => 'Alltid aktiverad',
|
||||
_ => null,
|
||||
};
|
||||
}
|
||||
|
||||
+148
-2
@@ -74,6 +74,7 @@ class TranslationsZh with BaseTranslations<AppLocale, Translations> implements T
|
||||
@override late final _TranslationsCompanionRemoteZh companionRemote = _TranslationsCompanionRemoteZh._(_root);
|
||||
@override late final _TranslationsVideoSettingsZh videoSettings = _TranslationsVideoSettingsZh._(_root);
|
||||
@override late final _TranslationsExternalPlayerZh externalPlayer = _TranslationsExternalPlayerZh._(_root);
|
||||
@override late final _TranslationsMetadataEditZh metadataEdit = _TranslationsMetadataEditZh._(_root);
|
||||
}
|
||||
|
||||
// Path: app
|
||||
@@ -149,6 +150,7 @@ class _TranslationsCommonZh implements TranslationsCommonEn {
|
||||
@override String get exitConfirmMessage => '确定要退出吗?';
|
||||
@override String get dontAskAgain => '不再询问';
|
||||
@override String get exit => '退出';
|
||||
@override String get viewAll => '查看全部';
|
||||
}
|
||||
|
||||
// Path: screens
|
||||
@@ -243,6 +245,8 @@ class _TranslationsSettingsZh implements TranslationsSettingsEn {
|
||||
@override String get hardwareDecodingDescription => '如果可用,使用硬件加速';
|
||||
@override String get bufferSize => '缓冲区大小';
|
||||
@override String bufferSizeMB({required Object size}) => '${size}MB';
|
||||
@override String get bufferSizeAuto => '自动(推荐)';
|
||||
@override String bufferSizeWarning({required Object heap, required Object size}) => '您的设备有 ${heap}MB 内存。${size}MB 的缓冲区可能导致播放问题。';
|
||||
@override String get subtitleStyling => '字幕样式';
|
||||
@override String get subtitleStylingDescription => '调整字幕外观';
|
||||
@override String get smallSkipDuration => '短跳过时长';
|
||||
@@ -400,6 +404,7 @@ class _TranslationsMediaMenuZh implements TranslationsMediaMenuEn {
|
||||
@override String get deleteMultipleWarning => '可能会删除多个项目。';
|
||||
@override String get mediaDeletedSuccessfully => '媒体项已成功删除';
|
||||
@override String get mediaFailedToDelete => '删除媒体项失败';
|
||||
@override String get rate => '评分';
|
||||
}
|
||||
|
||||
// Path: accessibility
|
||||
@@ -474,6 +479,9 @@ class _TranslationsVideoControlsZh implements TranslationsVideoControlsEn {
|
||||
@override String get versionsButton => '视频版本';
|
||||
@override String get pipButton => '画中画模式';
|
||||
@override String get aspectRatioButton => '宽高比';
|
||||
@override String get ambientLighting => '氛围灯光';
|
||||
@override String get ambientLightingOn => '开启氛围灯光';
|
||||
@override String get ambientLightingOff => '关闭氛围灯光';
|
||||
@override String get fullscreenButton => '进入全屏';
|
||||
@override String get exitFullscreenButton => '退出全屏';
|
||||
@override String get alwaysOnTopButton => '置顶窗口';
|
||||
@@ -485,6 +493,8 @@ class _TranslationsVideoControlsZh implements TranslationsVideoControlsEn {
|
||||
@override late final _TranslationsVideoControlsPipErrorsZh pipErrors = _TranslationsVideoControlsPipErrorsZh._(_root);
|
||||
@override String get chapters => '章节';
|
||||
@override String get noChaptersAvailable => '没有可用的章节';
|
||||
@override String get queue => 'Queue';
|
||||
@override String get noQueueItems => 'No items in queue';
|
||||
}
|
||||
|
||||
// Path: userStatus
|
||||
@@ -1043,6 +1053,74 @@ class _TranslationsExternalPlayerZh implements TranslationsExternalPlayerEn {
|
||||
@override String get playInExternalPlayer => '在外部播放器中播放';
|
||||
}
|
||||
|
||||
// Path: metadataEdit
|
||||
class _TranslationsMetadataEditZh implements TranslationsMetadataEditEn {
|
||||
_TranslationsMetadataEditZh._(this._root);
|
||||
|
||||
final TranslationsZh _root; // ignore: unused_field
|
||||
|
||||
// Translations
|
||||
@override String get editMetadata => '编辑...';
|
||||
@override String get screenTitle => '编辑元数据';
|
||||
@override String get basicInfo => '基本信息';
|
||||
@override String get artwork => '封面图片';
|
||||
@override String get advancedSettings => '高级设置';
|
||||
@override String get title => '标题';
|
||||
@override String get sortTitle => '排序标题';
|
||||
@override String get originalTitle => '原始标题';
|
||||
@override String get releaseDate => '上映日期';
|
||||
@override String get contentRating => '内容分级';
|
||||
@override String get studio => '制片厂';
|
||||
@override String get tagline => '标语';
|
||||
@override String get summary => '简介';
|
||||
@override String get poster => '海报';
|
||||
@override String get background => '背景';
|
||||
@override String get selectPoster => '选择海报';
|
||||
@override String get selectBackground => '选择背景';
|
||||
@override String get fromUrl => '从 URL';
|
||||
@override String get uploadFile => '上传文件';
|
||||
@override String get enterImageUrl => '输入图片 URL';
|
||||
@override String get imageUrl => '图片 URL';
|
||||
@override String get metadataUpdated => '元数据已更新';
|
||||
@override String get metadataUpdateFailed => '元数据更新失败';
|
||||
@override String get artworkUpdated => '封面图片已更新';
|
||||
@override String get artworkUpdateFailed => '封面图片更新失败';
|
||||
@override String get noArtworkAvailable => '没有可用的封面图片';
|
||||
@override String get notSet => '未设置';
|
||||
@override String get libraryDefault => '媒体库默认';
|
||||
@override String get accountDefault => '账户默认';
|
||||
@override String get seriesDefault => '剧集默认';
|
||||
@override String get episodeSorting => '剧集排序';
|
||||
@override String get oldestFirst => '最旧优先';
|
||||
@override String get newestFirst => '最新优先';
|
||||
@override String get keep => '保留';
|
||||
@override String get allEpisodes => '所有剧集';
|
||||
@override String latestEpisodes({required Object count}) => '最新 ${count} 集';
|
||||
@override String get latestEpisode => '最新一集';
|
||||
@override String episodesAddedPastDays({required Object count}) => '过去 ${count} 天内添加的剧集';
|
||||
@override String get deleteAfterPlaying => '播放后删除剧集';
|
||||
@override String get never => '从不';
|
||||
@override String get afterADay => '一天后';
|
||||
@override String get afterAWeek => '一周后';
|
||||
@override String get afterAMonth => '一个月后';
|
||||
@override String get onNextRefresh => '下次刷新时';
|
||||
@override String get seasons => '季';
|
||||
@override String get show => '显示';
|
||||
@override String get hide => '隐藏';
|
||||
@override String get episodeOrdering => '剧集排列顺序';
|
||||
@override String get tmdbAiring => 'The Movie Database(播出顺序)';
|
||||
@override String get tvdbAiring => 'TheTVDB(播出顺序)';
|
||||
@override String get tvdbAbsolute => 'TheTVDB(绝对顺序)';
|
||||
@override String get metadataLanguage => '元数据语言';
|
||||
@override String get useOriginalTitle => '使用原始标题';
|
||||
@override String get preferredAudioLanguage => '首选音频语言';
|
||||
@override String get preferredSubtitleLanguage => '首选字幕语言';
|
||||
@override String get subtitleMode => '自动选择字幕模式';
|
||||
@override String get manuallySelected => '手动选择';
|
||||
@override String get shownWithForeignAudio => '外语音频时显示';
|
||||
@override String get alwaysEnabled => '始终启用';
|
||||
}
|
||||
|
||||
// Path: hotkeys.actions
|
||||
class _TranslationsHotkeysActionsZh implements TranslationsHotkeysActionsEn {
|
||||
_TranslationsHotkeysActionsZh._(this._root);
|
||||
@@ -1273,6 +1351,7 @@ extension on TranslationsZh {
|
||||
'common.exitConfirmMessage' => '确定要退出吗?',
|
||||
'common.dontAskAgain' => '不再询问',
|
||||
'common.exit' => '退出',
|
||||
'common.viewAll' => '查看全部',
|
||||
'screens.licenses' => '许可证',
|
||||
'screens.switchProfile' => '切换用户',
|
||||
'screens.subtitleStyling' => '字幕样式',
|
||||
@@ -1340,6 +1419,8 @@ extension on TranslationsZh {
|
||||
'settings.hardwareDecodingDescription' => '如果可用,使用硬件加速',
|
||||
'settings.bufferSize' => '缓冲区大小',
|
||||
'settings.bufferSizeMB' => ({required Object size}) => '${size}MB',
|
||||
'settings.bufferSizeAuto' => '自动(推荐)',
|
||||
'settings.bufferSizeWarning' => ({required Object heap, required Object size}) => '您的设备有 ${heap}MB 内存。${size}MB 的缓冲区可能导致播放问题。',
|
||||
'settings.subtitleStyling' => '字幕样式',
|
||||
'settings.subtitleStylingDescription' => '调整字幕外观',
|
||||
'settings.smallSkipDuration' => '短跳过时长',
|
||||
@@ -1470,6 +1551,7 @@ extension on TranslationsZh {
|
||||
'mediaMenu.deleteMultipleWarning' => '可能会删除多个项目。',
|
||||
'mediaMenu.mediaDeletedSuccessfully' => '媒体项已成功删除',
|
||||
'mediaMenu.mediaFailedToDelete' => '删除媒体项失败',
|
||||
'mediaMenu.rate' => '评分',
|
||||
'accessibility.mediaCardMovie' => ({required Object title}) => '${title}, 电影',
|
||||
'accessibility.mediaCardShow' => ({required Object title}) => '${title}, 电视剧',
|
||||
'accessibility.mediaCardEpisode' => ({required Object title, required Object episodeInfo}) => '${title}, ${episodeInfo}',
|
||||
@@ -1517,6 +1599,9 @@ extension on TranslationsZh {
|
||||
'videoControls.versionsButton' => '视频版本',
|
||||
'videoControls.pipButton' => '画中画模式',
|
||||
'videoControls.aspectRatioButton' => '宽高比',
|
||||
'videoControls.ambientLighting' => '氛围灯光',
|
||||
'videoControls.ambientLightingOn' => '开启氛围灯光',
|
||||
'videoControls.ambientLightingOff' => '关闭氛围灯光',
|
||||
'videoControls.fullscreenButton' => '进入全屏',
|
||||
'videoControls.exitFullscreenButton' => '退出全屏',
|
||||
'videoControls.alwaysOnTopButton' => '置顶窗口',
|
||||
@@ -1532,6 +1617,8 @@ extension on TranslationsZh {
|
||||
'videoControls.pipErrors.unknown' => ({required Object error}) => '发生错误:${error}',
|
||||
'videoControls.chapters' => '章节',
|
||||
'videoControls.noChaptersAvailable' => '没有可用的章节',
|
||||
'videoControls.queue' => 'Queue',
|
||||
'videoControls.noQueueItems' => 'No items in queue',
|
||||
'userStatus.admin' => '管理员',
|
||||
'userStatus.restricted' => '受限',
|
||||
'userStatus.protected' => '受保护',
|
||||
@@ -1728,6 +1815,8 @@ extension on TranslationsZh {
|
||||
'liveTv.reloadGuide' => '重新加载节目指南',
|
||||
'liveTv.guideReloaded' => '节目指南已重新加载',
|
||||
'liveTv.allChannels' => '所有频道',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.now' => '现在',
|
||||
'liveTv.today' => '今天',
|
||||
'liveTv.midnight' => '午夜',
|
||||
@@ -1737,8 +1826,6 @@ extension on TranslationsZh {
|
||||
'liveTv.evening' => '晚上',
|
||||
'liveTv.lateNight' => '深夜',
|
||||
'liveTv.whatsOn' => '正在播出',
|
||||
_ => null,
|
||||
} ?? switch (path) {
|
||||
'liveTv.watchChannel' => '观看频道',
|
||||
'downloads.title' => '下载',
|
||||
'downloads.manage' => '管理',
|
||||
@@ -1965,6 +2052,65 @@ extension on TranslationsZh {
|
||||
'externalPlayer.launchFailed' => '无法打开外部播放器',
|
||||
'externalPlayer.appNotInstalled' => ({required Object name}) => '${name} 未安装',
|
||||
'externalPlayer.playInExternalPlayer' => '在外部播放器中播放',
|
||||
'metadataEdit.editMetadata' => '编辑...',
|
||||
'metadataEdit.screenTitle' => '编辑元数据',
|
||||
'metadataEdit.basicInfo' => '基本信息',
|
||||
'metadataEdit.artwork' => '封面图片',
|
||||
'metadataEdit.advancedSettings' => '高级设置',
|
||||
'metadataEdit.title' => '标题',
|
||||
'metadataEdit.sortTitle' => '排序标题',
|
||||
'metadataEdit.originalTitle' => '原始标题',
|
||||
'metadataEdit.releaseDate' => '上映日期',
|
||||
'metadataEdit.contentRating' => '内容分级',
|
||||
'metadataEdit.studio' => '制片厂',
|
||||
'metadataEdit.tagline' => '标语',
|
||||
'metadataEdit.summary' => '简介',
|
||||
'metadataEdit.poster' => '海报',
|
||||
'metadataEdit.background' => '背景',
|
||||
'metadataEdit.selectPoster' => '选择海报',
|
||||
'metadataEdit.selectBackground' => '选择背景',
|
||||
'metadataEdit.fromUrl' => '从 URL',
|
||||
'metadataEdit.uploadFile' => '上传文件',
|
||||
'metadataEdit.enterImageUrl' => '输入图片 URL',
|
||||
'metadataEdit.imageUrl' => '图片 URL',
|
||||
'metadataEdit.metadataUpdated' => '元数据已更新',
|
||||
'metadataEdit.metadataUpdateFailed' => '元数据更新失败',
|
||||
'metadataEdit.artworkUpdated' => '封面图片已更新',
|
||||
'metadataEdit.artworkUpdateFailed' => '封面图片更新失败',
|
||||
'metadataEdit.noArtworkAvailable' => '没有可用的封面图片',
|
||||
'metadataEdit.notSet' => '未设置',
|
||||
'metadataEdit.libraryDefault' => '媒体库默认',
|
||||
'metadataEdit.accountDefault' => '账户默认',
|
||||
'metadataEdit.seriesDefault' => '剧集默认',
|
||||
'metadataEdit.episodeSorting' => '剧集排序',
|
||||
'metadataEdit.oldestFirst' => '最旧优先',
|
||||
'metadataEdit.newestFirst' => '最新优先',
|
||||
'metadataEdit.keep' => '保留',
|
||||
'metadataEdit.allEpisodes' => '所有剧集',
|
||||
'metadataEdit.latestEpisodes' => ({required Object count}) => '最新 ${count} 集',
|
||||
'metadataEdit.latestEpisode' => '最新一集',
|
||||
'metadataEdit.episodesAddedPastDays' => ({required Object count}) => '过去 ${count} 天内添加的剧集',
|
||||
'metadataEdit.deleteAfterPlaying' => '播放后删除剧集',
|
||||
'metadataEdit.never' => '从不',
|
||||
'metadataEdit.afterADay' => '一天后',
|
||||
'metadataEdit.afterAWeek' => '一周后',
|
||||
'metadataEdit.afterAMonth' => '一个月后',
|
||||
'metadataEdit.onNextRefresh' => '下次刷新时',
|
||||
'metadataEdit.seasons' => '季',
|
||||
'metadataEdit.show' => '显示',
|
||||
'metadataEdit.hide' => '隐藏',
|
||||
'metadataEdit.episodeOrdering' => '剧集排列顺序',
|
||||
'metadataEdit.tmdbAiring' => 'The Movie Database(播出顺序)',
|
||||
'metadataEdit.tvdbAiring' => 'TheTVDB(播出顺序)',
|
||||
'metadataEdit.tvdbAbsolute' => 'TheTVDB(绝对顺序)',
|
||||
'metadataEdit.metadataLanguage' => '元数据语言',
|
||||
'metadataEdit.useOriginalTitle' => '使用原始标题',
|
||||
'metadataEdit.preferredAudioLanguage' => '首选音频语言',
|
||||
'metadataEdit.preferredSubtitleLanguage' => '首选字幕语言',
|
||||
'metadataEdit.subtitleMode' => '自动选择字幕模式',
|
||||
'metadataEdit.manuallySelected' => '手动选择',
|
||||
'metadataEdit.shownWithForeignAudio' => '外语音频时显示',
|
||||
'metadataEdit.alwaysEnabled' => '始终启用',
|
||||
_ => null,
|
||||
};
|
||||
}
|
||||
|
||||
+74
-4
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"app": {
|
||||
"title": "Plezy"
|
||||
},
|
||||
},
|
||||
"auth": {
|
||||
"signInWithPlex": "Logga in med Plex",
|
||||
"showQRCode": "Visa QR-kod",
|
||||
@@ -51,7 +51,8 @@
|
||||
"exitConfirmTitle": "Avsluta appen?",
|
||||
"exitConfirmMessage": "Är du säker på att du vill avsluta?",
|
||||
"dontAskAgain": "Fråga inte igen",
|
||||
"exit": "Avsluta"
|
||||
"exit": "Avsluta",
|
||||
"viewAll": "Visa alla"
|
||||
},
|
||||
"screens": {
|
||||
"licenses": "Licenser",
|
||||
@@ -125,6 +126,8 @@
|
||||
"hardwareDecodingDescription": "Använd hårdvaruacceleration när tillgängligt",
|
||||
"bufferSize": "Bufferstorlek",
|
||||
"bufferSizeMB": "${size}MB",
|
||||
"bufferSizeAuto": "Auto (Rekommenderat)",
|
||||
"bufferSizeWarning": "Din enhet har ${heap}MB minne. En buffert på ${size}MB kan orsaka uppspelningsproblem.",
|
||||
"subtitleStyling": "Undertext-styling",
|
||||
"subtitleStylingDescription": "Anpassa undertextutseende",
|
||||
"smallSkipDuration": "Kort hoppvaraktighet",
|
||||
@@ -266,7 +269,8 @@
|
||||
"confirmDelete": "Är du säker på att du vill ta bort detta objekt från ditt filsystem?",
|
||||
"deleteMultipleWarning": "Flera objekt kan komma att tas bort.",
|
||||
"mediaDeletedSuccessfully": "Mediaobjekt borttaget",
|
||||
"mediaFailedToDelete": "Kunde inte ta bort mediaobjekt"
|
||||
"mediaFailedToDelete": "Kunde inte ta bort mediaobjekt",
|
||||
"rate": "Betygsätt"
|
||||
},
|
||||
"accessibility": {
|
||||
"mediaCardMovie": "${title}, film",
|
||||
@@ -320,6 +324,9 @@
|
||||
"versionsButton": "Videoversioner",
|
||||
"pipButton": "Bild-i-bild läge",
|
||||
"aspectRatioButton": "Bildförhållande",
|
||||
"ambientLighting": "Ambientbelysning",
|
||||
"ambientLightingOn": "Aktivera ambientbelysning",
|
||||
"ambientLightingOff": "Inaktivera ambientbelysning",
|
||||
"fullscreenButton": "Aktivera helskärm",
|
||||
"exitFullscreenButton": "Avsluta helskärm",
|
||||
"alwaysOnTopButton": "Alltid överst",
|
||||
@@ -336,7 +343,9 @@
|
||||
"unknown": "Ett fel uppstod: ${error}"
|
||||
},
|
||||
"chapters": "Kapitel",
|
||||
"noChaptersAvailable": "Inga kapitel tillgängliga"
|
||||
"noChaptersAvailable": "Inga kapitel tillgängliga",
|
||||
"queue": "Queue",
|
||||
"noQueueItems": "No items in queue"
|
||||
},
|
||||
"userStatus": {
|
||||
"admin": "Admin",
|
||||
@@ -824,5 +833,66 @@
|
||||
"launchFailed": "Kunde inte öppna extern spelare",
|
||||
"appNotInstalled": "${name} är inte installerad",
|
||||
"playInExternalPlayer": "Spela i extern spelare"
|
||||
},
|
||||
"metadataEdit": {
|
||||
"editMetadata": "Redigera...",
|
||||
"screenTitle": "Redigera metadata",
|
||||
"basicInfo": "Grundläggande info",
|
||||
"artwork": "Artwork",
|
||||
"advancedSettings": "Avancerade inställningar",
|
||||
"title": "Titel",
|
||||
"sortTitle": "Sorteringstitel",
|
||||
"originalTitle": "Originaltitel",
|
||||
"releaseDate": "Utgivningsdatum",
|
||||
"contentRating": "Åldersgräns",
|
||||
"studio": "Studio",
|
||||
"tagline": "Tagline",
|
||||
"summary": "Sammanfattning",
|
||||
"poster": "Poster",
|
||||
"background": "Bakgrund",
|
||||
"selectPoster": "Välj poster",
|
||||
"selectBackground": "Välj bakgrund",
|
||||
"fromUrl": "Från URL",
|
||||
"uploadFile": "Ladda upp fil",
|
||||
"enterImageUrl": "Ange bild-URL",
|
||||
"imageUrl": "Bild-URL",
|
||||
"metadataUpdated": "Metadata uppdaterad",
|
||||
"metadataUpdateFailed": "Kunde inte uppdatera metadata",
|
||||
"artworkUpdated": "Artwork uppdaterad",
|
||||
"artworkUpdateFailed": "Kunde inte uppdatera artwork",
|
||||
"noArtworkAvailable": "Ingen artwork tillgänglig",
|
||||
"notSet": "Inte angiven",
|
||||
"libraryDefault": "Biblioteksstandard",
|
||||
"accountDefault": "Kontostandard",
|
||||
"seriesDefault": "Seriestandard",
|
||||
"episodeSorting": "Avsnittsortering",
|
||||
"oldestFirst": "Äldst först",
|
||||
"newestFirst": "Nyast först",
|
||||
"keep": "Behåll",
|
||||
"allEpisodes": "Alla avsnitt",
|
||||
"latestEpisodes": "${count} senaste avsnitten",
|
||||
"latestEpisode": "Senaste avsnittet",
|
||||
"episodesAddedPastDays": "Avsnitt tillagda de senaste ${count} dagarna",
|
||||
"deleteAfterPlaying": "Ta bort avsnitt efter uppspelning",
|
||||
"never": "Aldrig",
|
||||
"afterADay": "Efter en dag",
|
||||
"afterAWeek": "Efter en vecka",
|
||||
"afterAMonth": "Efter en månad",
|
||||
"onNextRefresh": "Vid nästa uppdatering",
|
||||
"seasons": "Säsonger",
|
||||
"show": "Visa",
|
||||
"hide": "Dölj",
|
||||
"episodeOrdering": "Avsnittsordning",
|
||||
"tmdbAiring": "The Movie Database (Sändning)",
|
||||
"tvdbAiring": "TheTVDB (Sändning)",
|
||||
"tvdbAbsolute": "TheTVDB (Absolut)",
|
||||
"metadataLanguage": "Metadataspråk",
|
||||
"useOriginalTitle": "Använd originaltitel",
|
||||
"preferredAudioLanguage": "Föredraget ljudspråk",
|
||||
"preferredSubtitleLanguage": "Föredraget undertextspråk",
|
||||
"subtitleMode": "Automatiskt val av undertexter",
|
||||
"manuallySelected": "Manuellt vald",
|
||||
"shownWithForeignAudio": "Visas vid främmande ljud",
|
||||
"alwaysEnabled": "Alltid aktiverad"
|
||||
}
|
||||
}
|
||||
|
||||
+74
-4
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"app": {
|
||||
"title": "Plezy"
|
||||
},
|
||||
},
|
||||
"auth": {
|
||||
"signInWithPlex": "使用 Plex 登录",
|
||||
"showQRCode": "显示二维码",
|
||||
@@ -51,7 +51,8 @@
|
||||
"exitConfirmTitle": "退出应用?",
|
||||
"exitConfirmMessage": "确定要退出吗?",
|
||||
"dontAskAgain": "不再询问",
|
||||
"exit": "退出"
|
||||
"exit": "退出",
|
||||
"viewAll": "查看全部"
|
||||
},
|
||||
"screens": {
|
||||
"licenses": "许可证",
|
||||
@@ -125,6 +126,8 @@
|
||||
"hardwareDecodingDescription": "如果可用,使用硬件加速",
|
||||
"bufferSize": "缓冲区大小",
|
||||
"bufferSizeMB": "${size}MB",
|
||||
"bufferSizeAuto": "自动(推荐)",
|
||||
"bufferSizeWarning": "您的设备有 ${heap}MB 内存。${size}MB 的缓冲区可能导致播放问题。",
|
||||
"subtitleStyling": "字幕样式",
|
||||
"subtitleStylingDescription": "调整字幕外观",
|
||||
"smallSkipDuration": "短跳过时长",
|
||||
@@ -266,7 +269,8 @@
|
||||
"confirmDelete": "确定要从文件系统中删除此项吗?",
|
||||
"deleteMultipleWarning": "可能会删除多个项目。",
|
||||
"mediaDeletedSuccessfully": "媒体项已成功删除",
|
||||
"mediaFailedToDelete": "删除媒体项失败"
|
||||
"mediaFailedToDelete": "删除媒体项失败",
|
||||
"rate": "评分"
|
||||
},
|
||||
"accessibility": {
|
||||
"mediaCardMovie": "${title}, 电影",
|
||||
@@ -320,6 +324,9 @@
|
||||
"versionsButton": "视频版本",
|
||||
"pipButton": "画中画模式",
|
||||
"aspectRatioButton": "宽高比",
|
||||
"ambientLighting": "氛围灯光",
|
||||
"ambientLightingOn": "开启氛围灯光",
|
||||
"ambientLightingOff": "关闭氛围灯光",
|
||||
"fullscreenButton": "进入全屏",
|
||||
"exitFullscreenButton": "退出全屏",
|
||||
"alwaysOnTopButton": "置顶窗口",
|
||||
@@ -336,7 +343,9 @@
|
||||
"unknown": "发生错误:${error}"
|
||||
},
|
||||
"chapters": "章节",
|
||||
"noChaptersAvailable": "没有可用的章节"
|
||||
"noChaptersAvailable": "没有可用的章节",
|
||||
"queue": "Queue",
|
||||
"noQueueItems": "No items in queue"
|
||||
},
|
||||
"userStatus": {
|
||||
"admin": "管理员",
|
||||
@@ -824,5 +833,66 @@
|
||||
"launchFailed": "无法打开外部播放器",
|
||||
"appNotInstalled": "${name} 未安装",
|
||||
"playInExternalPlayer": "在外部播放器中播放"
|
||||
},
|
||||
"metadataEdit": {
|
||||
"editMetadata": "编辑...",
|
||||
"screenTitle": "编辑元数据",
|
||||
"basicInfo": "基本信息",
|
||||
"artwork": "封面图片",
|
||||
"advancedSettings": "高级设置",
|
||||
"title": "标题",
|
||||
"sortTitle": "排序标题",
|
||||
"originalTitle": "原始标题",
|
||||
"releaseDate": "上映日期",
|
||||
"contentRating": "内容分级",
|
||||
"studio": "制片厂",
|
||||
"tagline": "标语",
|
||||
"summary": "简介",
|
||||
"poster": "海报",
|
||||
"background": "背景",
|
||||
"selectPoster": "选择海报",
|
||||
"selectBackground": "选择背景",
|
||||
"fromUrl": "从 URL",
|
||||
"uploadFile": "上传文件",
|
||||
"enterImageUrl": "输入图片 URL",
|
||||
"imageUrl": "图片 URL",
|
||||
"metadataUpdated": "元数据已更新",
|
||||
"metadataUpdateFailed": "元数据更新失败",
|
||||
"artworkUpdated": "封面图片已更新",
|
||||
"artworkUpdateFailed": "封面图片更新失败",
|
||||
"noArtworkAvailable": "没有可用的封面图片",
|
||||
"notSet": "未设置",
|
||||
"libraryDefault": "媒体库默认",
|
||||
"accountDefault": "账户默认",
|
||||
"seriesDefault": "剧集默认",
|
||||
"episodeSorting": "剧集排序",
|
||||
"oldestFirst": "最旧优先",
|
||||
"newestFirst": "最新优先",
|
||||
"keep": "保留",
|
||||
"allEpisodes": "所有剧集",
|
||||
"latestEpisodes": "最新 ${count} 集",
|
||||
"latestEpisode": "最新一集",
|
||||
"episodesAddedPastDays": "过去 ${count} 天内添加的剧集",
|
||||
"deleteAfterPlaying": "播放后删除剧集",
|
||||
"never": "从不",
|
||||
"afterADay": "一天后",
|
||||
"afterAWeek": "一周后",
|
||||
"afterAMonth": "一个月后",
|
||||
"onNextRefresh": "下次刷新时",
|
||||
"seasons": "季",
|
||||
"show": "显示",
|
||||
"hide": "隐藏",
|
||||
"episodeOrdering": "剧集排列顺序",
|
||||
"tmdbAiring": "The Movie Database(播出顺序)",
|
||||
"tvdbAiring": "TheTVDB(播出顺序)",
|
||||
"tvdbAbsolute": "TheTVDB(绝对顺序)",
|
||||
"metadataLanguage": "元数据语言",
|
||||
"useOriginalTitle": "使用原始标题",
|
||||
"preferredAudioLanguage": "首选音频语言",
|
||||
"preferredSubtitleLanguage": "首选字幕语言",
|
||||
"subtitleMode": "自动选择字幕模式",
|
||||
"manuallySelected": "手动选择",
|
||||
"shownWithForeignAudio": "外语音频时显示",
|
||||
"alwaysEnabled": "始终启用"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ class LiveTvChannel {
|
||||
|
||||
factory LiveTvChannel.fromJson(Map<String, dynamic> json) {
|
||||
return LiveTvChannel(
|
||||
key: json['key'] as String? ?? json['ratingKey'] as String? ?? '',
|
||||
key: json['key'] as String? ?? json['ratingKey'] as String? ?? json['identifier'] as String? ?? json['channelIdentifier'] as String? ?? '',
|
||||
identifier: json['identifier'] as String? ?? json['channelIdentifier'] as String?,
|
||||
callSign: json['callSign'] as String?,
|
||||
title: json['title'] as String? ?? json['callSign'] as String?,
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import '../widgets/plex_optimized_image.dart' show kBlurArtwork, obfuscateText;
|
||||
import 'plex_metadata.dart';
|
||||
|
||||
/// Represents a Plex hub/recommendation section (e.g., Trending Movies, Top Thrillers)
|
||||
@@ -54,7 +55,7 @@ class PlexHub {
|
||||
|
||||
return PlexHub(
|
||||
hubKey: json['key'] as String? ?? '',
|
||||
title: json['title'] as String? ?? 'Unknown',
|
||||
title: kBlurArtwork ? obfuscateText(json['title'] as String? ?? 'Unknown') : json['title'] as String? ?? 'Unknown',
|
||||
type: json['type'] as String? ?? 'hub',
|
||||
hubIdentifier: json['hubIdentifier'] as String?,
|
||||
size: (json['size'] as num?)?.toInt() ?? metadataList.length,
|
||||
|
||||
@@ -183,4 +183,51 @@ class PlaybackExtras {
|
||||
final List<PlexMarker> markers;
|
||||
|
||||
PlaybackExtras({required this.chapters, required this.markers});
|
||||
|
||||
static final _introPattern = RegExp(
|
||||
r'(?:^|\b)(?:intro(?:duction)?|opening)(?:\b|$)|^op(?:\s?\d+)?$',
|
||||
caseSensitive: false,
|
||||
);
|
||||
static final _creditsPattern = RegExp(
|
||||
r'(?:^|\b)(?:outro|closing|credits?|ending)(?:\b|$)|^ed(?:\s?\d+)?$',
|
||||
caseSensitive: false,
|
||||
);
|
||||
|
||||
static String? _classifyChapterTitle(String title) {
|
||||
if (_introPattern.hasMatch(title)) return 'intro';
|
||||
if (_creditsPattern.hasMatch(title)) return 'credits';
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Returns [PlaybackExtras] using real markers when available, otherwise
|
||||
/// synthesises markers from chapter titles matching intro/credits patterns.
|
||||
factory PlaybackExtras.withChapterFallback({
|
||||
required List<PlexChapter> chapters,
|
||||
required List<PlexMarker> markers,
|
||||
}) {
|
||||
if (markers.isNotEmpty) {
|
||||
return PlaybackExtras(chapters: chapters, markers: markers);
|
||||
}
|
||||
|
||||
final synthetic = <PlexMarker>[];
|
||||
for (var i = 0; i < chapters.length; i++) {
|
||||
final ch = chapters[i];
|
||||
final title = ch.title;
|
||||
if (title == null || title.isEmpty) continue;
|
||||
|
||||
final type = _classifyChapterTitle(title);
|
||||
if (type == null) continue;
|
||||
|
||||
final start = ch.startTimeOffset;
|
||||
if (start == null) continue;
|
||||
|
||||
final end = ch.endTimeOffset ??
|
||||
(i + 1 < chapters.length ? chapters[i + 1].startTimeOffset : null);
|
||||
if (end == null) continue;
|
||||
|
||||
synthetic.add(PlexMarker(id: ch.id, type: type, startTimeOffset: start, endTimeOffset: end));
|
||||
}
|
||||
|
||||
return PlaybackExtras(chapters: chapters, markers: synthetic);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
import '../services/settings_service.dart' show EpisodePosterMode;
|
||||
import '../widgets/plex_optimized_image.dart' show kBlurArtwork, obfuscateText;
|
||||
import 'mixins/multi_server_fields.dart';
|
||||
import 'plex_role.dart';
|
||||
|
||||
@@ -32,6 +33,18 @@ enum PlexMediaType {
|
||||
|
||||
/// Whether this type can be played directly
|
||||
bool get isPlayable => isVideo || this == track;
|
||||
|
||||
/// Plex API type number for metadata editing endpoints
|
||||
int get typeNumber => switch (this) {
|
||||
PlexMediaType.movie => 1,
|
||||
PlexMediaType.show => 2,
|
||||
PlexMediaType.season => 3,
|
||||
PlexMediaType.episode => 4,
|
||||
PlexMediaType.artist => 8,
|
||||
PlexMediaType.album => 9,
|
||||
PlexMediaType.track => 10,
|
||||
_ => 0,
|
||||
};
|
||||
}
|
||||
|
||||
@JsonSerializable()
|
||||
@@ -47,6 +60,7 @@ class PlexMetadata with MultiServerFields {
|
||||
final String? summary;
|
||||
final double? rating;
|
||||
final double? audienceRating;
|
||||
final double? userRating;
|
||||
final int? year;
|
||||
final String? originallyAvailableAt; // Full release date (YYYY-MM-DD)
|
||||
final String? thumb;
|
||||
@@ -79,6 +93,8 @@ class PlexMetadata with MultiServerFields {
|
||||
final int? librarySectionID; // Library section ID this item belongs to
|
||||
final String? ratingImage; // Rating source URI (e.g. rottentomatoes://image.rating.ripe)
|
||||
final String? audienceRatingImage; // Audience rating source URI
|
||||
final String? tagline;
|
||||
final String? originalTitle;
|
||||
final String? subtype; // Clip subtype: "trailer", "behindTheScenes", "deleted", etc.
|
||||
final int? extraType; // Numeric extra type identifier
|
||||
final String? primaryExtraKey; // Points to main trailer (e.g., "/library/metadata/52601")
|
||||
@@ -127,6 +143,7 @@ class PlexMetadata with MultiServerFields {
|
||||
this.summary,
|
||||
this.rating,
|
||||
this.audienceRating,
|
||||
this.userRating,
|
||||
this.year,
|
||||
this.originallyAvailableAt,
|
||||
this.thumb,
|
||||
@@ -158,6 +175,8 @@ class PlexMetadata with MultiServerFields {
|
||||
this.librarySectionID,
|
||||
this.ratingImage,
|
||||
this.audienceRatingImage,
|
||||
this.tagline,
|
||||
this.originalTitle,
|
||||
this.subtype,
|
||||
this.extraType,
|
||||
this.primaryExtraKey,
|
||||
@@ -179,6 +198,7 @@ class PlexMetadata with MultiServerFields {
|
||||
String? summary,
|
||||
double? rating,
|
||||
double? audienceRating,
|
||||
double? userRating,
|
||||
int? year,
|
||||
String? originallyAvailableAt,
|
||||
String? thumb,
|
||||
@@ -210,6 +230,8 @@ class PlexMetadata with MultiServerFields {
|
||||
int? librarySectionID,
|
||||
String? ratingImage,
|
||||
String? audienceRatingImage,
|
||||
String? tagline,
|
||||
String? originalTitle,
|
||||
String? subtype,
|
||||
int? extraType,
|
||||
String? primaryExtraKey,
|
||||
@@ -229,6 +251,7 @@ class PlexMetadata with MultiServerFields {
|
||||
summary: summary ?? this.summary,
|
||||
rating: rating ?? this.rating,
|
||||
audienceRating: audienceRating ?? this.audienceRating,
|
||||
userRating: userRating ?? this.userRating,
|
||||
year: year ?? this.year,
|
||||
originallyAvailableAt: originallyAvailableAt ?? this.originallyAvailableAt,
|
||||
thumb: thumb ?? this.thumb,
|
||||
@@ -260,6 +283,8 @@ class PlexMetadata with MultiServerFields {
|
||||
librarySectionID: librarySectionID ?? this.librarySectionID,
|
||||
ratingImage: ratingImage ?? this.ratingImage,
|
||||
audienceRatingImage: audienceRatingImage ?? this.audienceRatingImage,
|
||||
tagline: tagline ?? this.tagline,
|
||||
originalTitle: originalTitle ?? this.originalTitle,
|
||||
subtype: subtype ?? this.subtype,
|
||||
extraType: extraType ?? this.extraType,
|
||||
primaryExtraKey: primaryExtraKey ?? this.primaryExtraKey,
|
||||
@@ -382,6 +407,13 @@ class PlexMetadata with MultiServerFields {
|
||||
return false;
|
||||
}
|
||||
|
||||
/// Returns true if this item has started but not finished playback
|
||||
/// Only applicable for individual items (movies, episodes)
|
||||
bool get hasActiveProgress {
|
||||
if (duration == null || viewOffset == null) return false;
|
||||
return viewOffset! > 0 && viewOffset! < duration!;
|
||||
}
|
||||
|
||||
// Helper to determine if content is watched
|
||||
bool get isWatched {
|
||||
// For series/seasons, check if all episodes are watched
|
||||
@@ -393,7 +425,16 @@ class PlexMetadata with MultiServerFields {
|
||||
return viewCount != null && viewCount! > 0;
|
||||
}
|
||||
|
||||
factory PlexMetadata.fromJson(Map<String, dynamic> json) => _$PlexMetadataFromJson(json);
|
||||
factory PlexMetadata.fromJson(Map<String, dynamic> json) =>
|
||||
_$PlexMetadataFromJson(kBlurArtwork ? _obfuscateJson(json) : json);
|
||||
|
||||
static Map<String, dynamic> _obfuscateJson(Map<String, dynamic> json) {
|
||||
final copy = Map<String, dynamic>.from(json);
|
||||
for (final key in const ['title', 'summary', 'tagline', 'grandparentTitle', 'parentTitle', 'studio']) {
|
||||
if (copy[key] is String) copy[key] = obfuscateText(copy[key] as String);
|
||||
}
|
||||
return copy;
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() => _$PlexMetadataToJson(this);
|
||||
}
|
||||
|
||||
@@ -18,6 +18,7 @@ PlexMetadata _$PlexMetadataFromJson(Map<String, dynamic> json) => PlexMetadata(
|
||||
summary: json['summary'] as String?,
|
||||
rating: (json['rating'] as num?)?.toDouble(),
|
||||
audienceRating: (json['audienceRating'] as num?)?.toDouble(),
|
||||
userRating: (json['userRating'] as num?)?.toDouble(),
|
||||
year: (json['year'] as num?)?.toInt(),
|
||||
originallyAvailableAt: json['originallyAvailableAt'] as String?,
|
||||
thumb: json['thumb'] as String?,
|
||||
@@ -49,6 +50,8 @@ PlexMetadata _$PlexMetadataFromJson(Map<String, dynamic> json) => PlexMetadata(
|
||||
librarySectionID: (json['librarySectionID'] as num?)?.toInt(),
|
||||
ratingImage: json['ratingImage'] as String?,
|
||||
audienceRatingImage: json['audienceRatingImage'] as String?,
|
||||
tagline: json['tagline'] as String?,
|
||||
originalTitle: json['originalTitle'] as String?,
|
||||
subtype: json['subtype'] as String?,
|
||||
extraType: (json['extraType'] as num?)?.toInt(),
|
||||
primaryExtraKey: json['primaryExtraKey'] as String?,
|
||||
@@ -67,6 +70,7 @@ Map<String, dynamic> _$PlexMetadataToJson(PlexMetadata instance) => <String, dyn
|
||||
'summary': instance.summary,
|
||||
'rating': instance.rating,
|
||||
'audienceRating': instance.audienceRating,
|
||||
'userRating': instance.userRating,
|
||||
'year': instance.year,
|
||||
'originallyAvailableAt': instance.originallyAvailableAt,
|
||||
'thumb': instance.thumb,
|
||||
@@ -98,6 +102,8 @@ Map<String, dynamic> _$PlexMetadataToJson(PlexMetadata instance) => <String, dyn
|
||||
'librarySectionID': instance.librarySectionID,
|
||||
'ratingImage': instance.ratingImage,
|
||||
'audienceRatingImage': instance.audienceRatingImage,
|
||||
'tagline': instance.tagline,
|
||||
'originalTitle': instance.originalTitle,
|
||||
'subtype': instance.subtype,
|
||||
'extraType': instance.extraType,
|
||||
'primaryExtraKey': instance.primaryExtraKey,
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
import 'package:json_annotation/json_annotation.dart';
|
||||
|
||||
import '../widgets/plex_optimized_image.dart' show kBlurArtwork, obfuscateText;
|
||||
import 'mixins/multi_server_fields.dart';
|
||||
|
||||
part 'plex_playlist.g.dart';
|
||||
@@ -94,7 +95,16 @@ class PlexPlaylist with MultiServerFields {
|
||||
/// Playlists don't track viewed leaf count
|
||||
int? get viewedLeafCount => null;
|
||||
|
||||
factory PlexPlaylist.fromJson(Map<String, dynamic> json) => _$PlexPlaylistFromJson(json);
|
||||
factory PlexPlaylist.fromJson(Map<String, dynamic> json) {
|
||||
if (kBlurArtwork) {
|
||||
final copy = Map<String, dynamic>.from(json);
|
||||
for (final key in const ['title', 'summary']) {
|
||||
if (copy[key] is String) copy[key] = obfuscateText(copy[key] as String);
|
||||
}
|
||||
return _$PlexPlaylistFromJson(copy);
|
||||
}
|
||||
return _$PlexPlaylistFromJson(json);
|
||||
}
|
||||
|
||||
Map<String, dynamic> toJson() => _$PlexPlaylistToJson(this);
|
||||
|
||||
|
||||
@@ -1,3 +1,10 @@
|
||||
/// Represents a contiguous buffered range in the demuxer cache.
|
||||
class BufferRange {
|
||||
final Duration start;
|
||||
final Duration end;
|
||||
const BufferRange({required this.start, required this.end});
|
||||
}
|
||||
|
||||
/// Log level for player messages.
|
||||
enum PlayerLogLevel {
|
||||
/// No logging.
|
||||
|
||||
@@ -2,11 +2,8 @@ import '../player_native.dart';
|
||||
|
||||
/// Linux implementation of [Player].
|
||||
///
|
||||
/// Uses libmpv with OpenGL rendering via GtkGLArea.
|
||||
/// The mpv video is rendered to a GtkGLArea positioned behind
|
||||
/// the Flutter view using a GtkOverlay, with transparent regions
|
||||
/// in the Flutter UI allowing the video to show through.
|
||||
/// Uses libmpv with FlTextureGL — video is rendered to an offscreen FBO
|
||||
/// and composited GPU-side via Flutter's Texture widget.
|
||||
class PlayerLinux extends PlayerNative {
|
||||
@override
|
||||
int? get textureId => null; // Uses GtkGLArea, not Flutter texture
|
||||
// textureId is set during initialize() via PlayerNative
|
||||
}
|
||||
|
||||
@@ -142,6 +142,12 @@ abstract class Player {
|
||||
/// Get an MPV property value by name.
|
||||
Future<String?> getProperty(String name);
|
||||
|
||||
/// Set the native MPV log message level (e.g., "warn", "v", "debug").
|
||||
///
|
||||
/// This controls the volume of log messages sent from the native player
|
||||
/// over the event channel. Use "warn" in production and "v" for debugging.
|
||||
Future<void> setLogLevel(String level);
|
||||
|
||||
/// Execute a raw MPV command.
|
||||
///
|
||||
/// [args] - Command and arguments as a list of strings.
|
||||
|
||||
@@ -9,6 +9,8 @@ class PlayerAndroid extends PlayerBase {
|
||||
static const _methodChannel = MethodChannel('com.plezy/exo_player');
|
||||
static const _eventChannel = EventChannel('com.plezy/exo_player/events');
|
||||
|
||||
int? _bufferSizeBytes;
|
||||
|
||||
@override
|
||||
MethodChannel get methodChannel => _methodChannel;
|
||||
|
||||
@@ -46,7 +48,9 @@ class PlayerAndroid extends PlayerBase {
|
||||
if (initialized) return;
|
||||
|
||||
try {
|
||||
final result = await methodChannel.invokeMethod<bool>('initialize');
|
||||
final result = await methodChannel.invokeMethod<bool>('initialize', {
|
||||
'bufferSizeBytes': _bufferSizeBytes,
|
||||
});
|
||||
initialized = result == true;
|
||||
if (!initialized) {
|
||||
throw Exception('Failed to initialize ExoPlayer');
|
||||
@@ -181,6 +185,9 @@ class PlayerAndroid extends PlayerBase {
|
||||
case 'speed':
|
||||
await setRate(double.tryParse(value) ?? 1.0);
|
||||
break;
|
||||
case 'demuxer-max-bytes':
|
||||
_bufferSizeBytes = int.tryParse(value);
|
||||
break;
|
||||
// Other properties are no-ops for ExoPlayer
|
||||
}
|
||||
}
|
||||
@@ -228,6 +235,17 @@ class PlayerAndroid extends PlayerBase {
|
||||
}
|
||||
}
|
||||
|
||||
/// Get the device's large heap size in MB (Android only).
|
||||
/// Returns 0 if unavailable.
|
||||
static Future<int> getHeapSize() async {
|
||||
try {
|
||||
final result = await _methodChannel.invokeMethod<int>('getHeapSize');
|
||||
return result ?? 0;
|
||||
} catch (e) {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
/// Get the current player type ('exoplayer' or 'mpv' if fallback is active).
|
||||
Future<String> getPlayerType() async {
|
||||
checkDisposed();
|
||||
|
||||
@@ -36,6 +36,7 @@ abstract class PlayerBase with PlayerStreamControllersMixin implements Player {
|
||||
int? get textureId => null;
|
||||
|
||||
StreamSubscription? _eventSubscription;
|
||||
StreamSubscription? _logSubscription;
|
||||
bool _disposed = false;
|
||||
final _throttleSw = Stopwatch()..start();
|
||||
int _lastEmitMs = 0;
|
||||
@@ -63,7 +64,7 @@ abstract class PlayerBase with PlayerStreamControllersMixin implements Player {
|
||||
PlayerBase() {
|
||||
_streams = createStreams();
|
||||
_setupEventListener();
|
||||
logController.stream.listen(_forwardToAppLogger);
|
||||
_logSubscription = logController.stream.listen(_forwardToAppLogger);
|
||||
}
|
||||
|
||||
void _forwardToAppLogger(PlayerLog log) {
|
||||
@@ -89,6 +90,7 @@ abstract class PlayerBase with PlayerStreamControllersMixin implements Player {
|
||||
_eventSubscription = eventChannel.receiveBroadcastStream().listen(
|
||||
_handleEvent,
|
||||
onError: (error) {
|
||||
if (_disposed) return;
|
||||
errorController.add(error.toString());
|
||||
},
|
||||
);
|
||||
@@ -108,8 +110,9 @@ abstract class PlayerBase with PlayerStreamControllersMixin implements Player {
|
||||
}
|
||||
|
||||
void _handleEvent(dynamic event) {
|
||||
if (_disposed) return;
|
||||
if (event is List && event.length == 2) {
|
||||
final name = _propIdToName[event[0]];
|
||||
final name = _propIdToName[event[0] as int];
|
||||
if (name != null) {
|
||||
handlePropertyChange(name, event[1]);
|
||||
}
|
||||
@@ -125,6 +128,7 @@ abstract class PlayerBase with PlayerStreamControllersMixin implements Player {
|
||||
/// Handle a property change event from the platform.
|
||||
/// Subclasses can override this to handle platform-specific properties.
|
||||
void handlePropertyChange(String name, dynamic value) {
|
||||
if (_disposed) return;
|
||||
switch (name) {
|
||||
case 'pause':
|
||||
final playing = value == false;
|
||||
@@ -172,9 +176,18 @@ abstract class PlayerBase with PlayerStreamControllersMixin implements Player {
|
||||
final buffer = Duration(milliseconds: (value * 1000).toInt());
|
||||
_state = _state.copyWith(buffer: buffer);
|
||||
bufferController.add(buffer);
|
||||
// Synthesize a single range for players without demuxer-cache-state (ExoPlayer).
|
||||
// ExoPlayer only buffers ahead of the current position, so use position as start.
|
||||
final ranges = [BufferRange(start: _state.position, end: buffer)];
|
||||
_state = _state.copyWith(bufferRanges: ranges);
|
||||
bufferRangesController.add(ranges);
|
||||
}
|
||||
break;
|
||||
|
||||
case 'demuxer-cache-state':
|
||||
_handleDemuxerCacheState(value);
|
||||
break;
|
||||
|
||||
case 'volume':
|
||||
if (value is num) {
|
||||
final volume = value.toDouble();
|
||||
@@ -217,12 +230,90 @@ abstract class PlayerBase with PlayerStreamControllersMixin implements Player {
|
||||
case 'sid':
|
||||
updateSelectedSubtitleTrack(value);
|
||||
break;
|
||||
|
||||
case 'audio-device-list':
|
||||
List? deviceList;
|
||||
if (value is List) {
|
||||
deviceList = value;
|
||||
} else if (value is String && value.isNotEmpty) {
|
||||
try {
|
||||
final parsed = jsonDecode(value);
|
||||
if (parsed is List) deviceList = parsed;
|
||||
} catch (_) {}
|
||||
}
|
||||
if (deviceList != null) {
|
||||
final devices = deviceList
|
||||
.whereType<Map>()
|
||||
.map((d) => AudioDevice(
|
||||
name: d['name'] as String? ?? '',
|
||||
description: d['description'] as String? ?? '',
|
||||
))
|
||||
.toList();
|
||||
_state = _state.copyWith(audioDevices: devices);
|
||||
audioDevicesController.add(devices);
|
||||
}
|
||||
break;
|
||||
|
||||
case 'audio-device':
|
||||
if (value is String && value.isNotEmpty) {
|
||||
final device = _state.audioDevices.cast<AudioDevice?>().firstWhere(
|
||||
(d) => d?.name == value,
|
||||
orElse: () => AudioDevice(name: value),
|
||||
) ??
|
||||
AudioDevice(name: value);
|
||||
_state = _state.copyWith(audioDevice: device);
|
||||
audioDeviceController.add(device);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
/// Parse demuxer-cache-state property to extract seekable ranges and buffer end.
|
||||
void _handleDemuxerCacheState(dynamic value) {
|
||||
Map? cacheState;
|
||||
if (value is Map) {
|
||||
cacheState = value;
|
||||
} else if (value is String && value.isNotEmpty) {
|
||||
try {
|
||||
final parsed = jsonDecode(value);
|
||||
if (parsed is Map) cacheState = parsed;
|
||||
} catch (_) {}
|
||||
}
|
||||
if (cacheState == null) return;
|
||||
|
||||
// Extract cache-end for the single buffer duration (replaces demuxer-cache-time)
|
||||
final cacheEnd = cacheState['cache-end'] as num?;
|
||||
if (cacheEnd != null) {
|
||||
final buffer = Duration(milliseconds: (cacheEnd * 1000).toInt());
|
||||
_state = _state.copyWith(buffer: buffer);
|
||||
bufferController.add(buffer);
|
||||
}
|
||||
|
||||
// Extract seekable-ranges array
|
||||
final seekableRanges = cacheState['seekable-ranges'];
|
||||
if (seekableRanges is List) {
|
||||
final ranges = <BufferRange>[];
|
||||
for (final range in seekableRanges) {
|
||||
if (range is Map) {
|
||||
final start = range['start'] as num?;
|
||||
final end = range['end'] as num?;
|
||||
if (start != null && end != null) {
|
||||
ranges.add(BufferRange(
|
||||
start: Duration(milliseconds: (start * 1000).toInt()),
|
||||
end: Duration(milliseconds: (end * 1000).toInt()),
|
||||
));
|
||||
}
|
||||
}
|
||||
}
|
||||
_state = _state.copyWith(bufferRanges: ranges);
|
||||
bufferRangesController.add(ranges);
|
||||
}
|
||||
}
|
||||
|
||||
/// Handle a player event from the platform.
|
||||
/// Subclasses can override this to handle platform-specific events.
|
||||
void handlePlayerEvent(String name, Map? data) {
|
||||
if (_disposed) return;
|
||||
switch (name) {
|
||||
case 'end-file':
|
||||
final reason = data?['reason'] as String?;
|
||||
@@ -240,6 +331,10 @@ abstract class PlayerBase with PlayerStreamControllersMixin implements Player {
|
||||
break;
|
||||
|
||||
case 'playback-restart':
|
||||
// Clear stale buffer ranges from before the seek; fresh ones will
|
||||
// arrive shortly via the next demuxer-cache-state update.
|
||||
_state = _state.copyWith(bufferRanges: const []);
|
||||
bufferRangesController.add(const []);
|
||||
playbackRestartController.add(null);
|
||||
break;
|
||||
|
||||
@@ -401,6 +496,10 @@ abstract class PlayerBase with PlayerStreamControllersMixin implements Player {
|
||||
// ignore: no-empty-block - base no-op, overridden by platform subclasses
|
||||
Future<void> setAudioPassthrough(bool enabled) async {}
|
||||
|
||||
@override
|
||||
// ignore: no-empty-block - base no-op, overridden by platform subclasses
|
||||
Future<void> setLogLevel(String level) async {}
|
||||
|
||||
// ============================================
|
||||
// Lifecycle
|
||||
// ============================================
|
||||
@@ -411,6 +510,7 @@ abstract class PlayerBase with PlayerStreamControllersMixin implements Player {
|
||||
_disposed = true;
|
||||
|
||||
await _eventSubscription?.cancel();
|
||||
await _logSubscription?.cancel();
|
||||
await methodChannel.invokeMethod('dispose');
|
||||
await closeStreamControllers();
|
||||
}
|
||||
|
||||
@@ -6,9 +6,15 @@ import '../font_loader.dart';
|
||||
import '../models.dart';
|
||||
import 'player_base.dart';
|
||||
|
||||
/// Shared native implementation of [Player] for iOS, macOS, and Android (MPV fallback).
|
||||
/// Uses MPVKit via platform channels with Metal rendering (Apple) or native window (Android).
|
||||
/// Shared native implementation of [Player] for iOS, macOS, Android (MPV fallback), and Linux.
|
||||
/// Uses MPVKit via platform channels with Metal rendering (Apple), native window (Android),
|
||||
/// or FlTextureGL (Linux).
|
||||
class PlayerNative extends PlayerBase {
|
||||
int? _textureIdValue;
|
||||
|
||||
@override
|
||||
int? get textureId => _textureIdValue;
|
||||
|
||||
static const _methodChannel = MethodChannel('com.plezy/mpv_player');
|
||||
static const _eventChannel = EventChannel('com.plezy/mpv_player/events');
|
||||
|
||||
@@ -24,6 +30,10 @@ class PlayerNative extends PlayerBase {
|
||||
@override
|
||||
String get playerType => 'mpv';
|
||||
|
||||
/// Node properties are returned as structured maps on macOS/iOS/Linux,
|
||||
/// but as JSON strings on Android/Windows.
|
||||
static final String _nodeFormat = (Platform.isAndroid || Platform.isWindows) ? 'string' : 'node';
|
||||
|
||||
// ============================================
|
||||
// Initialization
|
||||
// ============================================
|
||||
@@ -32,8 +42,14 @@ class PlayerNative extends PlayerBase {
|
||||
if (initialized) return;
|
||||
|
||||
try {
|
||||
final result = await methodChannel.invokeMethod<bool>('initialize');
|
||||
initialized = result == true;
|
||||
final result = await methodChannel.invokeMethod<Object>('initialize');
|
||||
if (result is int) {
|
||||
// Linux: initialize returns the texture ID
|
||||
_textureIdValue = result;
|
||||
initialized = true;
|
||||
} else {
|
||||
initialized = result == true;
|
||||
}
|
||||
if (!initialized) {
|
||||
throw Exception('Failed to initialize player');
|
||||
}
|
||||
@@ -46,12 +62,15 @@ class PlayerNative extends PlayerBase {
|
||||
await observeProperty('duration', 'double');
|
||||
await observeProperty('pause', 'flag');
|
||||
await observeProperty('paused-for-cache', 'flag');
|
||||
await observeProperty('track-list', (Platform.isAndroid || Platform.isWindows) ? 'string' : 'node');
|
||||
await observeProperty('track-list', _nodeFormat);
|
||||
await observeProperty('eof-reached', 'flag');
|
||||
await observeProperty('volume', 'double');
|
||||
await observeProperty('speed', 'double');
|
||||
await observeProperty('aid', 'string');
|
||||
await observeProperty('sid', 'string');
|
||||
await observeProperty('demuxer-cache-state', _nodeFormat);
|
||||
await observeProperty('audio-device-list', _nodeFormat);
|
||||
await observeProperty('audio-device', 'string');
|
||||
} catch (e) {
|
||||
errorController.add('Initialization failed: $e');
|
||||
rethrow;
|
||||
@@ -228,6 +247,17 @@ class PlayerNative extends PlayerBase {
|
||||
await methodChannel.invokeMethod('command', {'args': args});
|
||||
}
|
||||
|
||||
// ============================================
|
||||
// Log Level
|
||||
// ============================================
|
||||
|
||||
@override
|
||||
Future<void> setLogLevel(String level) async {
|
||||
checkDisposed();
|
||||
await _ensureInitialized();
|
||||
await methodChannel.invokeMethod('setLogLevel', {'level': level});
|
||||
}
|
||||
|
||||
// ============================================
|
||||
// Passthrough
|
||||
// ============================================
|
||||
|
||||
@@ -50,6 +50,9 @@ class PlayerState {
|
||||
/// Available audio output devices.
|
||||
final List<AudioDevice> audioDevices;
|
||||
|
||||
/// Seekable buffered ranges from the demuxer cache.
|
||||
final List<BufferRange> bufferRanges;
|
||||
|
||||
const PlayerState({
|
||||
this.playing = false,
|
||||
this.completed = false,
|
||||
@@ -66,6 +69,7 @@ class PlayerState {
|
||||
this.audioPassthrough = false,
|
||||
this.audioDevice = AudioDevice.auto,
|
||||
this.audioDevices = const [],
|
||||
this.bufferRanges = const [],
|
||||
});
|
||||
|
||||
/// Creates a copy with the given fields replaced.
|
||||
@@ -85,6 +89,7 @@ class PlayerState {
|
||||
bool? audioPassthrough,
|
||||
AudioDevice? audioDevice,
|
||||
List<AudioDevice>? audioDevices,
|
||||
List<BufferRange>? bufferRanges,
|
||||
}) {
|
||||
return PlayerState(
|
||||
playing: playing ?? this.playing,
|
||||
@@ -102,6 +107,7 @@ class PlayerState {
|
||||
audioPassthrough: audioPassthrough ?? this.audioPassthrough,
|
||||
audioDevice: audioDevice ?? this.audioDevice,
|
||||
audioDevices: audioDevices ?? this.audioDevices,
|
||||
bufferRanges: bufferRanges ?? this.bufferRanges,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -23,6 +23,7 @@ mixin PlayerStreamControllersMixin {
|
||||
final errorController = StreamController<String>.broadcast();
|
||||
final audioDeviceController = StreamController<AudioDevice>.broadcast();
|
||||
final audioDevicesController = StreamController<List<AudioDevice>>.broadcast();
|
||||
final bufferRangesController = StreamController<List<BufferRange>>.broadcast();
|
||||
final playbackRestartController = StreamController<void>.broadcast();
|
||||
final backendSwitchedController = StreamController<void>.broadcast();
|
||||
|
||||
@@ -43,6 +44,7 @@ mixin PlayerStreamControllersMixin {
|
||||
error: errorController.stream,
|
||||
audioDevice: audioDeviceController.stream,
|
||||
audioDevices: audioDevicesController.stream,
|
||||
bufferRanges: bufferRangesController.stream,
|
||||
playbackRestart: playbackRestartController.stream,
|
||||
backendSwitched: backendSwitchedController.stream,
|
||||
);
|
||||
@@ -64,6 +66,7 @@ mixin PlayerStreamControllersMixin {
|
||||
await errorController.close();
|
||||
await audioDeviceController.close();
|
||||
await audioDevicesController.close();
|
||||
await bufferRangesController.close();
|
||||
await playbackRestartController.close();
|
||||
await backendSwitchedController.close();
|
||||
}
|
||||
|
||||
@@ -50,6 +50,9 @@ class PlayerStreams {
|
||||
/// Stream that emits when playback restarts (first frame ready after load/seek).
|
||||
final Stream<void> playbackRestart;
|
||||
|
||||
/// Stream of seekable buffer ranges from the demuxer cache.
|
||||
final Stream<List<BufferRange>> bufferRanges;
|
||||
|
||||
/// Stream that emits when the native player backend switches (e.g., ExoPlayer to MPV).
|
||||
/// Only emitted on Android when ExoPlayer encounters an unsupported format.
|
||||
final Stream<void> backendSwitched;
|
||||
@@ -69,6 +72,7 @@ class PlayerStreams {
|
||||
required this.error,
|
||||
required this.audioDevice,
|
||||
required this.audioDevices,
|
||||
required this.bufferRanges,
|
||||
required this.playbackRestart,
|
||||
required this.backendSwitched,
|
||||
});
|
||||
|
||||
+8
-1
@@ -74,7 +74,14 @@ class _VideoState extends State<Video> {
|
||||
}
|
||||
|
||||
Widget _buildVideoSurface() {
|
||||
// For players that support video rect positioning (Windows, Linux),
|
||||
// For players that use Flutter's texture pipeline (Linux FlTextureGL),
|
||||
// render directly via the Texture widget.
|
||||
final textureId = widget.player.textureId;
|
||||
if (textureId != null) {
|
||||
return Texture(textureId: textureId);
|
||||
}
|
||||
|
||||
// For players that support video rect positioning (Windows),
|
||||
// communicate layout changes to the native side.
|
||||
if (widget.player is VideoRectSupport) {
|
||||
return LayoutBuilder(
|
||||
|
||||
@@ -57,6 +57,12 @@ class PlaybackStateProvider with ChangeNotifier {
|
||||
/// Current play queue ID
|
||||
int? get playQueueId => _playQueueId;
|
||||
|
||||
/// The currently loaded queue items (windowed subset of full queue)
|
||||
List<PlexMetadata> get loadedItems => List.unmodifiable(_loadedItems);
|
||||
|
||||
/// The current play queue item ID
|
||||
int? get currentPlayQueueItemID => _currentPlayQueueItemID;
|
||||
|
||||
/// Total number of items in the play queue
|
||||
int get queueLength => _playQueueTotalCount;
|
||||
|
||||
|
||||
@@ -223,14 +223,13 @@ class UserProfileProvider extends ChangeNotifier {
|
||||
}
|
||||
}
|
||||
|
||||
Future<bool> switchToUser(PlexHomeUser user, BuildContext? context) async {
|
||||
Future<bool> switchToUser(PlexHomeUser user, BuildContext? context, {bool verifyPin = false}) async {
|
||||
if (_authService == null || _storageService == null) {
|
||||
_setError('Services not initialized');
|
||||
return false;
|
||||
}
|
||||
|
||||
if (user.uuid == _currentUser?.uuid) {
|
||||
// Already on this user
|
||||
if (user.uuid == _currentUser?.uuid && !(verifyPin && user.requiresPassword)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -16,6 +16,7 @@ import '../i18n/strings.g.dart';
|
||||
import '../theme/mono_tokens.dart';
|
||||
import '../utils/app_logger.dart';
|
||||
import '../utils/platform_detector.dart';
|
||||
import '../focus/focusable_button.dart';
|
||||
import 'main_screen.dart';
|
||||
|
||||
class AuthScreen extends StatefulWidget {
|
||||
@@ -398,7 +399,7 @@ class _AuthScreenState extends State<AuthScreen> {
|
||||
children: [
|
||||
if (isTV) ...[
|
||||
// On TV: QR is primary, browser is secondary
|
||||
ElevatedButton(
|
||||
FocusableButton(
|
||||
autofocus: true,
|
||||
onPressed: () {
|
||||
setState(() {
|
||||
@@ -406,14 +407,25 @@ class _AuthScreenState extends State<AuthScreen> {
|
||||
});
|
||||
_startAuthentication();
|
||||
},
|
||||
style: ElevatedButton.styleFrom(padding: const EdgeInsets.symmetric(vertical: 16)),
|
||||
child: Text(t.auth.showQRCode),
|
||||
child: ElevatedButton(
|
||||
onPressed: () {
|
||||
setState(() {
|
||||
_useQrFlow = true;
|
||||
});
|
||||
_startAuthentication();
|
||||
},
|
||||
style: ElevatedButton.styleFrom(padding: const EdgeInsets.symmetric(vertical: 16)),
|
||||
child: Text(t.auth.showQRCode),
|
||||
),
|
||||
),
|
||||
const SizedBox(height: 12),
|
||||
OutlinedButton(
|
||||
FocusableButton(
|
||||
onPressed: _startAuthentication,
|
||||
style: OutlinedButton.styleFrom(padding: const EdgeInsets.symmetric(vertical: 16)),
|
||||
child: Text(t.auth.useBrowser),
|
||||
child: OutlinedButton(
|
||||
onPressed: _startAuthentication,
|
||||
style: OutlinedButton.styleFrom(padding: const EdgeInsets.symmetric(vertical: 16)),
|
||||
child: Text(t.auth.useBrowser),
|
||||
),
|
||||
),
|
||||
] else ...[
|
||||
// On other platforms: Browser is primary, QR is secondary
|
||||
@@ -500,22 +512,33 @@ class _AuthScreenState extends State<AuthScreen> {
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
OutlinedButton(
|
||||
FocusableButton(
|
||||
autofocus: true,
|
||||
onPressed: _retryAuthentication,
|
||||
style: OutlinedButton.styleFrom(padding: const EdgeInsets.symmetric(vertical: 12, horizontal: 24)),
|
||||
child: Text(t.common.retry),
|
||||
child: OutlinedButton(
|
||||
onPressed: _retryAuthentication,
|
||||
style: OutlinedButton.styleFrom(padding: const EdgeInsets.symmetric(vertical: 12, horizontal: 24)),
|
||||
child: Text(t.common.retry),
|
||||
),
|
||||
),
|
||||
const SizedBox(width: 16),
|
||||
OutlinedButton(
|
||||
FocusableButton(
|
||||
onPressed: () {
|
||||
setState(() {
|
||||
_useQrFlow = false;
|
||||
});
|
||||
_startAuthentication();
|
||||
},
|
||||
style: OutlinedButton.styleFrom(padding: const EdgeInsets.symmetric(vertical: 12, horizontal: 24)),
|
||||
child: Text(t.auth.useBrowser),
|
||||
child: OutlinedButton(
|
||||
onPressed: () {
|
||||
setState(() {
|
||||
_useQrFlow = false;
|
||||
});
|
||||
_startAuthentication();
|
||||
},
|
||||
style: OutlinedButton.styleFrom(padding: const EdgeInsets.symmetric(vertical: 12, horizontal: 24)),
|
||||
child: Text(t.auth.useBrowser),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
|
||||
@@ -8,6 +8,7 @@ import '../../i18n/strings.g.dart';
|
||||
import '../../providers/companion_remote_provider.dart';
|
||||
import '../../utils/platform_detector.dart';
|
||||
import '../../utils/app_logger.dart';
|
||||
import '../../widgets/overlay_sheet.dart';
|
||||
import 'pairing_screen.dart';
|
||||
|
||||
class MobileRemoteScreen extends StatefulWidget {
|
||||
@@ -20,101 +21,103 @@ class MobileRemoteScreen extends StatefulWidget {
|
||||
class _MobileRemoteScreenState extends State<MobileRemoteScreen> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text(t.companionRemote.title),
|
||||
actions: [
|
||||
Consumer<CompanionRemoteProvider>(
|
||||
builder: (context, provider, child) {
|
||||
if (provider.isConnected) {
|
||||
return IconButton(
|
||||
icon: const Icon(Icons.link_off),
|
||||
onPressed: () async {
|
||||
final confirmed = await showDialog<bool>(
|
||||
context: context,
|
||||
builder: (context) => AlertDialog(
|
||||
title: Text(t.common.disconnect),
|
||||
content: Text(t.companionRemote.remote.disconnectConfirm),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(context, false), child: Text(t.common.cancel)),
|
||||
TextButton(onPressed: () => Navigator.pop(context, true), child: Text(t.common.disconnect)),
|
||||
],
|
||||
),
|
||||
);
|
||||
return OverlaySheetHost(
|
||||
child: Scaffold(
|
||||
appBar: AppBar(
|
||||
title: Text(t.companionRemote.title),
|
||||
actions: [
|
||||
Consumer<CompanionRemoteProvider>(
|
||||
builder: (context, provider, child) {
|
||||
if (provider.isConnected) {
|
||||
return IconButton(
|
||||
icon: const Icon(Icons.link_off),
|
||||
onPressed: () async {
|
||||
final confirmed = await showDialog<bool>(
|
||||
context: context,
|
||||
builder: (context) => AlertDialog(
|
||||
title: Text(t.common.disconnect),
|
||||
content: Text(t.companionRemote.remote.disconnectConfirm),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(context, false), child: Text(t.common.cancel)),
|
||||
TextButton(onPressed: () => Navigator.pop(context, true), child: Text(t.common.disconnect)),
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
if (confirmed == true && context.mounted) {
|
||||
await context.read<CompanionRemoteProvider>().leaveSession();
|
||||
}
|
||||
},
|
||||
tooltip: t.common.disconnect,
|
||||
);
|
||||
}
|
||||
return const SizedBox.shrink();
|
||||
},
|
||||
),
|
||||
],
|
||||
),
|
||||
body: Consumer<CompanionRemoteProvider>(
|
||||
builder: (context, provider, child) {
|
||||
if (provider.status == RemoteSessionStatus.reconnecting) {
|
||||
return Center(
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
const CircularProgressIndicator(),
|
||||
const SizedBox(height: 24),
|
||||
Text(t.companionRemote.remote.reconnecting, style: Theme.of(context).textTheme.titleLarge),
|
||||
const SizedBox(height: 8),
|
||||
Text(
|
||||
t.companionRemote.remote.attemptOf(current: provider.reconnectAttempts),
|
||||
style: Theme.of(context).textTheme.bodyMedium?.copyWith(color: Colors.grey),
|
||||
),
|
||||
const SizedBox(height: 32),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
OutlinedButton(onPressed: () => provider.cancelReconnect(), child: Text(t.common.cancel)),
|
||||
const SizedBox(width: 16),
|
||||
FilledButton(
|
||||
onPressed: () => provider.retryReconnectNow(),
|
||||
child: Text(t.companionRemote.remote.retryNow),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
if (!provider.isConnected) {
|
||||
return Center(
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
const Icon(Icons.phonelink_off, size: 64, color: Colors.grey),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
provider.status == RemoteSessionStatus.error
|
||||
? provider.session?.errorMessage ?? t.companionRemote.remote.connectionError
|
||||
: t.companionRemote.remote.notConnected,
|
||||
style: const TextStyle(fontSize: 20, color: Colors.grey),
|
||||
textAlign: TextAlign.center,
|
||||
),
|
||||
const SizedBox(height: 32),
|
||||
FilledButton.icon(
|
||||
onPressed: () {
|
||||
Navigator.push(context, MaterialPageRoute(builder: (context) => const PairingScreen()));
|
||||
if (confirmed == true && context.mounted) {
|
||||
await context.read<CompanionRemoteProvider>().leaveSession();
|
||||
}
|
||||
},
|
||||
icon: const Icon(Icons.link),
|
||||
label: Text(t.companionRemote.connectToDevice),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
tooltip: t.common.disconnect,
|
||||
);
|
||||
}
|
||||
return const SizedBox.shrink();
|
||||
},
|
||||
),
|
||||
],
|
||||
),
|
||||
body: Consumer<CompanionRemoteProvider>(
|
||||
builder: (context, provider, child) {
|
||||
if (provider.status == RemoteSessionStatus.reconnecting) {
|
||||
return Center(
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
const CircularProgressIndicator(),
|
||||
const SizedBox(height: 24),
|
||||
Text(t.companionRemote.remote.reconnecting, style: Theme.of(context).textTheme.titleLarge),
|
||||
const SizedBox(height: 8),
|
||||
Text(
|
||||
t.companionRemote.remote.attemptOf(current: provider.reconnectAttempts),
|
||||
style: Theme.of(context).textTheme.bodyMedium?.copyWith(color: Colors.grey),
|
||||
),
|
||||
const SizedBox(height: 32),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
OutlinedButton(onPressed: () => provider.cancelReconnect(), child: Text(t.common.cancel)),
|
||||
const SizedBox(width: 16),
|
||||
FilledButton(
|
||||
onPressed: () => provider.retryReconnectNow(),
|
||||
child: Text(t.companionRemote.remote.retryNow),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
return const _RemoteControlLayout();
|
||||
},
|
||||
if (!provider.isConnected) {
|
||||
return Center(
|
||||
child: Column(
|
||||
mainAxisAlignment: MainAxisAlignment.center,
|
||||
children: [
|
||||
const Icon(Icons.phonelink_off, size: 64, color: Colors.grey),
|
||||
const SizedBox(height: 16),
|
||||
Text(
|
||||
provider.status == RemoteSessionStatus.error
|
||||
? provider.session?.errorMessage ?? t.companionRemote.remote.connectionError
|
||||
: t.companionRemote.remote.notConnected,
|
||||
style: const TextStyle(fontSize: 20, color: Colors.grey),
|
||||
textAlign: TextAlign.center,
|
||||
),
|
||||
const SizedBox(height: 32),
|
||||
FilledButton.icon(
|
||||
onPressed: () {
|
||||
Navigator.push(context, MaterialPageRoute(builder: (context) => const PairingScreen()));
|
||||
},
|
||||
icon: const Icon(Icons.link),
|
||||
label: Text(t.companionRemote.connectToDevice),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
return const _RemoteControlLayout();
|
||||
},
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
@@ -150,11 +153,7 @@ class _RemoteControlContentState extends State<_RemoteControlContent> {
|
||||
_sendCommand(RemoteCommandType.tabSearch);
|
||||
}
|
||||
final provider = context.read<CompanionRemoteProvider>();
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
isScrollControlled: true,
|
||||
builder: (_) => _SearchBottomSheet(provider: provider),
|
||||
);
|
||||
OverlaySheetController.of(context).show(builder: (_) => _SearchBottomSheet(provider: provider));
|
||||
}
|
||||
|
||||
void _sendCommand(RemoteCommandType type) {
|
||||
@@ -632,7 +631,7 @@ class _SearchBottomSheetState extends State<_SearchBottomSheet> {
|
||||
if (trimmed.isNotEmpty) {
|
||||
widget.provider.sendCommand(RemoteCommandType.search, data: {'query': trimmed});
|
||||
}
|
||||
Navigator.pop(context);
|
||||
OverlaySheetController.of(context).close();
|
||||
}
|
||||
|
||||
@override
|
||||
|
||||
@@ -5,6 +5,7 @@ import 'package:flutter/services.dart';
|
||||
import 'package:mobile_scanner/mobile_scanner.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
import '../../focus/focusable_button.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
import '../../providers/companion_remote_provider.dart';
|
||||
import '../../utils/formatters.dart';
|
||||
@@ -143,8 +144,9 @@ class _PairingScreenState extends State<PairingScreen> {
|
||||
if (data == _lastScannedCode) return;
|
||||
_lastScannedCode = data;
|
||||
|
||||
// New format: ip|port|sessionId|pin (4 parts separated by pipe)
|
||||
final parts = data.split('|');
|
||||
// Strip URL wrapper if present (e.g. "https://plezy.app/scan#ip|port|sid|pin")
|
||||
final payload = data.contains('#') ? data.split('#').last : data;
|
||||
final parts = payload.split('|');
|
||||
if (parts.length == 4) {
|
||||
final ip = parts.first;
|
||||
final port = parts[1];
|
||||
@@ -440,8 +442,18 @@ class _PairingScreenState extends State<PairingScreen> {
|
||||
title: Text(t.companionRemote.pairing.removeRecentConnection),
|
||||
content: Text(t.companionRemote.pairing.removeConfirm(name: session.deviceName)),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(context, false), child: Text(t.common.cancel)),
|
||||
TextButton(onPressed: () => Navigator.pop(context, true), child: Text(t.common.remove)),
|
||||
FocusableButton(
|
||||
autofocus: true,
|
||||
onPressed: () => Navigator.pop(context, false),
|
||||
child: TextButton(
|
||||
onPressed: () => Navigator.pop(context, false),
|
||||
child: Text(t.common.cancel),
|
||||
),
|
||||
),
|
||||
FocusableButton(
|
||||
onPressed: () => Navigator.pop(context, true),
|
||||
child: TextButton(onPressed: () => Navigator.pop(context, true), child: Text(t.common.remove)),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
@@ -9,6 +9,7 @@ import '../focus/dpad_navigator.dart';
|
||||
import 'package:cached_network_image/cached_network_image.dart';
|
||||
import '../../services/plex_client.dart';
|
||||
import '../utils/plex_image_helper.dart';
|
||||
import '../widgets/plex_optimized_image.dart' show blurArtwork;
|
||||
import '../models/plex_metadata.dart';
|
||||
import '../utils/content_utils.dart';
|
||||
import '../models/plex_hub.dart';
|
||||
@@ -1581,14 +1582,14 @@ class _DiscoverScreenState extends State<DiscoverScreen>
|
||||
imageType: ImageType.art,
|
||||
);
|
||||
|
||||
return CachedNetworkImage(
|
||||
return blurArtwork(CachedNetworkImage(
|
||||
imageUrl: imageUrl,
|
||||
fit: BoxFit.cover,
|
||||
placeholder: (context, url) =>
|
||||
Container(color: Theme.of(context).colorScheme.surfaceContainerHighest),
|
||||
errorWidget: (context, url, error) =>
|
||||
Container(color: Theme.of(context).colorScheme.surfaceContainerHighest),
|
||||
);
|
||||
));
|
||||
},
|
||||
),
|
||||
),
|
||||
@@ -1649,7 +1650,7 @@ class _DiscoverScreenState extends State<DiscoverScreen>
|
||||
imageType: ImageType.logo,
|
||||
);
|
||||
|
||||
return CachedNetworkImage(
|
||||
return blurArtwork(CachedNetworkImage(
|
||||
imageUrl: logoUrl,
|
||||
filterQuality: FilterQuality.medium,
|
||||
fit: BoxFit.contain,
|
||||
@@ -1696,7 +1697,7 @@ class _DiscoverScreenState extends State<DiscoverScreen>
|
||||
),
|
||||
);
|
||||
},
|
||||
);
|
||||
), sigma: 10, clip: false);
|
||||
},
|
||||
),
|
||||
)
|
||||
|
||||
@@ -10,8 +10,17 @@ import '../providers/settings_provider.dart';
|
||||
import '../services/settings_service.dart';
|
||||
import '../utils/provider_extensions.dart';
|
||||
import '../utils/app_logger.dart';
|
||||
import '../widgets/media_grid_sliver.dart';
|
||||
import '../widgets/focused_scroll_scaffold.dart';
|
||||
import '../utils/grid_size_calculator.dart';
|
||||
import '../widgets/focusable_media_card.dart';
|
||||
import '../widgets/media_grid_delegate.dart';
|
||||
import '../widgets/desktop_app_bar.dart';
|
||||
import '../widgets/overlay_sheet.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import '../focus/dpad_navigator.dart';
|
||||
import '../focus/focus_theme.dart';
|
||||
import '../focus/input_mode_tracker.dart';
|
||||
import '../focus/key_event_utils.dart';
|
||||
import '../mixins/grid_focus_node_mixin.dart';
|
||||
import 'libraries/sort_bottom_sheet.dart';
|
||||
import 'libraries/state_messages.dart';
|
||||
import '../mixins/refreshable.dart';
|
||||
@@ -27,7 +36,7 @@ class HubDetailScreen extends StatefulWidget {
|
||||
State<HubDetailScreen> createState() => _HubDetailScreenState();
|
||||
}
|
||||
|
||||
class _HubDetailScreenState extends State<HubDetailScreen> with Refreshable {
|
||||
class _HubDetailScreenState extends State<HubDetailScreen> with Refreshable, GridFocusNodeMixin {
|
||||
PlexClient get client => _getClientForHub();
|
||||
|
||||
List<PlexMetadata> _items = [];
|
||||
@@ -38,6 +47,14 @@ class _HubDetailScreenState extends State<HubDetailScreen> with Refreshable {
|
||||
bool _isLoading = false;
|
||||
String? _errorMessage;
|
||||
|
||||
late final FocusNode _firstItemFocusNode = FocusNode(debugLabel: 'hub_detail_first_item');
|
||||
late final FocusNode _sortButtonFocusNode = FocusNode(debugLabel: 'hub_detail_sort');
|
||||
bool _isAppBarFocused = false;
|
||||
bool _backHandledByKeyEvent = false;
|
||||
|
||||
/// Key for getting a context below OverlaySheetHost
|
||||
final GlobalKey _overlayChildKey = GlobalKey();
|
||||
|
||||
/// Get the correct PlexClient for this hub's server
|
||||
PlexClient _getClientForHub() {
|
||||
return context.getClientForServer(widget.hub.serverId!);
|
||||
@@ -46,6 +63,7 @@ class _HubDetailScreenState extends State<HubDetailScreen> with Refreshable {
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
_sortButtonFocusNode.addListener(_onSortButtonFocusChange);
|
||||
// Start with items already loaded in the hub
|
||||
_items = widget.hub.items;
|
||||
_filteredItems = widget.hub.items;
|
||||
@@ -55,6 +73,72 @@ class _HubDetailScreenState extends State<HubDetailScreen> with Refreshable {
|
||||
}
|
||||
// Load sorts based on the library type
|
||||
_loadSorts();
|
||||
// Auto-focus first grid item in keyboard mode after first frame
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||
if (!mounted) return;
|
||||
if (InputModeTracker.isKeyboardMode(context) && _filteredItems.isNotEmpty) {
|
||||
_firstItemFocusNode.requestFocus();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@override
|
||||
void dispose() {
|
||||
_sortButtonFocusNode.removeListener(_onSortButtonFocusChange);
|
||||
_firstItemFocusNode.dispose();
|
||||
_sortButtonFocusNode.dispose();
|
||||
disposeGridFocusNodes();
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
void _onSortButtonFocusChange() {
|
||||
if (!mounted) return;
|
||||
final hasFocus = _sortButtonFocusNode.hasFocus;
|
||||
if (hasFocus && !_isAppBarFocused) {
|
||||
setState(() => _isAppBarFocused = true);
|
||||
} else if (!hasFocus && _isAppBarFocused) {
|
||||
setState(() => _isAppBarFocused = false);
|
||||
}
|
||||
}
|
||||
|
||||
void _focusGrid() {
|
||||
if (_filteredItems.isEmpty) return;
|
||||
final targetIndex =
|
||||
shouldRestoreGridFocus && lastFocusedGridIndex! < _filteredItems.length ? lastFocusedGridIndex! : 0;
|
||||
if (targetIndex == 0) {
|
||||
_firstItemFocusNode.requestFocus();
|
||||
} else {
|
||||
getGridItemFocusNode(targetIndex, prefix: 'hub_detail_item').requestFocus();
|
||||
}
|
||||
}
|
||||
|
||||
void _navigateToAppBar() {
|
||||
setState(() => _isAppBarFocused = true);
|
||||
_sortButtonFocusNode.requestFocus();
|
||||
}
|
||||
|
||||
void _handleBackFromContent() {
|
||||
_backHandledByKeyEvent = true;
|
||||
_navigateToAppBar();
|
||||
}
|
||||
|
||||
KeyEventResult _handleSortButtonKeyEvent(FocusNode _, KeyEvent event) {
|
||||
final key = event.logicalKey;
|
||||
|
||||
final backResult = handleBackKeyAction(event, () => Navigator.pop(context));
|
||||
if (backResult != KeyEventResult.ignored) return backResult;
|
||||
|
||||
if (event is! KeyDownEvent) return KeyEventResult.ignored;
|
||||
|
||||
if (key.isDownKey) {
|
||||
_focusGrid();
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
if (key.isSelectKey) {
|
||||
_showSortBottomSheet();
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
return KeyEventResult.ignored;
|
||||
}
|
||||
|
||||
Future<void> _loadSorts() async {
|
||||
@@ -152,9 +236,8 @@ class _HubDetailScreenState extends State<HubDetailScreen> with Refreshable {
|
||||
}
|
||||
|
||||
void _showSortBottomSheet() {
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
isScrollControlled: true,
|
||||
final overlayContext = _overlayChildKey.currentContext ?? context;
|
||||
OverlaySheetController.of(overlayContext).show(
|
||||
builder: (context) => SortBottomSheet(
|
||||
sortOptions: _sortOptions,
|
||||
selectedSort: _selectedSort,
|
||||
@@ -231,57 +314,127 @@ class _HubDetailScreenState extends State<HubDetailScreen> with Refreshable {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return FocusedScrollScaffold(
|
||||
title: Text(widget.hub.title),
|
||||
actions: [
|
||||
IconButton(
|
||||
icon: AppIcon(Symbols.swap_vert_rounded, fill: 1, semanticLabel: t.libraries.sort),
|
||||
onPressed: _showSortBottomSheet,
|
||||
),
|
||||
],
|
||||
slivers: [
|
||||
if (_errorMessage != null)
|
||||
SliverFillRemaining(
|
||||
child: ErrorStateWidget(
|
||||
message: _errorMessage!,
|
||||
icon: Symbols.error_outline_rounded,
|
||||
onRetry: _loadMoreItems,
|
||||
),
|
||||
)
|
||||
else if (_filteredItems.isEmpty && _isLoading)
|
||||
const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))
|
||||
else if (_filteredItems.isEmpty)
|
||||
SliverFillRemaining(child: Center(child: Text(t.hubDetail.noItemsFound)))
|
||||
else
|
||||
Builder(
|
||||
builder: (context) {
|
||||
final episodePosterMode = context.watch<SettingsProvider>().episodePosterMode;
|
||||
final isKeyboardMode = InputModeTracker.isKeyboardMode(context);
|
||||
final sortButtonFocused = isKeyboardMode && _isAppBarFocused;
|
||||
|
||||
// Determine hub content type for layout decisions
|
||||
final hasEpisodes = _filteredItems.any((item) => item.usesWideAspectRatio(episodePosterMode));
|
||||
final hasNonEpisodes = _filteredItems.any((item) => !item.usesWideAspectRatio(episodePosterMode));
|
||||
return PopScope(
|
||||
canPop: !isKeyboardMode || _isAppBarFocused,
|
||||
onPopInvokedWithResult: (didPop, _) {
|
||||
if (didPop || _backHandledByKeyEvent) {
|
||||
_backHandledByKeyEvent = false;
|
||||
return;
|
||||
}
|
||||
_navigateToAppBar();
|
||||
},
|
||||
child: OverlaySheetHost(
|
||||
child: Scaffold(
|
||||
key: _overlayChildKey,
|
||||
body: CustomScrollView(
|
||||
clipBehavior: Clip.none,
|
||||
slivers: [
|
||||
CustomAppBar(
|
||||
title: Text(widget.hub.title),
|
||||
pinned: true,
|
||||
actions: [
|
||||
Focus(
|
||||
focusNode: _sortButtonFocusNode,
|
||||
onKeyEvent: _handleSortButtonKeyEvent,
|
||||
child: Container(
|
||||
decoration: FocusTheme.focusBackgroundDecoration(isFocused: sortButtonFocused, borderRadius: 20),
|
||||
child: IconButton(
|
||||
icon: AppIcon(Symbols.swap_vert_rounded, fill: 1, semanticLabel: t.libraries.sort),
|
||||
onPressed: _showSortBottomSheet,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
if (_errorMessage != null)
|
||||
SliverFillRemaining(
|
||||
child: ErrorStateWidget(
|
||||
message: _errorMessage!,
|
||||
icon: Symbols.error_outline_rounded,
|
||||
onRetry: _loadMoreItems,
|
||||
),
|
||||
)
|
||||
else if (_filteredItems.isEmpty && _isLoading)
|
||||
const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))
|
||||
else if (_filteredItems.isEmpty)
|
||||
SliverFillRemaining(child: Center(child: Text(t.hubDetail.noItemsFound)))
|
||||
else
|
||||
Builder(
|
||||
builder: (context) {
|
||||
final settings = context.watch<SettingsProvider>();
|
||||
final episodePosterMode = settings.episodePosterMode;
|
||||
|
||||
// Mixed hub = has both episodes AND non-episodes
|
||||
final isMixedHub = hasEpisodes && hasNonEpisodes;
|
||||
// Determine hub content type for layout decisions
|
||||
final hasEpisodes = _filteredItems.any((item) => item.usesWideAspectRatio(episodePosterMode));
|
||||
final hasNonEpisodes = _filteredItems.any((item) => !item.usesWideAspectRatio(episodePosterMode));
|
||||
|
||||
// Episode-only = all items are episodes with thumbnails
|
||||
final isEpisodeOnlyHub = hasEpisodes && !hasNonEpisodes;
|
||||
// Mixed hub = has both episodes AND non-episodes
|
||||
final isMixedHub = hasEpisodes && hasNonEpisodes;
|
||||
|
||||
// Use 16:9 for episode-only hubs OR mixed hubs (with episode thumbnail mode)
|
||||
final useWideLayout =
|
||||
episodePosterMode == EpisodePosterMode.episodeThumbnail && (isEpisodeOnlyHub || isMixedHub);
|
||||
// Episode-only = all items are episodes with thumbnails
|
||||
final isEpisodeOnlyHub = hasEpisodes && !hasNonEpisodes;
|
||||
|
||||
return MediaGridSliver(
|
||||
items: _filteredItems,
|
||||
onRefresh: _handleItemRefresh,
|
||||
usePaddingAwareExtent: true,
|
||||
horizontalPadding: 16,
|
||||
useWideAspectRatio: useWideLayout,
|
||||
mixedHubContext: isMixedHub,
|
||||
);
|
||||
},
|
||||
// Use 16:9 for episode-only hubs OR mixed hubs (with episode thumbnail mode)
|
||||
final useWideLayout =
|
||||
episodePosterMode == EpisodePosterMode.episodeThumbnail && (isEpisodeOnlyHub || isMixedHub);
|
||||
|
||||
return SliverPadding(
|
||||
padding: const EdgeInsets.fromLTRB(8, 8, 8, 8),
|
||||
sliver: SliverLayoutBuilder(
|
||||
builder: (context, constraints) {
|
||||
final maxExtent = GridSizeCalculator.getMaxCrossAxisExtentWithPadding(
|
||||
context,
|
||||
settings.libraryDensity,
|
||||
16,
|
||||
);
|
||||
final columnCount = GridSizeCalculator.getColumnCount(
|
||||
constraints.crossAxisExtent,
|
||||
useWideLayout ? maxExtent * 1.8 : maxExtent,
|
||||
);
|
||||
|
||||
return SliverGrid(
|
||||
gridDelegate: MediaGridDelegate.createDelegate(
|
||||
context: context,
|
||||
density: settings.libraryDensity,
|
||||
usePaddingAware: true,
|
||||
horizontalPadding: 16,
|
||||
useWideAspectRatio: useWideLayout,
|
||||
),
|
||||
delegate: SliverChildBuilderDelegate(
|
||||
(context, index) {
|
||||
final item = _filteredItems[index];
|
||||
final focusNode = index == 0
|
||||
? _firstItemFocusNode
|
||||
: getGridItemFocusNode(index, prefix: 'hub_detail_item');
|
||||
final isFirstRow = GridSizeCalculator.isFirstRow(index, columnCount);
|
||||
final isFirstColumn = GridSizeCalculator.isFirstColumn(index, columnCount);
|
||||
|
||||
return FocusableMediaCard(
|
||||
focusNode: focusNode,
|
||||
item: item,
|
||||
onRefresh: _handleItemRefresh,
|
||||
onNavigateUp: isFirstRow ? _navigateToAppBar : null,
|
||||
onNavigateLeft: isFirstColumn ? () {} : null,
|
||||
onBack: _handleBackFromContent,
|
||||
onFocusChange: (hasFocus) => trackGridItemFocus(index, hasFocus),
|
||||
mixedHubContext: isMixedHub,
|
||||
);
|
||||
},
|
||||
childCount: _filteredItems.length,
|
||||
),
|
||||
);
|
||||
},
|
||||
),
|
||||
);
|
||||
},
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,8 +4,8 @@ import 'package:material_symbols_icons/symbols.dart';
|
||||
import '../../models/plex_filter.dart';
|
||||
import '../../widgets/app_bar_back_button.dart';
|
||||
import '../../widgets/bottom_sheet_header.dart';
|
||||
import '../../widgets/focusable_bottom_sheet.dart';
|
||||
import '../../widgets/focusable_list_tile.dart';
|
||||
import '../../widgets/overlay_sheet.dart';
|
||||
import '../../utils/provider_extensions.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
|
||||
@@ -101,7 +101,7 @@ class _FiltersBottomSheetState extends State<FiltersBottomSheet> {
|
||||
|
||||
void _applyFilters() {
|
||||
widget.onFiltersChanged(_tempSelectedFilters);
|
||||
Navigator.pop(context);
|
||||
OverlaySheetController.of(context).close();
|
||||
}
|
||||
|
||||
String _extractFilterValue(String key, String filterName) {
|
||||
@@ -118,164 +118,148 @@ class _FiltersBottomSheetState extends State<FiltersBottomSheet> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return FocusableBottomSheet(
|
||||
initialFocusNode: _initialFocusNode,
|
||||
child: DraggableScrollableSheet(
|
||||
initialChildSize: 0.7,
|
||||
minChildSize: 0.5,
|
||||
maxChildSize: 0.95,
|
||||
expand: false,
|
||||
builder: (context, scrollController) {
|
||||
if (_currentFilter != null) {
|
||||
// Show filter options view
|
||||
return Column(
|
||||
children: [
|
||||
// Header with back button
|
||||
BottomSheetHeader(
|
||||
title: _currentFilter!.title,
|
||||
leading: AppBarBackButton(style: BackButtonStyle.plain, onPressed: _goBack),
|
||||
),
|
||||
|
||||
// Filter options list
|
||||
if (_isLoadingValues)
|
||||
const Expanded(child: Center(child: CircularProgressIndicator()))
|
||||
else
|
||||
Expanded(
|
||||
child: ListView.builder(
|
||||
controller: scrollController,
|
||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
||||
itemCount: _filterValues.length + 1,
|
||||
itemBuilder: (context, index) {
|
||||
if (index == 0) {
|
||||
final isSelected = !_tempSelectedFilters.containsKey(_currentFilter!.filter);
|
||||
return FocusableListTile(
|
||||
focusNode: _initialFocusNode,
|
||||
title: Text(t.libraries.all),
|
||||
selected: isSelected,
|
||||
onTap: () {
|
||||
setState(() {
|
||||
_tempSelectedFilters.remove(_currentFilter!.filter);
|
||||
});
|
||||
_applyFilters();
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
final value = _filterValues[index - 1];
|
||||
final filterValue = _extractFilterValue(value.key, _currentFilter!.filter);
|
||||
final isSelected = _tempSelectedFilters[_currentFilter!.filter] == filterValue;
|
||||
|
||||
return FocusableListTile(
|
||||
title: Text(value.title),
|
||||
selected: isSelected,
|
||||
onTap: () {
|
||||
setState(() {
|
||||
_tempSelectedFilters[_currentFilter!.filter] = filterValue;
|
||||
// Cache the display name for this filter value
|
||||
if (_filterDisplayNames.length > _maxCachedDisplayNames) {
|
||||
_filterDisplayNames.clear();
|
||||
}
|
||||
_filterDisplayNames[_cacheKey(_currentFilter!.filter, filterValue)] = value.title;
|
||||
});
|
||||
_applyFilters();
|
||||
},
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
// Show main filters view
|
||||
return Column(
|
||||
children: [
|
||||
// Header
|
||||
BottomSheetHeader(
|
||||
title: t.libraries.filters,
|
||||
leading: const AppIcon(Symbols.filter_alt_rounded, fill: 1),
|
||||
action: _tempSelectedFilters.isNotEmpty
|
||||
? TextButton.icon(
|
||||
onPressed: () {
|
||||
setState(() {
|
||||
_tempSelectedFilters.clear();
|
||||
});
|
||||
_applyFilters();
|
||||
},
|
||||
icon: const AppIcon(Symbols.clear_all_rounded, fill: 1),
|
||||
label: Text(t.libraries.clearAll),
|
||||
)
|
||||
: null,
|
||||
),
|
||||
|
||||
// All Filters (boolean toggles first, then regular filters)
|
||||
Expanded(
|
||||
child: ListView.builder(
|
||||
controller: scrollController,
|
||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
||||
itemCount: _sortedFilters.length,
|
||||
itemBuilder: (context, index) {
|
||||
final filter = _sortedFilters[index];
|
||||
|
||||
// Handle boolean filters as switches (unwatched, inProgress, unmatched, hdr, etc.)
|
||||
if (_isBooleanFilter(filter)) {
|
||||
final isActive =
|
||||
_tempSelectedFilters.containsKey(filter.filter) && _tempSelectedFilters[filter.filter] == '1';
|
||||
return FocusableSwitchListTile(
|
||||
focusNode: index == 0 ? _initialFocusNode : null,
|
||||
value: isActive,
|
||||
onChanged: (value) {
|
||||
setState(() {
|
||||
if (value) {
|
||||
_tempSelectedFilters[filter.filter] = '1';
|
||||
} else {
|
||||
_tempSelectedFilters.remove(filter.filter);
|
||||
}
|
||||
});
|
||||
_applyFilters();
|
||||
},
|
||||
title: Text(filter.title),
|
||||
);
|
||||
}
|
||||
|
||||
// Regular navigable filters - show selected value instead of checkmark
|
||||
final selectedValue = _tempSelectedFilters[filter.filter];
|
||||
String? displayValue;
|
||||
if (selectedValue != null) {
|
||||
// Try to get the cached display name, fall back to the value itself
|
||||
displayValue = _filterDisplayNames[_cacheKey(filter.filter, selectedValue)] ?? selectedValue;
|
||||
}
|
||||
if (_currentFilter != null) {
|
||||
// Show filter options view
|
||||
return Column(
|
||||
children: [
|
||||
// Header with back button
|
||||
BottomSheetHeader(
|
||||
title: _currentFilter!.title,
|
||||
leading: AppBarBackButton(style: BackButtonStyle.plain, onPressed: _goBack),
|
||||
),
|
||||
|
||||
// Filter options list
|
||||
if (_isLoadingValues)
|
||||
const Expanded(child: Center(child: CircularProgressIndicator()))
|
||||
else
|
||||
Expanded(
|
||||
child: ListView.builder(
|
||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
||||
itemCount: _filterValues.length + 1,
|
||||
itemBuilder: (context, index) {
|
||||
if (index == 0) {
|
||||
final isSelected = !_tempSelectedFilters.containsKey(_currentFilter!.filter);
|
||||
return FocusableListTile(
|
||||
focusNode: index == 0 ? _initialFocusNode : null,
|
||||
title: Text(filter.title),
|
||||
trailing: Row(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
if (displayValue != null)
|
||||
Flexible(
|
||||
child: Text(
|
||||
displayValue,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.primary,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
overflow: TextOverflow.ellipsis,
|
||||
),
|
||||
),
|
||||
if (displayValue != null) const SizedBox(width: 8),
|
||||
const AppIcon(Symbols.chevron_right_rounded, fill: 1),
|
||||
],
|
||||
),
|
||||
onTap: () => _loadFilterValues(filter),
|
||||
focusNode: _initialFocusNode,
|
||||
title: Text(t.libraries.all),
|
||||
selected: isSelected,
|
||||
onTap: () {
|
||||
setState(() {
|
||||
_tempSelectedFilters.remove(_currentFilter!.filter);
|
||||
});
|
||||
_applyFilters();
|
||||
},
|
||||
);
|
||||
},
|
||||
),
|
||||
}
|
||||
|
||||
final value = _filterValues[index - 1];
|
||||
final filterValue = _extractFilterValue(value.key, _currentFilter!.filter);
|
||||
final isSelected = _tempSelectedFilters[_currentFilter!.filter] == filterValue;
|
||||
|
||||
return FocusableListTile(
|
||||
title: Text(value.title),
|
||||
selected: isSelected,
|
||||
onTap: () {
|
||||
setState(() {
|
||||
_tempSelectedFilters[_currentFilter!.filter] = filterValue;
|
||||
// Cache the display name for this filter value
|
||||
if (_filterDisplayNames.length > _maxCachedDisplayNames) {
|
||||
_filterDisplayNames.clear();
|
||||
}
|
||||
_filterDisplayNames[_cacheKey(_currentFilter!.filter, filterValue)] = value.title;
|
||||
});
|
||||
_applyFilters();
|
||||
},
|
||||
);
|
||||
},
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
// Show main filters view
|
||||
return Column(
|
||||
children: [
|
||||
// Header
|
||||
BottomSheetHeader(
|
||||
title: t.libraries.filters,
|
||||
leading: const AppIcon(Symbols.filter_alt_rounded, fill: 1),
|
||||
action: _tempSelectedFilters.isNotEmpty
|
||||
? TextButton.icon(
|
||||
onPressed: () {
|
||||
setState(() {
|
||||
_tempSelectedFilters.clear();
|
||||
});
|
||||
_applyFilters();
|
||||
},
|
||||
icon: const AppIcon(Symbols.clear_all_rounded, fill: 1),
|
||||
label: Text(t.libraries.clearAll),
|
||||
)
|
||||
: null,
|
||||
),
|
||||
|
||||
// All Filters (boolean toggles first, then regular filters)
|
||||
Expanded(
|
||||
child: ListView.builder(
|
||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
||||
itemCount: _sortedFilters.length,
|
||||
itemBuilder: (context, index) {
|
||||
final filter = _sortedFilters[index];
|
||||
|
||||
// Handle boolean filters as switches (unwatched, inProgress, unmatched, hdr, etc.)
|
||||
if (_isBooleanFilter(filter)) {
|
||||
final isActive =
|
||||
_tempSelectedFilters.containsKey(filter.filter) && _tempSelectedFilters[filter.filter] == '1';
|
||||
return FocusableSwitchListTile(
|
||||
focusNode: index == 0 ? _initialFocusNode : null,
|
||||
value: isActive,
|
||||
onChanged: (value) {
|
||||
setState(() {
|
||||
if (value) {
|
||||
_tempSelectedFilters[filter.filter] = '1';
|
||||
} else {
|
||||
_tempSelectedFilters.remove(filter.filter);
|
||||
}
|
||||
});
|
||||
_applyFilters();
|
||||
},
|
||||
title: Text(filter.title),
|
||||
);
|
||||
}
|
||||
|
||||
// Regular navigable filters - show selected value instead of checkmark
|
||||
final selectedValue = _tempSelectedFilters[filter.filter];
|
||||
String? displayValue;
|
||||
if (selectedValue != null) {
|
||||
// Try to get the cached display name, fall back to the value itself
|
||||
displayValue = _filterDisplayNames[_cacheKey(filter.filter, selectedValue)] ?? selectedValue;
|
||||
}
|
||||
|
||||
return FocusableListTile(
|
||||
focusNode: index == 0 ? _initialFocusNode : null,
|
||||
title: Text(filter.title),
|
||||
trailing: Row(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
if (displayValue != null)
|
||||
Flexible(
|
||||
child: Text(
|
||||
displayValue,
|
||||
style: TextStyle(color: Theme.of(context).colorScheme.primary, fontWeight: FontWeight.w500),
|
||||
overflow: TextOverflow.ellipsis,
|
||||
),
|
||||
),
|
||||
if (displayValue != null) const SizedBox(width: 8),
|
||||
const AppIcon(Symbols.chevron_right_rounded, fill: 1),
|
||||
],
|
||||
),
|
||||
onTap: () => _loadFilterValues(filter),
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,10 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:plezy/widgets/app_icon.dart';
|
||||
import 'package:material_symbols_icons/symbols.dart';
|
||||
import '../../focus/focusable_button.dart';
|
||||
import '../../focus/focusable_wrapper.dart';
|
||||
import '../../models/plex_metadata.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
|
||||
/// Individual item in the folder tree
|
||||
/// Can be either a folder (expandable) or a file (tappable)
|
||||
@@ -12,7 +15,11 @@ class FolderTreeItem extends StatelessWidget {
|
||||
final bool isFolder;
|
||||
final VoidCallback? onTap;
|
||||
final VoidCallback? onExpand;
|
||||
final VoidCallback? onPlayAll;
|
||||
final VoidCallback? onShuffle;
|
||||
final bool isLoading;
|
||||
final FocusNode? focusNode;
|
||||
final VoidCallback? onNavigateUp;
|
||||
|
||||
const FolderTreeItem({
|
||||
super.key,
|
||||
@@ -22,7 +29,11 @@ class FolderTreeItem extends StatelessWidget {
|
||||
this.isFolder = false,
|
||||
this.onTap,
|
||||
this.onExpand,
|
||||
this.onPlayAll,
|
||||
this.onShuffle,
|
||||
this.isLoading = false,
|
||||
this.focusNode,
|
||||
this.onNavigateUp,
|
||||
});
|
||||
|
||||
IconData _getIcon() {
|
||||
@@ -61,56 +72,110 @@ class FolderTreeItem extends StatelessWidget {
|
||||
final indentation = depth * 24.0;
|
||||
final expandIcon = isExpanded ? Symbols.keyboard_arrow_down_rounded : Symbols.keyboard_arrow_right_rounded;
|
||||
|
||||
return InkWell(
|
||||
onTap: _handleTap,
|
||||
child: Container(
|
||||
padding: EdgeInsets.only(left: 16.0 + indentation, right: 16.0, top: 12.0, bottom: 12.0),
|
||||
child: Row(
|
||||
children: [
|
||||
// Expand/collapse icon for folders
|
||||
if (isFolder)
|
||||
SizedBox(
|
||||
width: 24,
|
||||
child: isLoading
|
||||
? const SizedBox(width: 16, height: 16, child: CircularProgressIndicator(strokeWidth: 2))
|
||||
: AppIcon(expandIcon, fill: 1, size: 20),
|
||||
)
|
||||
else
|
||||
const SizedBox(width: 24),
|
||||
final rowContent = Container(
|
||||
padding: EdgeInsets.only(left: 16.0 + indentation, right: 8.0, top: 8.0, bottom: 8.0),
|
||||
child: Row(
|
||||
children: [
|
||||
// Expand/collapse icon for folders
|
||||
if (isFolder)
|
||||
SizedBox(
|
||||
width: 24,
|
||||
child: isLoading
|
||||
? const SizedBox(width: 16, height: 16, child: CircularProgressIndicator(strokeWidth: 2))
|
||||
: AppIcon(expandIcon, fill: 1, size: 20),
|
||||
)
|
||||
else
|
||||
const SizedBox(width: 24),
|
||||
|
||||
const SizedBox(width: 8),
|
||||
const SizedBox(width: 8),
|
||||
|
||||
// File/folder icon
|
||||
AppIcon(
|
||||
_getIcon(),
|
||||
fill: 1,
|
||||
size: 20,
|
||||
color: isFolder
|
||||
? Theme.of(context).colorScheme.primary
|
||||
: Theme.of(context).colorScheme.onSurface.withValues(alpha: 0.7),
|
||||
// File/folder icon
|
||||
AppIcon(
|
||||
_getIcon(),
|
||||
fill: 1,
|
||||
size: 20,
|
||||
color: isFolder
|
||||
? Theme.of(context).colorScheme.primary
|
||||
: Theme.of(context).colorScheme.onSurface.withValues(alpha: 0.7),
|
||||
),
|
||||
|
||||
const SizedBox(width: 12),
|
||||
|
||||
// Item title
|
||||
Expanded(
|
||||
child: Text(
|
||||
item.title,
|
||||
style: TextStyle(fontSize: 14, fontWeight: isFolder ? FontWeight.w500 : FontWeight.w400),
|
||||
maxLines: 1,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
),
|
||||
),
|
||||
|
||||
const SizedBox(width: 12),
|
||||
|
||||
// Item title
|
||||
Expanded(
|
||||
child: Text(
|
||||
item.title,
|
||||
style: TextStyle(fontSize: 14, fontWeight: isFolder ? FontWeight.w500 : FontWeight.w400),
|
||||
maxLines: 1,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
),
|
||||
// Additional metadata for files
|
||||
if (!isFolder && item.year != null)
|
||||
Text(
|
||||
item.year.toString(),
|
||||
style: TextStyle(fontSize: 12, color: Theme.of(context).colorScheme.onSurface.withValues(alpha: 0.6)),
|
||||
),
|
||||
|
||||
// Additional metadata for files
|
||||
if (!isFolder && item.year != null)
|
||||
Text(
|
||||
item.year.toString(),
|
||||
style: TextStyle(fontSize: 12, color: Theme.of(context).colorScheme.onSurface.withValues(alpha: 0.6)),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
return Row(
|
||||
children: [
|
||||
// Main item row — expand/navigate on select
|
||||
Expanded(
|
||||
child: FocusableWrapper(
|
||||
focusNode: focusNode,
|
||||
onSelect: _handleTap,
|
||||
onNavigateUp: onNavigateUp,
|
||||
useBackgroundFocus: true,
|
||||
disableScale: true,
|
||||
descendantsAreFocusable: false,
|
||||
child: rowContent,
|
||||
),
|
||||
),
|
||||
|
||||
// Play/Shuffle buttons for folders
|
||||
if (isFolder) ...[
|
||||
FocusableButton(
|
||||
useBackgroundFocus: true,
|
||||
onPressed: onPlayAll,
|
||||
child: IconButton(
|
||||
onPressed: onPlayAll,
|
||||
icon: AppIcon(
|
||||
Symbols.play_arrow_rounded,
|
||||
fill: 1,
|
||||
size: 18,
|
||||
color: Theme.of(context).colorScheme.onSurface.withValues(alpha: 0.6),
|
||||
),
|
||||
tooltip: t.common.play,
|
||||
iconSize: 18,
|
||||
constraints: const BoxConstraints(minWidth: 36, minHeight: 36),
|
||||
padding: EdgeInsets.zero,
|
||||
visualDensity: VisualDensity.compact,
|
||||
),
|
||||
),
|
||||
FocusableButton(
|
||||
useBackgroundFocus: true,
|
||||
onPressed: onShuffle,
|
||||
child: IconButton(
|
||||
onPressed: onShuffle,
|
||||
icon: AppIcon(
|
||||
Symbols.shuffle_rounded,
|
||||
fill: 1,
|
||||
size: 18,
|
||||
color: Theme.of(context).colorScheme.onSurface.withValues(alpha: 0.6),
|
||||
),
|
||||
tooltip: t.common.shuffle,
|
||||
iconSize: 18,
|
||||
constraints: const BoxConstraints(minWidth: 36, minHeight: 36),
|
||||
padding: EdgeInsets.zero,
|
||||
visualDensity: VisualDensity.compact,
|
||||
),
|
||||
),
|
||||
],
|
||||
],
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:material_symbols_icons/symbols.dart';
|
||||
import '../../models/plex_metadata.dart';
|
||||
import '../../services/play_queue_launcher.dart';
|
||||
import '../../utils/app_logger.dart';
|
||||
import '../../utils/media_navigation_helper.dart';
|
||||
import '../../utils/provider_extensions.dart';
|
||||
@@ -15,8 +16,17 @@ class FolderTreeView extends StatefulWidget {
|
||||
final String libraryKey;
|
||||
final String? serverId; // Server this library belongs to
|
||||
final void Function(String)? onRefresh;
|
||||
final FocusNode? firstItemFocusNode;
|
||||
final VoidCallback? onNavigateUp;
|
||||
|
||||
const FolderTreeView({super.key, required this.libraryKey, this.serverId, this.onRefresh});
|
||||
const FolderTreeView({
|
||||
super.key,
|
||||
required this.libraryKey,
|
||||
this.serverId,
|
||||
this.onRefresh,
|
||||
this.firstItemFocusNode,
|
||||
this.onNavigateUp,
|
||||
});
|
||||
|
||||
@override
|
||||
State<FolderTreeView> createState() => _FolderTreeViewState();
|
||||
@@ -134,6 +144,18 @@ class _FolderTreeViewState extends State<FolderTreeView> {
|
||||
await navigateToMediaItem(context, item, onRefresh: widget.onRefresh);
|
||||
}
|
||||
|
||||
Future<void> _handleFolderPlay(PlexMetadata folder) async {
|
||||
final client = context.getClientForServer(widget.serverId!);
|
||||
final launcher = PlayQueueLauncher(context: context, client: client, serverId: widget.serverId);
|
||||
await launcher.launchFromFolder(folderKey: folder.key, shuffle: false);
|
||||
}
|
||||
|
||||
Future<void> _handleFolderShuffle(PlexMetadata folder) async {
|
||||
final client = context.getClientForServer(widget.serverId!);
|
||||
final launcher = PlayQueueLauncher(context: context, client: client, serverId: widget.serverId);
|
||||
await launcher.launchFromFolder(folderKey: folder.key, shuffle: true);
|
||||
}
|
||||
|
||||
bool _isFolder(PlexMetadata item) {
|
||||
// Folders typically don't have a specific type or might have special indicators
|
||||
// Check for common folder indicators
|
||||
@@ -152,6 +174,9 @@ class _FolderTreeViewState extends State<FolderTreeView> {
|
||||
// Create a unique key path that includes parent hierarchy and index
|
||||
final itemPath = parentPath.isEmpty ? '$i' : '$parentPath-$i';
|
||||
|
||||
// First root item gets the external focus node and navigate-up callback
|
||||
final isFirstRootItem = depth == 0 && i == 0;
|
||||
|
||||
// Add the item itself
|
||||
widgets.add(
|
||||
FolderTreeItem(
|
||||
@@ -163,6 +188,10 @@ class _FolderTreeViewState extends State<FolderTreeView> {
|
||||
isLoading: isLoading,
|
||||
onExpand: isFolder ? () => _toggleFolder(item) : null,
|
||||
onTap: !isFolder ? () => _handleItemTap(item) : null,
|
||||
onPlayAll: isFolder ? () => _handleFolderPlay(item) : null,
|
||||
onShuffle: isFolder ? () => _handleFolderShuffle(item) : null,
|
||||
focusNode: isFirstRootItem ? widget.firstItemFocusNode : null,
|
||||
onNavigateUp: isFirstRootItem ? widget.onNavigateUp : null,
|
||||
),
|
||||
);
|
||||
|
||||
@@ -197,7 +226,10 @@ class _FolderTreeViewState extends State<FolderTreeView> {
|
||||
|
||||
return RefreshIndicator(
|
||||
onRefresh: _loadRootFolders,
|
||||
child: ListView(children: _buildTreeItems(_rootFolders, 0)),
|
||||
child: ListView(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 8),
|
||||
children: _buildTreeItems(_rootFolders, 0),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@ import 'package:material_symbols_icons/symbols.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:dio/dio.dart';
|
||||
import '../../focus/focusable_button.dart';
|
||||
import '../../focus/dpad_navigator.dart';
|
||||
import '../../focus/focus_theme.dart';
|
||||
import '../../focus/input_mode_tracker.dart';
|
||||
@@ -23,6 +24,7 @@ import '../../utils/snackbar_helper.dart';
|
||||
import '../../utils/content_utils.dart';
|
||||
import '../../widgets/desktop_app_bar.dart';
|
||||
import '../../widgets/focusable_tab_chip.dart';
|
||||
import '../../widgets/overlay_sheet.dart';
|
||||
import '../../services/storage_service.dart';
|
||||
import '../../mixins/refreshable.dart';
|
||||
import '../../mixins/item_updatable.dart';
|
||||
@@ -786,9 +788,7 @@ class _LibrariesScreenState extends State<LibrariesScreen>
|
||||
),
|
||||
);
|
||||
} else {
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
isScrollControlled: true,
|
||||
OverlaySheetController.of(context).show(
|
||||
builder: (context) => _LibraryManagementSheet(
|
||||
allLibraries: List.from(allLibraries),
|
||||
hiddenLibraryKeys: hiddenLibrariesProvider.hiddenLibraryKeys,
|
||||
@@ -1066,140 +1066,142 @@ class _LibrariesScreenState extends State<LibrariesScreen>
|
||||
// Compute visible libraries (filtered from all libraries)
|
||||
final visibleLibraries = allLibraries.where((lib) => !hiddenKeys.contains(lib.globalKey)).toList();
|
||||
|
||||
return Scaffold(
|
||||
body: ScrollConfiguration(
|
||||
behavior: ScrollConfiguration.of(context).copyWith(scrollbars: false),
|
||||
child: CustomScrollView(
|
||||
controller: _outerScrollController,
|
||||
slivers: [
|
||||
DesktopSliverAppBar(
|
||||
title: _buildAppBarTitle(visibleLibraries),
|
||||
pinned: true,
|
||||
backgroundColor: Theme.of(context).scaffoldBackgroundColor,
|
||||
surfaceTintColor: Colors.transparent,
|
||||
shadowColor: Colors.transparent,
|
||||
scrolledUnderElevation: 0,
|
||||
actions: [
|
||||
if (allLibraries.isNotEmpty)
|
||||
return OverlaySheetHost(
|
||||
child: Scaffold(
|
||||
body: ScrollConfiguration(
|
||||
behavior: ScrollConfiguration.of(context).copyWith(scrollbars: false),
|
||||
child: CustomScrollView(
|
||||
controller: _outerScrollController,
|
||||
slivers: [
|
||||
DesktopSliverAppBar(
|
||||
title: _buildAppBarTitle(visibleLibraries),
|
||||
pinned: true,
|
||||
backgroundColor: Theme.of(context).scaffoldBackgroundColor,
|
||||
surfaceTintColor: Colors.transparent,
|
||||
shadowColor: Colors.transparent,
|
||||
scrolledUnderElevation: 0,
|
||||
actions: [
|
||||
if (allLibraries.isNotEmpty)
|
||||
Focus(
|
||||
focusNode: _editButtonFocusNode,
|
||||
onKeyEvent: _handleEditKeyEvent,
|
||||
child: Container(
|
||||
decoration: BoxDecoration(
|
||||
color: _isEditFocused ? Colors.white.withValues(alpha: 0.2) : Colors.transparent,
|
||||
borderRadius: const BorderRadius.all(Radius.circular(20)),
|
||||
),
|
||||
child: IconButton(
|
||||
icon: const AppIcon(Symbols.edit_rounded, fill: 1),
|
||||
tooltip: t.libraries.manageLibraries,
|
||||
onPressed: _showLibraryManagementSheet,
|
||||
),
|
||||
),
|
||||
),
|
||||
Focus(
|
||||
focusNode: _editButtonFocusNode,
|
||||
onKeyEvent: _handleEditKeyEvent,
|
||||
focusNode: _refreshButtonFocusNode,
|
||||
onKeyEvent: _handleRefreshKeyEvent,
|
||||
child: Container(
|
||||
decoration: BoxDecoration(
|
||||
color: _isEditFocused ? Colors.white.withValues(alpha: 0.2) : Colors.transparent,
|
||||
color: _isRefreshFocused ? Colors.white.withValues(alpha: 0.2) : Colors.transparent,
|
||||
borderRadius: const BorderRadius.all(Radius.circular(20)),
|
||||
),
|
||||
child: IconButton(
|
||||
icon: const AppIcon(Symbols.edit_rounded, fill: 1),
|
||||
tooltip: t.libraries.manageLibraries,
|
||||
onPressed: _showLibraryManagementSheet,
|
||||
icon: const AppIcon(Symbols.refresh_rounded, fill: 1),
|
||||
tooltip: t.common.refresh,
|
||||
onPressed: _refreshCurrentTab,
|
||||
),
|
||||
),
|
||||
),
|
||||
Focus(
|
||||
focusNode: _refreshButtonFocusNode,
|
||||
onKeyEvent: _handleRefreshKeyEvent,
|
||||
child: Container(
|
||||
decoration: BoxDecoration(
|
||||
color: _isRefreshFocused ? Colors.white.withValues(alpha: 0.2) : Colors.transparent,
|
||||
borderRadius: const BorderRadius.all(Radius.circular(20)),
|
||||
),
|
||||
child: IconButton(
|
||||
icon: const AppIcon(Symbols.refresh_rounded, fill: 1),
|
||||
tooltip: t.common.refresh,
|
||||
onPressed: _refreshCurrentTab,
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
if (isLoadingLibraries)
|
||||
const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))
|
||||
else if (_errorMessage != null && visibleLibraries.isEmpty)
|
||||
SliverFillRemaining(
|
||||
child: ErrorStateWidget(
|
||||
message: _errorMessage!,
|
||||
icon: Symbols.error_outline_rounded,
|
||||
onRetry: () {
|
||||
final librariesProvider = context.read<LibrariesProvider>();
|
||||
librariesProvider.refresh();
|
||||
},
|
||||
),
|
||||
)
|
||||
else if (visibleLibraries.isEmpty)
|
||||
SliverFillRemaining(
|
||||
child: EmptyStateWidget(message: t.libraries.noLibrariesFound, icon: Symbols.video_library_rounded),
|
||||
)
|
||||
else ...[
|
||||
// Tab selector chips (only on mobile - desktop has them in app bar)
|
||||
if (_selectedLibraryGlobalKey != null && !PlatformDetector.shouldUseSideNavigation(context))
|
||||
SliverToBoxAdapter(
|
||||
child: Container(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 8),
|
||||
child: SingleChildScrollView(
|
||||
scrollDirection: Axis.horizontal,
|
||||
child: Row(
|
||||
children: [
|
||||
_buildTabChip(t.libraries.tabs.recommended, 0),
|
||||
const SizedBox(width: 8),
|
||||
_buildTabChip(t.libraries.tabs.browse, 1),
|
||||
const SizedBox(width: 8),
|
||||
_buildTabChip(t.libraries.tabs.collections, 2),
|
||||
const SizedBox(width: 8),
|
||||
_buildTabChip(t.libraries.tabs.playlists, 3),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
// Tab content
|
||||
if (_selectedLibraryGlobalKey != null)
|
||||
],
|
||||
),
|
||||
if (isLoadingLibraries)
|
||||
const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))
|
||||
else if (_errorMessage != null && visibleLibraries.isEmpty)
|
||||
SliverFillRemaining(
|
||||
child: TabBarView(
|
||||
key: ValueKey(_selectedLibraryGlobalKey),
|
||||
controller: tabController,
|
||||
// Disable swipe on desktop - trackpad scrolling triggers accidental tab switches
|
||||
// See: https://github.com/flutter/flutter/issues/11132
|
||||
physics: PlatformDetector.isDesktop(context) ? const NeverScrollableScrollPhysics() : null,
|
||||
children: [
|
||||
LibraryRecommendedTab(
|
||||
key: _recommendedTabKey,
|
||||
library: allLibraries.firstWhere((lib) => lib.globalKey == _selectedLibraryGlobalKey),
|
||||
isActive: tabController.index == 0,
|
||||
suppressAutoFocus: suppressAutoFocus,
|
||||
onDataLoaded: () => _handleTabDataLoaded(0),
|
||||
onBack: focusTabBar,
|
||||
),
|
||||
LibraryBrowseTab(
|
||||
key: _browseTabKey,
|
||||
library: allLibraries.firstWhere((lib) => lib.globalKey == _selectedLibraryGlobalKey),
|
||||
isActive: tabController.index == 1,
|
||||
suppressAutoFocus: suppressAutoFocus,
|
||||
onDataLoaded: () => _handleTabDataLoaded(1),
|
||||
onBack: focusTabBar,
|
||||
),
|
||||
LibraryCollectionsTab(
|
||||
key: _collectionsTabKey,
|
||||
library: allLibraries.firstWhere((lib) => lib.globalKey == _selectedLibraryGlobalKey),
|
||||
isActive: tabController.index == 2,
|
||||
suppressAutoFocus: suppressAutoFocus,
|
||||
onDataLoaded: () => _handleTabDataLoaded(2),
|
||||
onBack: focusTabBar,
|
||||
),
|
||||
LibraryPlaylistsTab(
|
||||
key: _playlistsTabKey,
|
||||
library: allLibraries.firstWhere((lib) => lib.globalKey == _selectedLibraryGlobalKey),
|
||||
isActive: tabController.index == 3,
|
||||
suppressAutoFocus: suppressAutoFocus,
|
||||
onDataLoaded: () => _handleTabDataLoaded(3),
|
||||
onBack: focusTabBar,
|
||||
),
|
||||
],
|
||||
child: ErrorStateWidget(
|
||||
message: _errorMessage!,
|
||||
icon: Symbols.error_outline_rounded,
|
||||
onRetry: () {
|
||||
final librariesProvider = context.read<LibrariesProvider>();
|
||||
librariesProvider.refresh();
|
||||
},
|
||||
),
|
||||
),
|
||||
)
|
||||
else if (visibleLibraries.isEmpty)
|
||||
SliverFillRemaining(
|
||||
child: EmptyStateWidget(message: t.libraries.noLibrariesFound, icon: Symbols.video_library_rounded),
|
||||
)
|
||||
else ...[
|
||||
// Tab selector chips (only on mobile - desktop has them in app bar)
|
||||
if (_selectedLibraryGlobalKey != null && !PlatformDetector.shouldUseSideNavigation(context))
|
||||
SliverToBoxAdapter(
|
||||
child: Container(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 16, vertical: 8),
|
||||
child: SingleChildScrollView(
|
||||
scrollDirection: Axis.horizontal,
|
||||
child: Row(
|
||||
children: [
|
||||
_buildTabChip(t.libraries.tabs.recommended, 0),
|
||||
const SizedBox(width: 8),
|
||||
_buildTabChip(t.libraries.tabs.browse, 1),
|
||||
const SizedBox(width: 8),
|
||||
_buildTabChip(t.libraries.tabs.collections, 2),
|
||||
const SizedBox(width: 8),
|
||||
_buildTabChip(t.libraries.tabs.playlists, 3),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
),
|
||||
|
||||
// Tab content
|
||||
if (_selectedLibraryGlobalKey != null)
|
||||
SliverFillRemaining(
|
||||
child: TabBarView(
|
||||
key: ValueKey(_selectedLibraryGlobalKey),
|
||||
controller: tabController,
|
||||
// Disable swipe on desktop - trackpad scrolling triggers accidental tab switches
|
||||
// See: https://github.com/flutter/flutter/issues/11132
|
||||
physics: PlatformDetector.isDesktop(context) ? const NeverScrollableScrollPhysics() : null,
|
||||
children: [
|
||||
LibraryRecommendedTab(
|
||||
key: _recommendedTabKey,
|
||||
library: allLibraries.firstWhere((lib) => lib.globalKey == _selectedLibraryGlobalKey),
|
||||
isActive: tabController.index == 0,
|
||||
suppressAutoFocus: suppressAutoFocus,
|
||||
onDataLoaded: () => _handleTabDataLoaded(0),
|
||||
onBack: focusTabBar,
|
||||
),
|
||||
LibraryBrowseTab(
|
||||
key: _browseTabKey,
|
||||
library: allLibraries.firstWhere((lib) => lib.globalKey == _selectedLibraryGlobalKey),
|
||||
isActive: tabController.index == 1,
|
||||
suppressAutoFocus: suppressAutoFocus,
|
||||
onDataLoaded: () => _handleTabDataLoaded(1),
|
||||
onBack: focusTabBar,
|
||||
),
|
||||
LibraryCollectionsTab(
|
||||
key: _collectionsTabKey,
|
||||
library: allLibraries.firstWhere((lib) => lib.globalKey == _selectedLibraryGlobalKey),
|
||||
isActive: tabController.index == 2,
|
||||
suppressAutoFocus: suppressAutoFocus,
|
||||
onDataLoaded: () => _handleTabDataLoaded(2),
|
||||
onBack: focusTabBar,
|
||||
),
|
||||
LibraryPlaylistsTab(
|
||||
key: _playlistsTabKey,
|
||||
library: allLibraries.firstWhere((lib) => lib.globalKey == _selectedLibraryGlobalKey),
|
||||
isActive: tabController.index == 3,
|
||||
suppressAutoFocus: suppressAutoFocus,
|
||||
onDataLoaded: () => _handleTabDataLoaded(3),
|
||||
onBack: focusTabBar,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
],
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
@@ -1420,27 +1422,52 @@ class _LibraryManagementSheetState extends State<_LibraryManagementSheet> {
|
||||
|
||||
Future<void> _showLibraryMenuBottomSheet(BuildContext outerContext, PlexLibrary library) async {
|
||||
final menuItems = widget.getLibraryMenuItems(library);
|
||||
final selected = await showModalBottomSheet<String>(
|
||||
context: outerContext,
|
||||
builder: (context) => SafeArea(
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: Text(library.title, style: const TextStyle(fontSize: 16, fontWeight: FontWeight.w600)),
|
||||
),
|
||||
...menuItems.indexed.map(
|
||||
(entry) => ListTile(
|
||||
leading: AppIcon(entry.$2.icon, fill: 1),
|
||||
title: Text(entry.$2.label),
|
||||
onTap: () => Navigator.pop(context, entry.$2.value),
|
||||
final controller = OverlaySheetController.maybeOf(outerContext);
|
||||
final String? selected;
|
||||
if (controller != null) {
|
||||
selected = await controller.push<String>(
|
||||
builder: (context) => SafeArea(
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: Text(library.title, style: const TextStyle(fontSize: 16, fontWeight: FontWeight.w600)),
|
||||
),
|
||||
),
|
||||
],
|
||||
...menuItems.indexed.map(
|
||||
(entry) => ListTile(
|
||||
leading: AppIcon(entry.$2.icon, fill: 1),
|
||||
title: Text(entry.$2.label),
|
||||
onTap: () => controller.pop(entry.$2.value),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
);
|
||||
} else {
|
||||
selected = await showModalBottomSheet<String>(
|
||||
context: outerContext,
|
||||
builder: (context) => SafeArea(
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: Text(library.title, style: const TextStyle(fontSize: 16, fontWeight: FontWeight.w600)),
|
||||
),
|
||||
...menuItems.indexed.map(
|
||||
(entry) => ListTile(
|
||||
leading: AppIcon(entry.$2.icon, fill: 1),
|
||||
title: Text(entry.$2.label),
|
||||
onTap: () => Navigator.pop(context, entry.$2.value),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
if (selected != null && mounted) {
|
||||
// Find the selected item to check if confirmation is needed
|
||||
@@ -1454,11 +1481,21 @@ class _LibraryManagementSheetState extends State<_LibraryManagementSheet> {
|
||||
title: Text(selectedItem.confirmationTitle ?? t.dialog.confirmAction),
|
||||
content: Text(selectedItem.confirmationMessage ?? t.libraries.confirmActionMessage),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(context, false), child: Text(t.common.cancel)),
|
||||
TextButton(
|
||||
FocusableButton(
|
||||
autofocus: true,
|
||||
onPressed: () => Navigator.pop(context, false),
|
||||
child: TextButton(
|
||||
onPressed: () => Navigator.pop(context, false),
|
||||
child: Text(t.common.cancel),
|
||||
),
|
||||
),
|
||||
FocusableButton(
|
||||
onPressed: () => Navigator.pop(context, true),
|
||||
style: selectedItem.isDestructive ? TextButton.styleFrom(foregroundColor: Colors.red) : null,
|
||||
child: Text(t.common.confirm),
|
||||
child: TextButton(
|
||||
onPressed: () => Navigator.pop(context, true),
|
||||
style: selectedItem.isDestructive ? TextButton.styleFrom(foregroundColor: Colors.red) : null,
|
||||
child: Text(t.common.confirm),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
|
||||
@@ -4,8 +4,8 @@ import 'package:material_symbols_icons/symbols.dart';
|
||||
import '../../focus/dpad_navigator.dart';
|
||||
import '../../models/plex_sort.dart';
|
||||
import '../../widgets/bottom_sheet_header.dart';
|
||||
import '../../widgets/focusable_bottom_sheet.dart';
|
||||
import '../../widgets/focusable_list_tile.dart';
|
||||
import '../../widgets/overlay_sheet.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
|
||||
class SortBottomSheet extends StatefulWidget {
|
||||
@@ -45,6 +45,11 @@ class _SortBottomSheetState extends State<SortBottomSheet> {
|
||||
if (ctx != null) {
|
||||
Scrollable.ensureVisible(ctx, alignment: 0.5);
|
||||
}
|
||||
// Schedule after overlay's _autoFocus second callback so we override it.
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||
if (!mounted) return;
|
||||
_initialFocusNode.requestFocus();
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
@@ -68,7 +73,7 @@ class _SortBottomSheetState extends State<SortBottomSheet> {
|
||||
_currentDescending = descending;
|
||||
});
|
||||
widget.onSortChanged(sort, descending);
|
||||
Navigator.pop(context);
|
||||
OverlaySheetController.of(context).close();
|
||||
}
|
||||
|
||||
void _handleClear() {
|
||||
@@ -77,89 +82,73 @@ class _SortBottomSheetState extends State<SortBottomSheet> {
|
||||
_currentDescending = false;
|
||||
});
|
||||
widget.onClear?.call();
|
||||
OverlaySheetController.of(context).close();
|
||||
}
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return FocusableBottomSheet(
|
||||
initialFocusNode: _initialFocusNode,
|
||||
child: DraggableScrollableSheet(
|
||||
initialChildSize: 0.6,
|
||||
minChildSize: 0.4,
|
||||
maxChildSize: 0.9,
|
||||
expand: false,
|
||||
builder: (context, scrollController) {
|
||||
return Column(
|
||||
children: [
|
||||
BottomSheetHeader(
|
||||
title: t.libraries.sortBy,
|
||||
action: widget.onClear != null
|
||||
? TextButton(onPressed: _handleClear, child: Text(t.common.clear))
|
||||
: null,
|
||||
),
|
||||
Expanded(
|
||||
child: ListView.builder(
|
||||
controller: scrollController,
|
||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
||||
itemCount: widget.sortOptions.length,
|
||||
itemBuilder: (context, index) {
|
||||
final sort = widget.sortOptions[index];
|
||||
final isSelected = _currentSort?.key == sort.key;
|
||||
return Column(
|
||||
children: [
|
||||
BottomSheetHeader(
|
||||
title: t.libraries.sortBy,
|
||||
action: widget.onClear != null ? TextButton(onPressed: _handleClear, child: Text(t.common.clear)) : null,
|
||||
),
|
||||
Expanded(
|
||||
child: ListView.builder(
|
||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
||||
itemCount: widget.sortOptions.length,
|
||||
itemBuilder: (context, index) {
|
||||
final sort = widget.sortOptions[index];
|
||||
final isSelected = _currentSort?.key == sort.key;
|
||||
|
||||
return Focus(
|
||||
canRequestFocus: false,
|
||||
skipTraversal: true,
|
||||
onKeyEvent: (node, event) {
|
||||
if (!event.isActionable) return KeyEventResult.ignored;
|
||||
if (!isSelected) return KeyEventResult.ignored;
|
||||
if (event.logicalKey.isLeftKey) {
|
||||
_handleDirectionChange(sort, false);
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
if (event.logicalKey.isRightKey) {
|
||||
_handleDirectionChange(sort, true);
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
return KeyEventResult.ignored;
|
||||
},
|
||||
child: FocusableRadioListTile<PlexSort>(
|
||||
focusNode: (widget.selectedSort?.key == sort.key || (widget.selectedSort == null && index == 0))
|
||||
? _initialFocusNode
|
||||
: null,
|
||||
title: Text(sort.title),
|
||||
value: sort,
|
||||
groupValue: _currentSort,
|
||||
onChanged: (value) {
|
||||
if (value != null) _handleSortSelect(value);
|
||||
},
|
||||
secondary: isSelected
|
||||
? SegmentedButton<bool>(
|
||||
showSelectedIcon: false,
|
||||
segments: const [
|
||||
ButtonSegment(
|
||||
value: false,
|
||||
icon: AppIcon(Symbols.arrow_upward_rounded, fill: 1, size: 16),
|
||||
),
|
||||
ButtonSegment(
|
||||
value: true,
|
||||
icon: AppIcon(Symbols.arrow_downward_rounded, fill: 1, size: 16),
|
||||
),
|
||||
],
|
||||
selected: {_currentDescending},
|
||||
onSelectionChanged: (Set<bool> newSelection) {
|
||||
_handleDirectionChange(sort, newSelection.first);
|
||||
},
|
||||
)
|
||||
: null,
|
||||
),
|
||||
);
|
||||
return Focus(
|
||||
canRequestFocus: false,
|
||||
skipTraversal: true,
|
||||
onKeyEvent: (node, event) {
|
||||
if (!event.isActionable) return KeyEventResult.ignored;
|
||||
if (!isSelected) return KeyEventResult.ignored;
|
||||
if (event.logicalKey.isLeftKey) {
|
||||
_handleDirectionChange(sort, false);
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
if (event.logicalKey.isRightKey) {
|
||||
_handleDirectionChange(sort, true);
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
return KeyEventResult.ignored;
|
||||
},
|
||||
child: FocusableRadioListTile<PlexSort>(
|
||||
focusNode: (widget.selectedSort?.key == sort.key || (widget.selectedSort == null && index == 0))
|
||||
? _initialFocusNode
|
||||
: null,
|
||||
title: Text(sort.title),
|
||||
value: sort,
|
||||
groupValue: _currentSort,
|
||||
onChanged: (value) {
|
||||
if (value != null) _handleSortSelect(value);
|
||||
},
|
||||
secondary: isSelected
|
||||
? SegmentedButton<bool>(
|
||||
showSelectedIcon: false,
|
||||
segments: const [
|
||||
ButtonSegment(value: false, icon: AppIcon(Symbols.arrow_upward_rounded, fill: 1, size: 16)),
|
||||
ButtonSegment(
|
||||
value: true,
|
||||
icon: AppIcon(Symbols.arrow_downward_rounded, fill: 1, size: 16),
|
||||
),
|
||||
],
|
||||
selected: {_currentDescending},
|
||||
onSelectionChanged: (Set<bool> newSelection) {
|
||||
_handleDirectionChange(sort, newSelection.first);
|
||||
},
|
||||
)
|
||||
: null,
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
),
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -20,6 +20,7 @@ import '../../../widgets/alpha_scroll_handle.dart';
|
||||
import '../../../widgets/focusable_media_card.dart';
|
||||
import '../../../widgets/focusable_filter_chip.dart';
|
||||
import '../../../widgets/media_grid_delegate.dart';
|
||||
import '../../../widgets/overlay_sheet.dart';
|
||||
import '../../../mixins/library_tab_focus_mixin.dart';
|
||||
import '../folder_tree_view.dart';
|
||||
import '../filters_bottom_sheet.dart';
|
||||
@@ -222,9 +223,22 @@ class _LibraryBrowseTabState extends BaseLibraryTabState<PlexMetadata, LibraryBr
|
||||
@override
|
||||
Widget buildContent(List<PlexMetadata> items) => const SizedBox.shrink();
|
||||
|
||||
/// Focus the first item in the grid/list (for tab activation)
|
||||
/// Focus the first item in the grid/list/folder tree (for tab activation)
|
||||
@override
|
||||
void focusFirstItem() {
|
||||
// In folder mode, items list is empty — focus the first folder tree item directly
|
||||
if (_selectedGrouping == 'folders') {
|
||||
void request() {
|
||||
if (mounted && !firstItemFocusNode.hasFocus) {
|
||||
firstItemFocusNode.requestFocus();
|
||||
}
|
||||
}
|
||||
|
||||
request();
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) => request());
|
||||
return;
|
||||
}
|
||||
|
||||
if (items.isNotEmpty) {
|
||||
// Request immediately, then once more on the next frame to handle cases
|
||||
// where the grid/list attaches after the initial focus attempt.
|
||||
@@ -245,14 +259,7 @@ class _LibraryBrowseTabState extends BaseLibraryTabState<PlexMetadata, LibraryBr
|
||||
/// Focus the chips bar (for navigating from tab bar to content).
|
||||
/// Called by libraries screen when pressing DOWN on tab bar.
|
||||
void focusChipsBar() {
|
||||
// If in folders mode, no chips to focus - go directly to folder tree
|
||||
if (_selectedGrouping == 'folders') {
|
||||
focusFirstItem();
|
||||
return;
|
||||
}
|
||||
|
||||
// With Stack layout, chips are always visible on top of the grid.
|
||||
// No need to scroll - just focus the chip.
|
||||
// Grouping chip is always visible (including in folder mode)
|
||||
_groupingChipFocusNode.requestFocus();
|
||||
}
|
||||
|
||||
@@ -482,52 +489,51 @@ class _LibraryBrowseTabState extends BaseLibraryTabState<PlexMetadata, LibraryBr
|
||||
void _showGroupingBottomSheet() {
|
||||
SelectKeyUpSuppressor.suppressSelectUntilKeyUp();
|
||||
var pendingGrouping = _selectedGrouping;
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
builder: (sheetContext) {
|
||||
final options = _getGroupingOptions();
|
||||
return StatefulBuilder(
|
||||
builder: (context, setSheetState) {
|
||||
return ListView.builder(
|
||||
shrinkWrap: true,
|
||||
itemCount: options.length,
|
||||
itemBuilder: (context, index) {
|
||||
final grouping = options[index];
|
||||
return RadioListTile<String>(
|
||||
title: Text(_getGroupingLabel(grouping)),
|
||||
value: grouping,
|
||||
groupValue: pendingGrouping,
|
||||
onChanged: (value) {
|
||||
if (value == null) return;
|
||||
setSheetState(() {
|
||||
pendingGrouping = value;
|
||||
});
|
||||
OverlaySheetController.of(context)
|
||||
.show(
|
||||
builder: (sheetContext) {
|
||||
final options = _getGroupingOptions();
|
||||
return StatefulBuilder(
|
||||
builder: (context, setSheetState) {
|
||||
return ListView.builder(
|
||||
shrinkWrap: true,
|
||||
itemCount: options.length,
|
||||
itemBuilder: (context, index) {
|
||||
final grouping = options[index];
|
||||
return RadioListTile<String>(
|
||||
title: Text(_getGroupingLabel(grouping)),
|
||||
value: grouping,
|
||||
groupValue: pendingGrouping,
|
||||
onChanged: (value) {
|
||||
if (value == null) return;
|
||||
setSheetState(() {
|
||||
pendingGrouping = value;
|
||||
});
|
||||
},
|
||||
);
|
||||
},
|
||||
);
|
||||
},
|
||||
);
|
||||
},
|
||||
);
|
||||
},
|
||||
).then((_) {
|
||||
if (!mounted) return;
|
||||
if (pendingGrouping == _selectedGrouping) return;
|
||||
setState(() {
|
||||
_selectedGrouping = pendingGrouping;
|
||||
});
|
||||
StorageService.getInstance().then((storage) {
|
||||
storage.saveLibraryGrouping(widget.library.globalKey, pendingGrouping);
|
||||
});
|
||||
_loadItems();
|
||||
_loadFirstCharacters();
|
||||
});
|
||||
)
|
||||
.then((_) {
|
||||
if (!mounted) return;
|
||||
if (pendingGrouping == _selectedGrouping) return;
|
||||
setState(() {
|
||||
_selectedGrouping = pendingGrouping;
|
||||
});
|
||||
StorageService.getInstance().then((storage) {
|
||||
storage.saveLibraryGrouping(widget.library.globalKey, pendingGrouping);
|
||||
});
|
||||
_loadItems();
|
||||
_loadFirstCharacters();
|
||||
});
|
||||
}
|
||||
|
||||
void _showFiltersBottomSheet() {
|
||||
SelectKeyUpSuppressor.suppressSelectUntilKeyUp();
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
isScrollControlled: true,
|
||||
OverlaySheetController.of(context).show(
|
||||
builder: (context) => FiltersBottomSheet(
|
||||
filters: _filters,
|
||||
selectedFilters: _selectedFilters,
|
||||
@@ -557,51 +563,57 @@ class _LibraryBrowseTabState extends BaseLibraryTabState<PlexMetadata, LibraryBr
|
||||
PlexSort? pendingSort = _selectedSort;
|
||||
bool pendingDescending = _isSortDescending;
|
||||
bool pendingCleared = false;
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
isScrollControlled: true,
|
||||
builder: (context) => SortBottomSheet(
|
||||
sortOptions: _sortOptions,
|
||||
selectedSort: _selectedSort,
|
||||
isSortDescending: _isSortDescending,
|
||||
onSortChanged: (sort, descending) {
|
||||
pendingSort = sort;
|
||||
pendingDescending = descending;
|
||||
pendingCleared = false;
|
||||
},
|
||||
onClear: () {
|
||||
pendingSort = null;
|
||||
pendingDescending = false;
|
||||
pendingCleared = true;
|
||||
},
|
||||
),
|
||||
).then((_) {
|
||||
if (!mounted) return;
|
||||
if (pendingCleared) {
|
||||
setState(() {
|
||||
_selectedSort = null;
|
||||
_isSortDescending = false;
|
||||
OverlaySheetController.of(context)
|
||||
.show(
|
||||
builder: (context) => SortBottomSheet(
|
||||
sortOptions: _sortOptions,
|
||||
selectedSort: _selectedSort,
|
||||
isSortDescending: _isSortDescending,
|
||||
onSortChanged: (sort, descending) {
|
||||
pendingSort = sort;
|
||||
pendingDescending = descending;
|
||||
pendingCleared = false;
|
||||
},
|
||||
onClear: () {
|
||||
pendingSort = null;
|
||||
pendingDescending = false;
|
||||
pendingCleared = true;
|
||||
},
|
||||
),
|
||||
)
|
||||
.then((_) {
|
||||
if (!mounted) return;
|
||||
if (pendingCleared) {
|
||||
setState(() {
|
||||
_selectedSort = null;
|
||||
_isSortDescending = false;
|
||||
});
|
||||
_loadItems();
|
||||
_loadFirstCharacters();
|
||||
} else if (pendingSort != null &&
|
||||
(pendingSort!.key != _selectedSort?.key || pendingDescending != _isSortDescending)) {
|
||||
setState(() {
|
||||
_selectedSort = pendingSort;
|
||||
_isSortDescending = pendingDescending;
|
||||
});
|
||||
StorageService.getInstance().then((storage) {
|
||||
storage.saveLibrarySort(widget.library.globalKey, pendingSort!.key, descending: pendingDescending);
|
||||
});
|
||||
_loadItems();
|
||||
_loadFirstCharacters();
|
||||
}
|
||||
});
|
||||
_loadItems();
|
||||
_loadFirstCharacters();
|
||||
} else if (pendingSort != null &&
|
||||
(pendingSort!.key != _selectedSort?.key || pendingDescending != _isSortDescending)) {
|
||||
setState(() {
|
||||
_selectedSort = pendingSort;
|
||||
_isSortDescending = pendingDescending;
|
||||
});
|
||||
StorageService.getInstance().then((storage) {
|
||||
storage.saveLibrarySort(widget.library.globalKey, pendingSort!.key, descending: pendingDescending);
|
||||
});
|
||||
_loadItems();
|
||||
_loadFirstCharacters();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
/// Navigate focus from chips down to the grid item.
|
||||
/// Restores focus to the previously focused item if content hasn't changed.
|
||||
void _navigateToGrid() {
|
||||
// In folder mode, firstItemFocusNode is attached to the first folder tree item
|
||||
if (_selectedGrouping == 'folders') {
|
||||
firstItemFocusNode.requestFocus();
|
||||
return;
|
||||
}
|
||||
|
||||
if (items.isEmpty) return;
|
||||
|
||||
final targetIndex = shouldRestoreGridFocus && lastFocusedGridIndex! < items.length ? lastFocusedGridIndex! : 0;
|
||||
@@ -649,6 +661,13 @@ class _LibraryBrowseTabState extends BaseLibraryTabState<PlexMetadata, LibraryBr
|
||||
/// Whether the device is a phone (not tablet/desktop/TV).
|
||||
bool _isPhone(BuildContext context) => PlatformDetector.isPhone(context);
|
||||
|
||||
/// The letter currently visible at the top of the grid, determined by
|
||||
/// how many items we've scrolled past relative to the API's cumulative
|
||||
/// firstCharacter counts.
|
||||
String get _currentAlphaLetter {
|
||||
return _alphaHelper.currentLetter(_currentFirstVisibleIndex);
|
||||
}
|
||||
|
||||
/// Whether the alpha jump bar should be shown.
|
||||
/// Only shown when sorting by title (titleSort) and not in folders mode.
|
||||
bool get _shouldShowAlphaJumpBar {
|
||||
@@ -736,51 +755,23 @@ class _LibraryBrowseTabState extends BaseLibraryTabState<PlexMetadata, LibraryBr
|
||||
}
|
||||
|
||||
/// Scroll to the item at [targetIndex], loading more pages if necessary.
|
||||
/// Pins the index so scroll events during the animation don't override
|
||||
/// the highlighted letter. The pin is cleared on the next user scroll.
|
||||
///
|
||||
/// The [targetIndex] comes from [AlphaJumpHelper] which derives cumulative
|
||||
/// indices from the `firstCharacters` API. That API may count by display
|
||||
/// title (e.g. "The Simpsons" → T), while the grid sorts by `titleSort`
|
||||
/// (e.g. "Simpsons" → S). We correct for this by searching the loaded
|
||||
/// items' `titleSort` for the true start of the target letter.
|
||||
/// The target index is a cumulative offset from the API's firstCharacter
|
||||
/// counts — the same model used by [_currentAlphaLetter] so highlight
|
||||
/// and jump always agree.
|
||||
void _jumpToIndex(int targetIndex) {
|
||||
_jumpScrollGeneration++;
|
||||
_isJumpScrolling = true;
|
||||
|
||||
// Determine the intended letter from the helper's model
|
||||
final targetLetter = _alphaHelper.currentLetter(targetIndex);
|
||||
|
||||
// Correct the index using actual items' titleSort when available
|
||||
final correctedIndex = _findFirstItemForLetter(targetLetter) ?? targetIndex;
|
||||
|
||||
_hasJumpPin = true;
|
||||
setState(() => _currentFirstVisibleIndex = correctedIndex);
|
||||
setState(() => _currentFirstVisibleIndex = targetIndex);
|
||||
|
||||
if (correctedIndex < items.length) {
|
||||
_scrollToItemIndex(correctedIndex);
|
||||
if (targetIndex < items.length) {
|
||||
_scrollToItemIndex(targetIndex);
|
||||
} else {
|
||||
_loadUntilIndex(correctedIndex);
|
||||
_loadUntilIndex(targetIndex);
|
||||
}
|
||||
}
|
||||
|
||||
/// Returns the first character (A-Z or #) of an item's sort title.
|
||||
static String _sortTitleFirstChar(String title) {
|
||||
if (title.isEmpty) return '#';
|
||||
final ch = title[0].toUpperCase();
|
||||
return ch.codeUnitAt(0) >= 65 && ch.codeUnitAt(0) <= 90 ? ch : '#';
|
||||
}
|
||||
|
||||
/// Find the index of the first loaded item whose `titleSort` starts with
|
||||
/// [letter]. Returns null if no match is found (e.g. items not yet loaded).
|
||||
int? _findFirstItemForLetter(String letter) {
|
||||
for (int i = 0; i < items.length; i++) {
|
||||
final sortTitle = items[i].titleSort ?? items[i].title;
|
||||
if (_sortTitleFirstChar(sortTitle) == letter) return i;
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/// Scroll the grid so that [index] is visible just below the chips bar
|
||||
void _scrollToItemIndex(int index) {
|
||||
if (_currentColumnCount < 1 || _lastCrossAxisExtent <= 0 || !_scrollController.hasClients) {
|
||||
@@ -831,52 +822,58 @@ class _LibraryBrowseTabState extends BaseLibraryTabState<PlexMetadata, LibraryBr
|
||||
|
||||
// For folders mode, use FolderTreeView instead of grid/list
|
||||
if (_selectedGrouping == 'folders') {
|
||||
return Column(
|
||||
children: [
|
||||
_buildChipsBar(),
|
||||
Expanded(
|
||||
child: FolderTreeView(
|
||||
libraryKey: widget.library.key,
|
||||
serverId: widget.library.serverId,
|
||||
onRefresh: updateItem,
|
||||
return OverlaySheetHost(
|
||||
child: Column(
|
||||
children: [
|
||||
_buildChipsBar(),
|
||||
Expanded(
|
||||
child: FolderTreeView(
|
||||
libraryKey: widget.library.key,
|
||||
serverId: widget.library.serverId,
|
||||
onRefresh: updateItem,
|
||||
firstItemFocusNode: firstItemFocusNode,
|
||||
onNavigateUp: () => _groupingChipFocusNode.requestFocus(),
|
||||
),
|
||||
),
|
||||
),
|
||||
],
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
// For list/grid modes, use Stack with chips layered on top of grid.
|
||||
// This allows the grid to use Clip.none for focus decorations while
|
||||
// the chips bar (with background) covers any overflow at the top.
|
||||
return Stack(
|
||||
children: [
|
||||
// Grid fills the entire area, with top padding for chips bar
|
||||
Positioned.fill(child: _buildScrollableContent()),
|
||||
// Chips bar on top with solid background
|
||||
Positioned(top: 0, left: 0, right: 0, child: _buildChipsBar()),
|
||||
// Alpha jump bar / scroll handle on the right edge
|
||||
if (_shouldShowAlphaJumpBar)
|
||||
Positioned(
|
||||
top: _chipsBarHeight,
|
||||
right: 0,
|
||||
bottom: 0,
|
||||
child: _isPhone(context)
|
||||
? AlphaScrollHandle(
|
||||
firstCharacters: _firstCharacters,
|
||||
onJump: _jumpToIndex,
|
||||
currentFirstVisibleIndex: _currentFirstVisibleIndex,
|
||||
isScrolling: _isScrollActive,
|
||||
)
|
||||
: AlphaJumpBar(
|
||||
firstCharacters: _firstCharacters,
|
||||
onJump: _jumpToIndex,
|
||||
currentFirstVisibleIndex: _currentFirstVisibleIndex,
|
||||
focusNode: _alphaJumpBarFocusNode,
|
||||
onNavigateLeft: _navigateToGridNearScroll,
|
||||
onBack: _navigateToGridNearScroll,
|
||||
),
|
||||
),
|
||||
],
|
||||
return OverlaySheetHost(
|
||||
child: Stack(
|
||||
children: [
|
||||
// Grid fills the entire area, with top padding for chips bar
|
||||
Positioned.fill(child: _buildScrollableContent()),
|
||||
// Chips bar on top with solid background
|
||||
Positioned(top: 0, left: 0, right: 0, child: _buildChipsBar()),
|
||||
// Alpha jump bar / scroll handle on the right edge
|
||||
if (_shouldShowAlphaJumpBar)
|
||||
Positioned(
|
||||
top: _chipsBarHeight,
|
||||
right: 0,
|
||||
bottom: 0,
|
||||
child: _isPhone(context)
|
||||
? AlphaScrollHandle(
|
||||
firstCharacters: _firstCharacters,
|
||||
onJump: _jumpToIndex,
|
||||
currentLetter: _currentAlphaLetter,
|
||||
isScrolling: _isScrollActive,
|
||||
)
|
||||
: AlphaJumpBar(
|
||||
firstCharacters: _firstCharacters,
|
||||
onJump: _jumpToIndex,
|
||||
currentLetter: _currentAlphaLetter,
|
||||
focusNode: _alphaJumpBarFocusNode,
|
||||
onNavigateLeft: _navigateToGridNearScroll,
|
||||
onBack: _navigateToGridNearScroll,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -2,6 +2,7 @@ import 'package:flutter/material.dart';
|
||||
import 'package:material_symbols_icons/symbols.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
|
||||
import '../../focus/focusable_button.dart';
|
||||
import '../../focus/focusable_wrapper.dart';
|
||||
import '../../focus/key_event_utils.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
@@ -103,8 +104,18 @@ class _DvrRecordingsScreenState extends State<DvrRecordingsScreen> with SingleTi
|
||||
title: Text(t.liveTv.deleteSubscription),
|
||||
content: Text(t.liveTv.deleteSubscriptionConfirm),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.of(context).pop(false), child: Text(t.common.cancel)),
|
||||
FilledButton(onPressed: () => Navigator.of(context).pop(true), child: Text(t.common.delete)),
|
||||
FocusableButton(
|
||||
autofocus: true,
|
||||
onPressed: () => Navigator.of(context).pop(false),
|
||||
child: TextButton(
|
||||
onPressed: () => Navigator.of(context).pop(false),
|
||||
child: Text(t.common.cancel),
|
||||
),
|
||||
),
|
||||
FocusableButton(
|
||||
onPressed: () => Navigator.of(context).pop(true),
|
||||
child: FilledButton(onPressed: () => Navigator.of(context).pop(true), child: Text(t.common.delete)),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
@@ -320,6 +331,7 @@ class _SubscriptionEditDialog extends StatefulWidget {
|
||||
class _SubscriptionEditDialogState extends State<_SubscriptionEditDialog> {
|
||||
late Map<String, String> _prefs;
|
||||
final Map<String, TextEditingController> _textControllers = {};
|
||||
final _saveFocusNode = FocusNode();
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
@@ -332,6 +344,7 @@ class _SubscriptionEditDialogState extends State<_SubscriptionEditDialog> {
|
||||
for (final controller in _textControllers.values) {
|
||||
controller.dispose();
|
||||
}
|
||||
_saveFocusNode.dispose();
|
||||
super.dispose();
|
||||
}
|
||||
|
||||
@@ -351,8 +364,18 @@ class _SubscriptionEditDialogState extends State<_SubscriptionEditDialog> {
|
||||
),
|
||||
),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.of(context).pop(null), child: Text(t.common.cancel)),
|
||||
FilledButton(onPressed: () => Navigator.of(context).pop(_prefs), child: Text(t.common.save)),
|
||||
FocusableButton(
|
||||
onPressed: () => Navigator.of(context).pop(null),
|
||||
child: TextButton(onPressed: () => Navigator.of(context).pop(null), child: Text(t.common.cancel)),
|
||||
),
|
||||
FocusableButton(
|
||||
focusNode: _saveFocusNode,
|
||||
onPressed: () => Navigator.of(context).pop(_prefs),
|
||||
child: FilledButton(
|
||||
onPressed: () => Navigator.of(context).pop(_prefs),
|
||||
child: Text(t.common.save),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
@@ -399,9 +422,11 @@ class _SubscriptionEditDialogState extends State<_SubscriptionEditDialog> {
|
||||
title: Text(setting.label ?? setting.id),
|
||||
subtitle: TextField(
|
||||
controller: controller,
|
||||
textInputAction: TextInputAction.done,
|
||||
onChanged: (newValue) {
|
||||
_prefs[setting.id] = newValue;
|
||||
},
|
||||
onSubmitted: (_) => _saveFocusNode.requestFocus(),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@ import '../../focus/dpad_navigator.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
import '../../models/livetv_channel.dart';
|
||||
import '../../models/livetv_dvr.dart';
|
||||
import '../../mixins/refreshable.dart';
|
||||
import '../../mixins/tab_navigation_mixin.dart';
|
||||
import '../../providers/multi_server_provider.dart';
|
||||
import '../../utils/app_logger.dart';
|
||||
@@ -23,7 +24,9 @@ class LiveTvScreen extends StatefulWidget {
|
||||
State<LiveTvScreen> createState() => _LiveTvScreenState();
|
||||
}
|
||||
|
||||
class _LiveTvScreenState extends State<LiveTvScreen> with SingleTickerProviderStateMixin, TabNavigationMixin {
|
||||
class _LiveTvScreenState extends State<LiveTvScreen>
|
||||
with SingleTickerProviderStateMixin, TabNavigationMixin
|
||||
implements FocusableTab {
|
||||
final _guideTabFocusNode = FocusNode(debugLabel: 'tab_chip_guide');
|
||||
final _whatsOnTabFocusNode = FocusNode(debugLabel: 'tab_chip_whats_on');
|
||||
final _guideTabKey = GlobalKey<GuideTabState>();
|
||||
@@ -216,6 +219,9 @@ class _LiveTvScreenState extends State<LiveTvScreen> with SingleTickerProviderSt
|
||||
});
|
||||
}
|
||||
|
||||
@override
|
||||
void focusActiveTabIfReady() => _focusCurrentTab();
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
// Action button key handlers
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
@@ -12,6 +12,7 @@ import '../../utils/live_tv_player_navigation.dart';
|
||||
import '../../utils/plex_image_helper.dart';
|
||||
import '../../widgets/app_icon.dart';
|
||||
import '../../widgets/focused_scroll_scaffold.dart';
|
||||
import '../../widgets/overlay_sheet.dart';
|
||||
import 'program_details_sheet.dart';
|
||||
|
||||
/// Shows all upcoming airings of a show, matching the Plex "upcoming episodes" view.
|
||||
@@ -126,39 +127,41 @@ class _LiveTvShowScheduleScreenState extends State<LiveTvShowScheduleScreen> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return FocusedScrollScaffold(
|
||||
title: Text(widget.showTitle),
|
||||
slivers: [
|
||||
if (_isLoading)
|
||||
const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))
|
||||
else if (_programs.isEmpty)
|
||||
SliverFillRemaining(child: Center(child: Text(t.liveTv.noPrograms)))
|
||||
else
|
||||
SliverList(
|
||||
delegate: SliverChildBuilderDelegate((context, index) {
|
||||
final program = _programs[index];
|
||||
final channel = _findChannel(program.channelIdentifier);
|
||||
void onTap() {
|
||||
if (program.isCurrentlyAiring && channel != null) {
|
||||
_tuneChannel(channel);
|
||||
} else {
|
||||
_showProgramDetails(program, channel);
|
||||
return OverlaySheetHost(
|
||||
child: FocusedScrollScaffold(
|
||||
title: Text(widget.showTitle),
|
||||
slivers: [
|
||||
if (_isLoading)
|
||||
const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))
|
||||
else if (_programs.isEmpty)
|
||||
SliverFillRemaining(child: Center(child: Text(t.liveTv.noPrograms)))
|
||||
else
|
||||
SliverList(
|
||||
delegate: SliverChildBuilderDelegate((context, index) {
|
||||
final program = _programs[index];
|
||||
final channel = _findChannel(program.channelIdentifier);
|
||||
void onTap() {
|
||||
if (program.isCurrentlyAiring && channel != null) {
|
||||
_tuneChannel(channel);
|
||||
} else {
|
||||
_showProgramDetails(program, channel);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return FocusableWrapper(
|
||||
autofocus: index == 0,
|
||||
autoScroll: true,
|
||||
useComfortableZone: true,
|
||||
useBackgroundFocus: true,
|
||||
disableScale: true,
|
||||
onSelect: onTap,
|
||||
onBack: () => Navigator.pop(context),
|
||||
child: _ScheduleListTile(program: program, channel: channel, onTap: onTap),
|
||||
);
|
||||
}, childCount: _programs.length),
|
||||
),
|
||||
],
|
||||
return FocusableWrapper(
|
||||
autofocus: index == 0,
|
||||
autoScroll: true,
|
||||
useComfortableZone: true,
|
||||
useBackgroundFocus: true,
|
||||
disableScale: true,
|
||||
onSelect: onTap,
|
||||
onBack: () => Navigator.pop(context),
|
||||
child: _ScheduleListTile(program: program, channel: channel, onTap: onTap),
|
||||
);
|
||||
}, childCount: _programs.length),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,13 +1,14 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:material_symbols_icons/symbols.dart';
|
||||
|
||||
import '../../focus/focusable_wrapper.dart';
|
||||
import '../../focus/focusable_button.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
import '../../models/livetv_channel.dart';
|
||||
import '../../models/livetv_program.dart';
|
||||
import '../../utils/formatters.dart';
|
||||
import '../../widgets/app_icon.dart';
|
||||
import '../../widgets/focusable_bottom_sheet.dart';
|
||||
import '../../widgets/overlay_sheet.dart';
|
||||
import '../../widgets/plex_optimized_image.dart' show blurArtwork;
|
||||
|
||||
/// Shows a bottom sheet with program details and actions (Record, Watch Channel, Play).
|
||||
void showProgramDetailsSheet(
|
||||
@@ -17,17 +18,31 @@ void showProgramDetailsSheet(
|
||||
required String? posterUrl,
|
||||
required VoidCallback? onTuneChannel,
|
||||
}) {
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
builder: (sheetContext) {
|
||||
return _ProgramDetailsSheetContent(
|
||||
program: program,
|
||||
channel: channel,
|
||||
posterUrl: posterUrl,
|
||||
onTuneChannel: onTuneChannel,
|
||||
);
|
||||
},
|
||||
);
|
||||
final controller = OverlaySheetController.maybeOf(context);
|
||||
if (controller != null) {
|
||||
controller.show(
|
||||
builder: (sheetContext) {
|
||||
return _ProgramDetailsSheetContent(
|
||||
program: program,
|
||||
channel: channel,
|
||||
posterUrl: posterUrl,
|
||||
onTuneChannel: onTuneChannel,
|
||||
);
|
||||
},
|
||||
);
|
||||
} else {
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
builder: (sheetContext) {
|
||||
return _ProgramDetailsSheetContent(
|
||||
program: program,
|
||||
channel: channel,
|
||||
posterUrl: posterUrl,
|
||||
onTuneChannel: onTuneChannel,
|
||||
);
|
||||
},
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
class _ProgramDetailsSheetContent extends StatefulWidget {
|
||||
@@ -50,8 +65,6 @@ class _ProgramDetailsSheetContent extends StatefulWidget {
|
||||
class _ProgramDetailsSheetContentState extends State<_ProgramDetailsSheetContent> {
|
||||
final List<FocusNode> _buttonFocusNodes = [];
|
||||
|
||||
FocusNode get _initialFocusNode => _buttonFocusNodes.isNotEmpty ? _buttonFocusNodes.first : FocusNode();
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
@@ -94,25 +107,31 @@ class _ProgramDetailsSheetContentState extends State<_ProgramDetailsSheetContent
|
||||
final buttons = <Widget>[];
|
||||
int buttonIndex = 0;
|
||||
|
||||
void closeSheet() {
|
||||
final controller = OverlaySheetController.maybeOf(context);
|
||||
if (controller != null) {
|
||||
controller.close();
|
||||
} else {
|
||||
Navigator.of(context).pop();
|
||||
}
|
||||
}
|
||||
|
||||
if (program.isCurrentlyAiring && widget.onTuneChannel != null) {
|
||||
final idx = buttonIndex;
|
||||
buttons.add(
|
||||
FocusableWrapper(
|
||||
FocusableButton(
|
||||
focusNode: _buttonFocusNodes[idx],
|
||||
onSelect: () {
|
||||
Navigator.of(context).pop();
|
||||
onPressed: () {
|
||||
closeSheet();
|
||||
widget.onTuneChannel!();
|
||||
},
|
||||
onNavigateLeft: idx > 0 ? () => _focusButton(idx - 1) : null,
|
||||
onNavigateRight: idx < _buttonFocusNodes.length - 1 ? () => _focusButton(idx + 1) : null,
|
||||
onBack: () => Navigator.of(context).pop(),
|
||||
borderRadius: 100,
|
||||
useBackgroundFocus: true,
|
||||
disableScale: true,
|
||||
onBack: closeSheet,
|
||||
child: FilledButton.icon(
|
||||
style: FilledButton.styleFrom(tapTargetSize: MaterialTapTargetSize.shrinkWrap),
|
||||
onPressed: () {
|
||||
Navigator.of(context).pop();
|
||||
closeSheet();
|
||||
widget.onTuneChannel!();
|
||||
},
|
||||
icon: const AppIcon(Symbols.play_arrow_rounded),
|
||||
@@ -159,22 +178,19 @@ class _ProgramDetailsSheetContentState extends State<_ProgramDetailsSheetContent
|
||||
buttons.add(const SizedBox(width: 8));
|
||||
final idx = buttonIndex;
|
||||
buttons.add(
|
||||
FocusableWrapper(
|
||||
FocusableButton(
|
||||
focusNode: _buttonFocusNodes[idx],
|
||||
onSelect: () {
|
||||
Navigator.of(context).pop();
|
||||
onPressed: () {
|
||||
closeSheet();
|
||||
widget.onTuneChannel!();
|
||||
},
|
||||
onNavigateLeft: idx > 0 ? () => _focusButton(idx - 1) : null,
|
||||
onNavigateRight: idx < _buttonFocusNodes.length - 1 ? () => _focusButton(idx + 1) : null,
|
||||
onBack: () => Navigator.of(context).pop(),
|
||||
borderRadius: 100,
|
||||
useBackgroundFocus: true,
|
||||
disableScale: true,
|
||||
onBack: closeSheet,
|
||||
child: OutlinedButton.icon(
|
||||
style: OutlinedButton.styleFrom(tapTargetSize: MaterialTapTargetSize.shrinkWrap),
|
||||
onPressed: () {
|
||||
Navigator.of(context).pop();
|
||||
closeSheet();
|
||||
widget.onTuneChannel!();
|
||||
},
|
||||
icon: const AppIcon(Symbols.live_tv_rounded),
|
||||
@@ -185,79 +201,76 @@ class _ProgramDetailsSheetContentState extends State<_ProgramDetailsSheetContent
|
||||
buttonIndex++;
|
||||
}
|
||||
|
||||
return FocusableBottomSheet(
|
||||
initialFocusNode: _initialFocusNode,
|
||||
child: Padding(
|
||||
padding: const EdgeInsets.all(20),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Row(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
if (widget.posterUrl != null) ...[
|
||||
ClipRRect(
|
||||
borderRadius: const BorderRadius.all(Radius.circular(6)),
|
||||
child: Image.network(
|
||||
widget.posterUrl!,
|
||||
width: 80,
|
||||
height: 120,
|
||||
fit: BoxFit.cover,
|
||||
errorBuilder: (_, _, _) => const SizedBox.shrink(),
|
||||
),
|
||||
),
|
||||
const SizedBox(width: 14),
|
||||
],
|
||||
Expanded(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Row(
|
||||
children: [
|
||||
Expanded(child: Text(program.displayTitle, style: theme.textTheme.titleMedium)),
|
||||
if (program.isCurrentlyAiring)
|
||||
Container(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 4),
|
||||
decoration: const BoxDecoration(
|
||||
color: Colors.red,
|
||||
borderRadius: BorderRadius.all(Radius.circular(4)),
|
||||
),
|
||||
child: Text(
|
||||
t.liveTv.live,
|
||||
style: const TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 11),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
const SizedBox(height: 4),
|
||||
Text(
|
||||
[
|
||||
if (channel != null) channel.displayName,
|
||||
if (program.startTime != null && program.endTime != null)
|
||||
'${program.startTime!.hour.toString().padLeft(2, '0')}:${program.startTime!.minute.toString().padLeft(2, '0')} - ${program.endTime!.hour.toString().padLeft(2, '0')}:${program.endTime!.minute.toString().padLeft(2, '0')}',
|
||||
if (program.durationMinutes > 0) formatDurationTextual(program.durationMinutes * 60000),
|
||||
].join(' · '),
|
||||
style: theme.textTheme.bodySmall?.copyWith(color: theme.colorScheme.onSurfaceVariant),
|
||||
),
|
||||
if (program.summary != null && program.summary!.isNotEmpty) ...[
|
||||
const SizedBox(height: 12),
|
||||
Text(
|
||||
program.summary!,
|
||||
style: theme.textTheme.bodyMedium,
|
||||
maxLines: 4,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
),
|
||||
],
|
||||
],
|
||||
),
|
||||
return Padding(
|
||||
padding: const EdgeInsets.all(20),
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Row(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
if (widget.posterUrl != null) ...[
|
||||
ClipRRect(
|
||||
borderRadius: const BorderRadius.all(Radius.circular(6)),
|
||||
child: blurArtwork(Image.network(
|
||||
widget.posterUrl!,
|
||||
width: 80,
|
||||
height: 120,
|
||||
fit: BoxFit.cover,
|
||||
errorBuilder: (_, _, _) => const SizedBox.shrink(),
|
||||
)),
|
||||
),
|
||||
const SizedBox(width: 14),
|
||||
],
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Row(children: buttons),
|
||||
],
|
||||
),
|
||||
Expanded(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Row(
|
||||
children: [
|
||||
Expanded(child: Text(program.displayTitle, style: theme.textTheme.titleMedium)),
|
||||
if (program.isCurrentlyAiring)
|
||||
Container(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 4),
|
||||
decoration: const BoxDecoration(
|
||||
color: Colors.red,
|
||||
borderRadius: BorderRadius.all(Radius.circular(4)),
|
||||
),
|
||||
child: Text(
|
||||
t.liveTv.live,
|
||||
style: const TextStyle(color: Colors.white, fontWeight: FontWeight.bold, fontSize: 11),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
const SizedBox(height: 4),
|
||||
Text(
|
||||
[
|
||||
if (channel != null) channel.displayName,
|
||||
if (program.startTime != null && program.endTime != null)
|
||||
'${program.startTime!.hour.toString().padLeft(2, '0')}:${program.startTime!.minute.toString().padLeft(2, '0')} - ${program.endTime!.hour.toString().padLeft(2, '0')}:${program.endTime!.minute.toString().padLeft(2, '0')}',
|
||||
if (program.durationMinutes > 0) formatDurationTextual(program.durationMinutes * 60000),
|
||||
].join(' · '),
|
||||
style: theme.textTheme.bodySmall?.copyWith(color: theme.colorScheme.onSurfaceVariant),
|
||||
),
|
||||
if (program.summary != null && program.summary!.isNotEmpty) ...[
|
||||
const SizedBox(height: 12),
|
||||
Text(
|
||||
program.summary!,
|
||||
style: theme.textTheme.bodyMedium,
|
||||
maxLines: 4,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
),
|
||||
],
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
Row(children: buttons),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
@@ -17,6 +17,7 @@ import '../../../utils/formatters.dart';
|
||||
import '../../../utils/plex_image_helper.dart';
|
||||
import '../../../utils/live_tv_player_navigation.dart';
|
||||
import '../../../widgets/app_icon.dart';
|
||||
import '../../../widgets/overlay_sheet.dart';
|
||||
import '../../../widgets/plex_optimized_image.dart';
|
||||
import '../program_details_sheet.dart';
|
||||
|
||||
@@ -375,15 +376,21 @@ class GuideTabState extends State<GuideTab> {
|
||||
});
|
||||
_scrollToProgramTime(program);
|
||||
}
|
||||
} else {
|
||||
// Already in program column — move to next program
|
||||
_navigateToAdjacentProgram(_gridChannelIndex, forward: true);
|
||||
}
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
if (key.isLeftKey) {
|
||||
if (_gridColumn == 1) {
|
||||
setState(() {
|
||||
_gridColumn = 0;
|
||||
_focusedProgram = null;
|
||||
});
|
||||
// Try moving to previous program; if at first program, go back to channel column
|
||||
if (!_navigateToAdjacentProgram(_gridChannelIndex, forward: false)) {
|
||||
setState(() {
|
||||
_gridColumn = 0;
|
||||
_focusedProgram = null;
|
||||
});
|
||||
}
|
||||
} else {
|
||||
widget.onBack?.call();
|
||||
}
|
||||
@@ -424,6 +431,27 @@ class GuideTabState extends State<GuideTab> {
|
||||
return programs.firstOrNull;
|
||||
}
|
||||
|
||||
/// Navigate to the next or previous program on the same channel.
|
||||
/// Returns true if navigation succeeded, false if at the boundary.
|
||||
bool _navigateToAdjacentProgram(int channelIndex, {required bool forward}) {
|
||||
if (channelIndex < 0 || channelIndex >= widget.channels.length) return false;
|
||||
final channel = widget.channels[channelIndex];
|
||||
final programs = _getProgramsForChannel(channel);
|
||||
if (programs.isEmpty || _focusedProgram == null) return false;
|
||||
|
||||
final currentIndex = programs.indexWhere((p) => identical(p, _focusedProgram));
|
||||
if (currentIndex < 0) return false;
|
||||
|
||||
final nextIndex = forward ? currentIndex + 1 : currentIndex - 1;
|
||||
if (nextIndex < 0 || nextIndex >= programs.length) return false;
|
||||
|
||||
setState(() {
|
||||
_focusedProgram = programs[nextIndex];
|
||||
});
|
||||
_scrollToProgramTime(_focusedProgram);
|
||||
return true;
|
||||
}
|
||||
|
||||
void _scrollToChannel(int index) {
|
||||
if (!_gridVerticalController.hasClients) return;
|
||||
final targetTop = index * _rowHeight;
|
||||
@@ -440,9 +468,13 @@ class GuideTabState extends State<GuideTab> {
|
||||
|
||||
if (newOffset != null) {
|
||||
final clamped = newOffset.clamp(0.0, _gridVerticalController.position.maxScrollExtent);
|
||||
_gridVerticalController.jumpTo(clamped);
|
||||
_gridVerticalController.animateTo(clamped, duration: const Duration(milliseconds: 150), curve: Curves.easeOut);
|
||||
if (_channelVerticalController.hasClients) {
|
||||
_channelVerticalController.jumpTo(clamped.clamp(0.0, _channelVerticalController.position.maxScrollExtent));
|
||||
_channelVerticalController.animateTo(
|
||||
clamped.clamp(0.0, _channelVerticalController.position.maxScrollExtent),
|
||||
duration: const Duration(milliseconds: 150),
|
||||
curve: Curves.easeOut,
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -477,11 +509,13 @@ class GuideTabState extends State<GuideTab> {
|
||||
return const Center(child: CircularProgressIndicator());
|
||||
}
|
||||
|
||||
return Focus(
|
||||
focusNode: _guideFocusNode,
|
||||
onFocusChange: (hasFocus) => setState(() => _hasFocus = hasFocus),
|
||||
onKeyEvent: _handleKeyEvent,
|
||||
child: _buildGuideGrid(theme),
|
||||
return OverlaySheetHost(
|
||||
child: Focus(
|
||||
focusNode: _guideFocusNode,
|
||||
onFocusChange: (hasFocus) => setState(() => _hasFocus = hasFocus),
|
||||
onKeyEvent: _handleKeyEvent,
|
||||
child: _buildGuideGrid(theme),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -22,6 +22,7 @@ import '../../../utils/plex_image_helper.dart';
|
||||
import '../../../utils/provider_extensions.dart';
|
||||
import '../../../widgets/app_icon.dart';
|
||||
import '../../../widgets/focus_builders.dart';
|
||||
import '../../../widgets/overlay_sheet.dart';
|
||||
import '../../../utils/scroll_utils.dart';
|
||||
import '../../../widgets/horizontal_scroll_with_arrows.dart';
|
||||
import '../../../widgets/plex_optimized_image.dart';
|
||||
@@ -222,20 +223,22 @@ class WhatsOnTabState extends State<WhatsOnTab> {
|
||||
return Center(child: Text(t.liveTv.noPrograms));
|
||||
}
|
||||
|
||||
return ListView.builder(
|
||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
||||
clipBehavior: Clip.none,
|
||||
itemCount: _hubs.length,
|
||||
itemBuilder: (context, index) {
|
||||
return _LiveTvHubSection(
|
||||
key: _hubKeys[index],
|
||||
hub: _hubs[index],
|
||||
onTap: _onItemTap,
|
||||
onLongPress: (entry) => _showProgramDetails(entry, _findChannel(entry.program.channelIdentifier)),
|
||||
onVerticalNavigation: (isUp) => _handleVerticalNavigation(index, isUp),
|
||||
onBack: widget.onBack,
|
||||
);
|
||||
},
|
||||
return OverlaySheetHost(
|
||||
child: ListView.builder(
|
||||
padding: const EdgeInsets.symmetric(vertical: 8),
|
||||
clipBehavior: Clip.none,
|
||||
itemCount: _hubs.length,
|
||||
itemBuilder: (context, index) {
|
||||
return _LiveTvHubSection(
|
||||
key: _hubKeys[index],
|
||||
hub: _hubs[index],
|
||||
onTap: _onItemTap,
|
||||
onLongPress: (entry) => _showProgramDetails(entry, _findChannel(entry.program.channelIdentifier)),
|
||||
onVerticalNavigation: (isUp) => _handleVerticalNavigation(index, isUp),
|
||||
onBack: widget.onBack,
|
||||
);
|
||||
},
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -10,6 +10,7 @@ import '../../services/plex_client.dart';
|
||||
import '../i18n/strings.g.dart';
|
||||
import '../services/update_service.dart';
|
||||
import '../utils/app_logger.dart';
|
||||
import '../focus/focusable_button.dart';
|
||||
import '../utils/dialogs.dart';
|
||||
import '../utils/provider_extensions.dart';
|
||||
import '../utils/platform_detector.dart';
|
||||
@@ -226,27 +227,36 @@ class _MainScreenState extends State<MainScreen> with RouteAware, WindowListener
|
||||
],
|
||||
),
|
||||
actions: [
|
||||
TextButton(
|
||||
FocusableButton(
|
||||
autofocus: true,
|
||||
onPressed: () => Navigator.pop(dialogContext),
|
||||
style: TextButton.styleFrom(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 18, vertical: 14),
|
||||
shape: const StadiumBorder(),
|
||||
child: TextButton(
|
||||
onPressed: () => Navigator.pop(dialogContext),
|
||||
style: TextButton.styleFrom(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 18, vertical: 14),
|
||||
shape: const StadiumBorder(),
|
||||
),
|
||||
child: Text(t.common.later),
|
||||
),
|
||||
child: Text(t.common.later),
|
||||
),
|
||||
TextButton(
|
||||
FocusableButton(
|
||||
onPressed: () async {
|
||||
await UpdateService.skipVersion(updateInfo['latestVersion']);
|
||||
if (dialogContext.mounted) Navigator.pop(dialogContext);
|
||||
},
|
||||
style: TextButton.styleFrom(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 18, vertical: 14),
|
||||
shape: const StadiumBorder(),
|
||||
child: TextButton(
|
||||
onPressed: () async {
|
||||
await UpdateService.skipVersion(updateInfo['latestVersion']);
|
||||
if (dialogContext.mounted) Navigator.pop(dialogContext);
|
||||
},
|
||||
style: TextButton.styleFrom(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 18, vertical: 14),
|
||||
shape: const StadiumBorder(),
|
||||
),
|
||||
child: Text(t.update.skipVersion),
|
||||
),
|
||||
child: Text(t.update.skipVersion),
|
||||
),
|
||||
FilledButton(
|
||||
FocusableButton(
|
||||
onPressed: () async {
|
||||
final url = Uri.parse(updateInfo['releaseUrl']);
|
||||
if (await canLaunchUrl(url)) {
|
||||
@@ -254,7 +264,16 @@ class _MainScreenState extends State<MainScreen> with RouteAware, WindowListener
|
||||
}
|
||||
if (dialogContext.mounted) Navigator.pop(dialogContext);
|
||||
},
|
||||
child: Text(t.update.viewRelease),
|
||||
child: FilledButton(
|
||||
onPressed: () async {
|
||||
final url = Uri.parse(updateInfo['releaseUrl']);
|
||||
if (await canLaunchUrl(url)) {
|
||||
await launchUrl(url, mode: LaunchMode.externalApplication);
|
||||
}
|
||||
if (dialogContext.mounted) Navigator.pop(dialogContext);
|
||||
},
|
||||
child: Text(t.update.viewRelease),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
@@ -671,6 +690,15 @@ class _MainScreenState extends State<MainScreen> with RouteAware, WindowListener
|
||||
}
|
||||
});
|
||||
}
|
||||
// When content regains focus while on Live TV, focus the active guide/whats-on tab
|
||||
final liveTvIndex = NavigationTab.indexFor(NavigationTabId.liveTv, isOffline: _isOffline, hasLiveTv: _hasLiveTv);
|
||||
if (_currentIndex == liveTvIndex && liveTvIndex >= 0) {
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||
if (_liveTvKey.currentState case final FocusableTab focusable) {
|
||||
focusable.focusActiveTabIfReady();
|
||||
}
|
||||
});
|
||||
}
|
||||
// When content regains focus while on Settings, restore focus to last focused setting
|
||||
final settingsIndex = NavigationTab.indexFor(
|
||||
NavigationTabId.settings,
|
||||
@@ -876,6 +904,13 @@ class _MainScreenState extends State<MainScreen> with RouteAware, WindowListener
|
||||
focusable.focusActiveTabIfReady();
|
||||
}
|
||||
}
|
||||
// Ensure the Live TV screen applies focus when brought into view
|
||||
final liveTvIdx = NavigationTab.indexFor(NavigationTabId.liveTv, isOffline: _isOffline, hasLiveTv: _hasLiveTv);
|
||||
if (index == liveTvIdx && liveTvIdx >= 0 && previousIndex != liveTvIdx) {
|
||||
if (_liveTvKey.currentState case final FocusableTab focusable) {
|
||||
focusable.focusActiveTabIfReady();
|
||||
}
|
||||
}
|
||||
// Focus search input when selecting Search tab
|
||||
if (NavigationTab.isTabAtIndex(NavigationTabId.search, index, isOffline: _isOffline, hasLiveTv: _hasLiveTv)) {
|
||||
if (_searchKey.currentState case final SearchInputFocusable searchable) {
|
||||
|
||||
@@ -10,6 +10,7 @@ import 'package:plezy/widgets/app_icon.dart';
|
||||
import 'package:material_symbols_icons/symbols.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import '../widgets/collapsible_text.dart';
|
||||
import '../widgets/rating_bottom_sheet.dart';
|
||||
|
||||
import '../focus/dpad_navigator.dart';
|
||||
import '../focus/focusable_wrapper.dart';
|
||||
@@ -46,6 +47,7 @@ import '../mixins/watch_state_aware.dart';
|
||||
import '../mixins/deletion_aware.dart';
|
||||
import '../utils/watch_state_notifier.dart';
|
||||
import '../utils/deletion_notifier.dart';
|
||||
import 'metadata_edit_screen.dart';
|
||||
import 'season_detail_screen.dart';
|
||||
|
||||
class MediaDetailScreen extends StatefulWidget {
|
||||
@@ -75,6 +77,7 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
int _focusedSeasonIndex = 0;
|
||||
late final FocusNode _seasonsFocusNode;
|
||||
late final FocusNode _playButtonFocusNode;
|
||||
late final FocusNode _ratingChipFocusNode;
|
||||
Timer? _selectKeyTimer;
|
||||
bool _isSelectKeyDown = false;
|
||||
bool _longPressTriggered = false;
|
||||
@@ -98,6 +101,7 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
late final FocusNode _castFocusNode;
|
||||
final ScrollController _castScrollController = ScrollController();
|
||||
final _castSectionKey = GlobalKey();
|
||||
final _seasonsSectionKey = GlobalKey();
|
||||
|
||||
String _toGlobalKey(String ratingKey, {String? serverId}) =>
|
||||
'${serverId ?? widget.metadata.serverId ?? ''}:$ratingKey';
|
||||
@@ -255,6 +259,7 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
_seasonsFocusNode = FocusNode(debugLabel: 'seasons_row');
|
||||
_extrasFocusNode = FocusNode(debugLabel: 'extras_row');
|
||||
_playButtonFocusNode = FocusNode(debugLabel: 'play_button');
|
||||
_ratingChipFocusNode = FocusNode(debugLabel: 'rating_chip');
|
||||
_overviewFocusNode = FocusNode(debugLabel: 'overview');
|
||||
_castFocusNode = FocusNode(debugLabel: 'cast_row');
|
||||
_loadFullMetadata();
|
||||
@@ -274,6 +279,7 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
_seasonsFocusNode.dispose();
|
||||
_extrasFocusNode.dispose();
|
||||
_playButtonFocusNode.dispose();
|
||||
_ratingChipFocusNode.dispose();
|
||||
_overviewFocusNode.dispose();
|
||||
_castFocusNode.dispose();
|
||||
_castScrollController.dispose();
|
||||
@@ -698,6 +704,25 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
iconSize: 20,
|
||||
style: IconButton.styleFrom(minimumSize: const Size(48, 48), maximumSize: const Size(48, 48)),
|
||||
),
|
||||
// Edit metadata button (hidden in offline mode)
|
||||
if (!widget.isOffline) ...[
|
||||
const SizedBox(width: 12),
|
||||
IconButton.filledTonal(
|
||||
onPressed: () async {
|
||||
final result = await Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(builder: (context) => MetadataEditScreen(metadata: metadata)),
|
||||
);
|
||||
if (result == true && mounted) {
|
||||
_loadFullMetadata();
|
||||
}
|
||||
},
|
||||
icon: const AppIcon(Symbols.edit_rounded, fill: 1),
|
||||
tooltip: t.metadataEdit.editMetadata,
|
||||
iconSize: 20,
|
||||
style: IconButton.styleFrom(minimumSize: const Size(48, 48), maximumSize: const Size(48, 48)),
|
||||
),
|
||||
],
|
||||
],
|
||||
),
|
||||
);
|
||||
@@ -771,9 +796,97 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
chips.add(_buildRatingChip(metadata.audienceRatingImage, metadata.audienceRating!, Symbols.people_rounded));
|
||||
}
|
||||
}
|
||||
|
||||
// User rating chip (tappable)
|
||||
if (!widget.isOffline) {
|
||||
chips.add(_buildUserRatingChip(metadata));
|
||||
}
|
||||
|
||||
return chips;
|
||||
}
|
||||
|
||||
Widget _buildUserRatingChip(PlexMetadata metadata) {
|
||||
final hasRating = metadata.userRating != null && metadata.userRating! > 0;
|
||||
final starValue = hasRating ? metadata.userRating! / 2.0 : 0.0;
|
||||
|
||||
return FocusableWrapper(
|
||||
focusNode: _ratingChipFocusNode,
|
||||
onSelect: () => _showRatingDialog(metadata, starValue),
|
||||
borderRadius: 100,
|
||||
useBackgroundFocus: true,
|
||||
onKeyEvent: (_, event) {
|
||||
if (!event.isActionable) return KeyEventResult.ignored;
|
||||
final key = event.logicalKey;
|
||||
if (key.isDownKey) {
|
||||
_playButtonFocusNode.requestFocus();
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
if (key.isUpKey) {
|
||||
return KeyEventResult.handled; // consume — nothing above
|
||||
}
|
||||
return KeyEventResult.ignored;
|
||||
},
|
||||
child: GestureDetector(
|
||||
onTap: () => _showRatingDialog(metadata, starValue),
|
||||
child: Container(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 6),
|
||||
decoration: BoxDecoration(
|
||||
color: Theme.of(context).colorScheme.secondaryContainer.withValues(alpha: 0.8),
|
||||
borderRadius: const BorderRadius.all(Radius.circular(100)),
|
||||
),
|
||||
child: Row(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
AppIcon(
|
||||
Symbols.star_rounded,
|
||||
fill: hasRating ? 1 : 0,
|
||||
color: hasRating
|
||||
? Colors.amber
|
||||
: Theme.of(context).colorScheme.onSecondaryContainer,
|
||||
size: 16,
|
||||
),
|
||||
const SizedBox(width: 4),
|
||||
Text(
|
||||
hasRating
|
||||
? (starValue == starValue.truncateToDouble()
|
||||
? '${starValue.toInt()}'
|
||||
: starValue.toStringAsFixed(1))
|
||||
: t.mediaMenu.rate,
|
||||
style: TextStyle(
|
||||
color: Theme.of(context).colorScheme.onSecondaryContainer,
|
||||
fontSize: 13,
|
||||
fontWeight: FontWeight.w500,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
void _showRatingDialog(PlexMetadata metadata, double currentStarValue) {
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
builder: (context) => RatingBottomSheet(
|
||||
currentRating: currentStarValue,
|
||||
onRate: (stars) async {
|
||||
final client = _getClientForMetadata(this.context);
|
||||
if (client == null) return;
|
||||
final plexRating = stars * 2.0; // Convert 0-5 stars to 0-10 scale
|
||||
final success = await client.rateItem(metadata.ratingKey, plexRating);
|
||||
if (success) _updateWatchState();
|
||||
},
|
||||
onClear: () async {
|
||||
final client = _getClientForMetadata(this.context);
|
||||
if (client == null) return;
|
||||
final success = await client.rateItem(metadata.ratingKey, -1);
|
||||
if (success) _updateWatchState();
|
||||
},
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
/// Build a combined RT chip showing critic + audience side by side.
|
||||
Widget _buildCombinedRtChip(RatingInfo critic, RatingInfo audience) {
|
||||
final textStyle = TextStyle(
|
||||
@@ -1035,23 +1148,33 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
KeyEventResult _handlePlayButtonKeyEvent(FocusNode _, KeyEvent event) {
|
||||
final key = event.logicalKey;
|
||||
if (!event.isActionable) return KeyEventResult.ignored;
|
||||
|
||||
// UP: focus the rating chip if available
|
||||
if (key.isUpKey) {
|
||||
if (!widget.isOffline) {
|
||||
_ratingChipFocusNode.requestFocus();
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
if (!key.isDownKey) return KeyEventResult.ignored;
|
||||
|
||||
final metadata = _fullMetadata ?? widget.metadata;
|
||||
|
||||
// For shows, go to seasons first
|
||||
if (metadata.isShow && _seasons.isNotEmpty) {
|
||||
_seasonsFocusNode.requestFocus();
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
// For movies (or shows with no seasons): overview → cast → extras
|
||||
// DOWN order: overview → seasons → cast → extras
|
||||
if (metadata.summary != null) {
|
||||
_overviewFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_overviewSectionKey);
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
if (metadata.isShow && _seasons.isNotEmpty) {
|
||||
_seasonsFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_seasonsSectionKey);
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
if (metadata.role != null && metadata.role!.isNotEmpty) {
|
||||
_castFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_castSectionKey);
|
||||
@@ -1145,20 +1268,23 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
// UP: scroll to top and focus play button
|
||||
// UP: overview → play button
|
||||
if (key.isUpKey) {
|
||||
_scrollController.animateTo(0, duration: const Duration(milliseconds: 200), curve: Curves.easeOut);
|
||||
_playButtonFocusNode.requestFocus();
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
// DOWN: overview → cast → extras (first that exists)
|
||||
if (key.isDownKey) {
|
||||
final metadata = _fullMetadata ?? widget.metadata;
|
||||
if (metadata.summary != null) {
|
||||
_overviewFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_overviewSectionKey);
|
||||
} else if (metadata.role != null && metadata.role!.isNotEmpty) {
|
||||
} else {
|
||||
_scrollController.animateTo(0, duration: const Duration(milliseconds: 200), curve: Curves.easeOut);
|
||||
_playButtonFocusNode.requestFocus();
|
||||
}
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
// DOWN: cast → extras
|
||||
if (key.isDownKey) {
|
||||
final metadata = _fullMetadata ?? widget.metadata;
|
||||
if (metadata.role != null && metadata.role!.isNotEmpty) {
|
||||
_castFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_castSectionKey);
|
||||
} else if (_extras != null && _extras!.isNotEmpty) {
|
||||
@@ -1179,20 +1305,19 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
|
||||
final metadata = _fullMetadata ?? widget.metadata;
|
||||
|
||||
// UP: seasons (if show) or play button
|
||||
// UP: always play button (overview is directly below play)
|
||||
if (key.isUpKey) {
|
||||
if (metadata.isShow && _seasons.isNotEmpty) {
|
||||
_seasonsFocusNode.requestFocus();
|
||||
} else {
|
||||
_scrollController.animateTo(0, duration: const Duration(milliseconds: 200), curve: Curves.easeOut);
|
||||
_playButtonFocusNode.requestFocus();
|
||||
}
|
||||
_scrollController.animateTo(0, duration: const Duration(milliseconds: 200), curve: Curves.easeOut);
|
||||
_playButtonFocusNode.requestFocus();
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
// DOWN: cast → extras → consume
|
||||
// DOWN: seasons (if show) → cast → extras
|
||||
if (key.isDownKey) {
|
||||
if (metadata.role != null && metadata.role!.isNotEmpty) {
|
||||
if (metadata.isShow && _seasons.isNotEmpty) {
|
||||
_seasonsFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_seasonsSectionKey);
|
||||
} else if (metadata.role != null && metadata.role!.isNotEmpty) {
|
||||
_castFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_castSectionKey);
|
||||
} else if (_extras != null && _extras!.isNotEmpty) {
|
||||
@@ -1330,17 +1455,18 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
// UP: cast → overview → seasons → play button (first that exists)
|
||||
// UP: cast → seasons (if show) → overview → play button
|
||||
if (key.isUpKey) {
|
||||
final metadata = _fullMetadata ?? widget.metadata;
|
||||
if (metadata.role != null && metadata.role!.isNotEmpty) {
|
||||
_castFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_castSectionKey);
|
||||
} else if (metadata.isShow && _seasons.isNotEmpty) {
|
||||
_seasonsFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_seasonsSectionKey);
|
||||
} else if (metadata.summary != null) {
|
||||
_overviewFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_overviewSectionKey);
|
||||
} else if (_seasons.isNotEmpty) {
|
||||
_seasonsFocusNode.requestFocus();
|
||||
} else {
|
||||
_scrollController.animateTo(0, duration: const Duration(milliseconds: 200), curve: Curves.easeOut);
|
||||
_playButtonFocusNode.requestFocus();
|
||||
@@ -1383,13 +1509,14 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
|
||||
// UP: overview → seasons (if show) → play button
|
||||
// UP: seasons (if show) → overview → play button
|
||||
if (key.isUpKey) {
|
||||
if (metadata.summary != null) {
|
||||
if (metadata.isShow && _seasons.isNotEmpty) {
|
||||
_seasonsFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_seasonsSectionKey);
|
||||
} else if (metadata.summary != null) {
|
||||
_overviewFocusNode.requestFocus();
|
||||
_scrollSectionIntoView(_overviewSectionKey);
|
||||
} else if (metadata.isShow && _seasons.isNotEmpty) {
|
||||
_seasonsFocusNode.requestFocus();
|
||||
} else {
|
||||
_scrollController.animateTo(0, duration: const Duration(milliseconds: 200), curve: Curves.easeOut);
|
||||
_playButtonFocusNode.requestFocus();
|
||||
@@ -1755,12 +1882,12 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
imageType: ImageType.art,
|
||||
);
|
||||
|
||||
return CachedNetworkImage(
|
||||
return blurArtwork(CachedNetworkImage(
|
||||
imageUrl: imageUrl,
|
||||
fit: BoxFit.cover,
|
||||
placeholder: (context, url) => const PlaceholderContainer(),
|
||||
errorWidget: (context, url, error) => const PlaceholderContainer(),
|
||||
);
|
||||
));
|
||||
},
|
||||
)
|
||||
: const PlaceholderContainer(),
|
||||
@@ -1839,7 +1966,7 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
imageType: ImageType.logo,
|
||||
);
|
||||
|
||||
return CachedNetworkImage(
|
||||
return blurArtwork(CachedNetworkImage(
|
||||
imageUrl: logoUrl,
|
||||
filterQuality: FilterQuality.medium,
|
||||
fit: BoxFit.contain,
|
||||
@@ -1863,7 +1990,7 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
errorWidget: (context, url, error) {
|
||||
return _buildTitleText(context, metadata.title);
|
||||
},
|
||||
);
|
||||
), sigma: 10, clip: false);
|
||||
},
|
||||
),
|
||||
)
|
||||
@@ -1960,6 +2087,7 @@ class _MediaDetailScreenState extends State<MediaDetailScreen> with WatchStateAw
|
||||
// Seasons (for TV shows)
|
||||
if (isShow) ...[
|
||||
Text(
|
||||
key: _seasonsSectionKey,
|
||||
t.discover.seasons,
|
||||
style: Theme.of(context).textTheme.titleLarge?.copyWith(fontWeight: FontWeight.bold),
|
||||
),
|
||||
@@ -2380,6 +2508,22 @@ class _SeasonCardState extends State<_SeasonCard> {
|
||||
t.discover.episodeCount(count: widget.season.leafCount.toString()),
|
||||
style: Theme.of(context).textTheme.bodyMedium?.copyWith(color: Colors.grey),
|
||||
),
|
||||
if (widget.season.userRating != null && widget.season.userRating! > 0) ...[
|
||||
const SizedBox(height: 4),
|
||||
Row(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
const Padding(padding: EdgeInsets.only(top: 2), child: Icon(Symbols.star_rounded, size: 14, fill: 1, color: Colors.amber)),
|
||||
const SizedBox(width: 3),
|
||||
Text(
|
||||
(widget.season.userRating! / 2) == (widget.season.userRating! / 2).truncateToDouble()
|
||||
? '${(widget.season.userRating! / 2).toInt()}'
|
||||
: (widget.season.userRating! / 2).toStringAsFixed(1),
|
||||
style: Theme.of(context).textTheme.bodySmall?.copyWith(color: Colors.grey),
|
||||
),
|
||||
],
|
||||
),
|
||||
],
|
||||
// Hide watch progress when offline (not tracked)
|
||||
if (!widget.isOffline) ...[
|
||||
const SizedBox(height: 8),
|
||||
@@ -2467,3 +2611,4 @@ class _SeasonCardState extends State<_SeasonCard> {
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,717 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:material_symbols_icons/symbols.dart';
|
||||
import '../focus/focusable_button.dart';
|
||||
import '../i18n/strings.g.dart';
|
||||
import '../models/plex_metadata.dart';
|
||||
import '../services/plex_client.dart';
|
||||
import '../utils/dialogs.dart';
|
||||
import '../utils/language_codes.dart';
|
||||
import '../utils/provider_extensions.dart';
|
||||
import '../utils/snackbar_helper.dart';
|
||||
import '../widgets/app_icon.dart';
|
||||
import '../widgets/artwork_picker_dialog.dart';
|
||||
import '../widgets/focusable_list_tile.dart';
|
||||
import '../widgets/focused_scroll_scaffold.dart';
|
||||
import '../widgets/plex_optimized_image.dart';
|
||||
|
||||
class MetadataEditScreen extends StatefulWidget {
|
||||
final PlexMetadata metadata;
|
||||
|
||||
const MetadataEditScreen({super.key, required this.metadata});
|
||||
|
||||
@override
|
||||
State<MetadataEditScreen> createState() => _MetadataEditScreenState();
|
||||
}
|
||||
|
||||
class _MetadataEditScreenState extends State<MetadataEditScreen> {
|
||||
late PlexClient _client;
|
||||
PlexMetadata? _fullMetadata;
|
||||
bool _isLoading = true;
|
||||
bool _isSaving = false;
|
||||
|
||||
// Text field values
|
||||
String? _title;
|
||||
String? _titleSort;
|
||||
String? _originalTitle;
|
||||
String? _originallyAvailableAt;
|
||||
String? _contentRating;
|
||||
String? _studio;
|
||||
String? _tagline;
|
||||
String? _summary;
|
||||
|
||||
// Original values for change detection
|
||||
String? _origTitle;
|
||||
String? _origTitleSort;
|
||||
String? _origOriginalTitle;
|
||||
String? _origOriginallyAvailableAt;
|
||||
String? _origContentRating;
|
||||
String? _origStudio;
|
||||
String? _origTagline;
|
||||
String? _origSummary;
|
||||
|
||||
// Advanced prefs (loaded from metadata JSON)
|
||||
final Map<String, String> _currentPrefs = {};
|
||||
|
||||
bool get _hasChanges =>
|
||||
_title != _origTitle ||
|
||||
_titleSort != _origTitleSort ||
|
||||
_originalTitle != _origOriginalTitle ||
|
||||
_originallyAvailableAt != _origOriginallyAvailableAt ||
|
||||
_contentRating != _origContentRating ||
|
||||
_studio != _origStudio ||
|
||||
_tagline != _origTagline ||
|
||||
_summary != _origSummary;
|
||||
|
||||
PlexMediaType get _mediaType => widget.metadata.mediaType;
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
_client = context.getClientWithFallback(widget.metadata.serverId);
|
||||
_loadMetadata();
|
||||
}
|
||||
|
||||
Future<void> _loadMetadata() async {
|
||||
try {
|
||||
final meta = await _client.getMetadataWithImages(widget.metadata.ratingKey);
|
||||
if (!mounted) return;
|
||||
if (meta != null) {
|
||||
_fullMetadata = meta;
|
||||
_initFieldsFromMetadata(meta);
|
||||
} else {
|
||||
_initFieldsFromMetadata(widget.metadata);
|
||||
}
|
||||
setState(() => _isLoading = false);
|
||||
} catch (e) {
|
||||
if (!mounted) return;
|
||||
_initFieldsFromMetadata(widget.metadata);
|
||||
setState(() => _isLoading = false);
|
||||
}
|
||||
}
|
||||
|
||||
void _initFieldsFromMetadata(PlexMetadata meta) {
|
||||
_title = meta.title;
|
||||
_titleSort = meta.titleSort ?? '';
|
||||
_originalTitle = meta.originalTitle ?? '';
|
||||
_originallyAvailableAt = meta.originallyAvailableAt ?? '';
|
||||
_contentRating = meta.contentRating ?? '';
|
||||
_studio = meta.studio ?? '';
|
||||
_tagline = meta.tagline ?? '';
|
||||
_summary = meta.summary ?? '';
|
||||
|
||||
_origTitle = _title;
|
||||
_origTitleSort = _titleSort;
|
||||
_origOriginalTitle = _originalTitle;
|
||||
_origOriginallyAvailableAt = _originallyAvailableAt;
|
||||
_origContentRating = _contentRating;
|
||||
_origStudio = _studio;
|
||||
_origTagline = _tagline;
|
||||
_origSummary = _summary;
|
||||
}
|
||||
|
||||
Future<void> _save() async {
|
||||
if (!_hasChanges || _isSaving) return;
|
||||
|
||||
final sectionId = _fullMetadata?.librarySectionID ?? widget.metadata.librarySectionID;
|
||||
if (sectionId == null) {
|
||||
if (mounted) showErrorSnackBar(context, t.metadataEdit.metadataUpdateFailed);
|
||||
return;
|
||||
}
|
||||
|
||||
setState(() => _isSaving = true);
|
||||
|
||||
final success = await _client.updateMetadata(
|
||||
sectionId: sectionId,
|
||||
ratingKey: widget.metadata.ratingKey,
|
||||
typeNumber: _mediaType.typeNumber,
|
||||
title: _title != _origTitle ? _title : null,
|
||||
titleSort: _titleSort != _origTitleSort ? _titleSort : null,
|
||||
originalTitle: _originalTitle != _origOriginalTitle ? _originalTitle : null,
|
||||
originallyAvailableAt: _originallyAvailableAt != _origOriginallyAvailableAt ? _originallyAvailableAt : null,
|
||||
contentRating: _contentRating != _origContentRating ? _contentRating : null,
|
||||
studio: _studio != _origStudio ? _studio : null,
|
||||
tagline: _tagline != _origTagline ? _tagline : null,
|
||||
summary: _summary != _origSummary ? _summary : null,
|
||||
);
|
||||
|
||||
if (!mounted) return;
|
||||
setState(() => _isSaving = false);
|
||||
|
||||
if (success) {
|
||||
showSuccessSnackBar(context, t.metadataEdit.metadataUpdated);
|
||||
Navigator.pop(context, true);
|
||||
} else {
|
||||
showErrorSnackBar(context, t.metadataEdit.metadataUpdateFailed);
|
||||
}
|
||||
}
|
||||
|
||||
Future<void> _editTextField({
|
||||
required String title,
|
||||
required String label,
|
||||
required String? currentValue,
|
||||
required ValueChanged<String> onChanged,
|
||||
bool multiline = false,
|
||||
}) async {
|
||||
final String? result;
|
||||
if (multiline) {
|
||||
result = await showMultilineTextInputDialog(
|
||||
context,
|
||||
title: title,
|
||||
labelText: label,
|
||||
initialValue: currentValue,
|
||||
);
|
||||
} else {
|
||||
result = await showTextInputDialog(
|
||||
context,
|
||||
title: title,
|
||||
labelText: label,
|
||||
hintText: '',
|
||||
initialValue: currentValue,
|
||||
);
|
||||
}
|
||||
|
||||
if (result != null && mounted) {
|
||||
final value = result;
|
||||
setState(() => onChanged(value));
|
||||
}
|
||||
}
|
||||
|
||||
Future<void> _editDate() async {
|
||||
DateTime initial = DateTime.now();
|
||||
if (_originallyAvailableAt != null && _originallyAvailableAt!.isNotEmpty) {
|
||||
final parsed = DateTime.tryParse(_originallyAvailableAt!);
|
||||
if (parsed != null) initial = parsed;
|
||||
}
|
||||
|
||||
final picked = await showDatePicker(
|
||||
context: context,
|
||||
initialDate: initial,
|
||||
firstDate: DateTime(1800),
|
||||
lastDate: DateTime(2200),
|
||||
);
|
||||
|
||||
if (picked != null && mounted) {
|
||||
setState(() {
|
||||
_originallyAvailableAt =
|
||||
'${picked.year}-${picked.month.toString().padLeft(2, '0')}-${picked.day.toString().padLeft(2, '0')}';
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Future<void> _openArtworkPicker(String element) async {
|
||||
final result = await showDialog<bool>(
|
||||
context: context,
|
||||
builder: (context) => ArtworkPickerDialog(
|
||||
client: _client,
|
||||
ratingKey: widget.metadata.ratingKey,
|
||||
element: element,
|
||||
),
|
||||
);
|
||||
|
||||
if (result == true && mounted) {
|
||||
// Reload metadata to get updated artwork paths
|
||||
_loadMetadata();
|
||||
}
|
||||
}
|
||||
|
||||
Future<void> _showAdvancedSettingDialog({
|
||||
required String title,
|
||||
required String prefKey,
|
||||
required List<({String value, String label})> options,
|
||||
}) async {
|
||||
// Determine current value from metadata or default
|
||||
final currentValue = _currentPrefs[prefKey] ?? _getMetadataPrefValue(prefKey);
|
||||
|
||||
final result = await showDialog<String>(
|
||||
context: context,
|
||||
builder: (dialogContext) {
|
||||
String? selected = currentValue;
|
||||
return StatefulBuilder(
|
||||
builder: (context, setDialogState) {
|
||||
return AlertDialog(
|
||||
title: Text(title),
|
||||
content: SizedBox(
|
||||
width: double.maxFinite,
|
||||
child: ListView(
|
||||
shrinkWrap: true,
|
||||
children: options.map((option) {
|
||||
return FocusableRadioListTile<String>(
|
||||
title: Text(option.label),
|
||||
value: option.value,
|
||||
groupValue: selected,
|
||||
onChanged: (val) {
|
||||
setDialogState(() => selected = val);
|
||||
Navigator.pop(dialogContext, val);
|
||||
},
|
||||
);
|
||||
}).toList(),
|
||||
),
|
||||
),
|
||||
actions: [
|
||||
FocusableButton(
|
||||
autofocus: true,
|
||||
onPressed: () => Navigator.pop(dialogContext),
|
||||
child: TextButton(
|
||||
onPressed: () => Navigator.pop(dialogContext),
|
||||
child: Text(t.common.cancel),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
},
|
||||
);
|
||||
},
|
||||
);
|
||||
|
||||
if (result != null && mounted) {
|
||||
setState(() => _currentPrefs[prefKey] = result);
|
||||
await _client.updateMetadataPrefs(widget.metadata.ratingKey, {prefKey: result});
|
||||
}
|
||||
}
|
||||
|
||||
String _getMetadataPrefValue(String key) {
|
||||
// These prefs appear as keys on the raw metadata JSON when non-default.
|
||||
// Since we use typed models, we check known fields.
|
||||
final meta = _fullMetadata ?? widget.metadata;
|
||||
switch (key) {
|
||||
case 'audioLanguage':
|
||||
return meta.audioLanguage ?? '';
|
||||
case 'subtitleLanguage':
|
||||
return meta.subtitleLanguage ?? '';
|
||||
default:
|
||||
return '';
|
||||
}
|
||||
}
|
||||
|
||||
String _getDisplayValueForPref(String prefKey, List<({String value, String label})> options) {
|
||||
final val = _currentPrefs[prefKey] ?? _getMetadataPrefValue(prefKey);
|
||||
for (final option in options) {
|
||||
if (option.value == val) return option.label;
|
||||
}
|
||||
return options.first.label;
|
||||
}
|
||||
|
||||
// ===== Field visibility =====
|
||||
|
||||
bool get _showSortTitle => _mediaType != PlexMediaType.season;
|
||||
bool get _showOriginalTitle => _mediaType == PlexMediaType.movie || _mediaType == PlexMediaType.show;
|
||||
bool get _showReleaseDate => _mediaType != PlexMediaType.season;
|
||||
bool get _showContentRating => _mediaType != PlexMediaType.season;
|
||||
bool get _showStudio => _mediaType == PlexMediaType.movie || _mediaType == PlexMediaType.show;
|
||||
bool get _showTagline => _mediaType == PlexMediaType.movie || _mediaType == PlexMediaType.show;
|
||||
bool get _showBackground =>
|
||||
_mediaType == PlexMediaType.movie || _mediaType == PlexMediaType.show || _mediaType == PlexMediaType.episode;
|
||||
bool get _showAdvanced => _mediaType != PlexMediaType.episode;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
if (_isLoading) {
|
||||
return FocusedScrollScaffold(
|
||||
title: Text(t.metadataEdit.screenTitle),
|
||||
slivers: [const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))],
|
||||
);
|
||||
}
|
||||
|
||||
return FocusedScrollScaffold(
|
||||
title: Text(t.metadataEdit.screenTitle),
|
||||
actions: [
|
||||
if (_isSaving)
|
||||
const Padding(
|
||||
padding: EdgeInsets.all(12),
|
||||
child: SizedBox(width: 24, height: 24, child: CircularProgressIndicator(strokeWidth: 2)),
|
||||
)
|
||||
else
|
||||
IconButton(
|
||||
onPressed: _hasChanges ? _save : null,
|
||||
icon: const AppIcon(Symbols.check_rounded, fill: 1),
|
||||
),
|
||||
],
|
||||
slivers: [
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
sliver: SliverList(
|
||||
delegate: SliverChildListDelegate([
|
||||
_buildBasicInfoCard(),
|
||||
const SizedBox(height: 16),
|
||||
_buildArtworkCard(),
|
||||
if (_showAdvanced) ...[
|
||||
const SizedBox(height: 16),
|
||||
_buildAdvancedSettingsCard(),
|
||||
],
|
||||
]),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
Widget _buildBasicInfoCard() {
|
||||
return Card(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: Text(
|
||||
t.metadataEdit.basicInfo,
|
||||
style: Theme.of(context).textTheme.titleMedium?.copyWith(fontWeight: FontWeight.bold),
|
||||
),
|
||||
),
|
||||
_buildFieldTile(
|
||||
label: t.metadataEdit.title,
|
||||
value: _title,
|
||||
onTap: () => _editTextField(
|
||||
title: t.metadataEdit.title,
|
||||
label: t.metadataEdit.title,
|
||||
currentValue: _title,
|
||||
onChanged: (v) => _title = v,
|
||||
),
|
||||
),
|
||||
if (_showSortTitle)
|
||||
_buildFieldTile(
|
||||
label: t.metadataEdit.sortTitle,
|
||||
value: _titleSort,
|
||||
onTap: () => _editTextField(
|
||||
title: t.metadataEdit.sortTitle,
|
||||
label: t.metadataEdit.sortTitle,
|
||||
currentValue: _titleSort,
|
||||
onChanged: (v) => _titleSort = v,
|
||||
),
|
||||
),
|
||||
if (_showOriginalTitle)
|
||||
_buildFieldTile(
|
||||
label: t.metadataEdit.originalTitle,
|
||||
value: _originalTitle,
|
||||
onTap: () => _editTextField(
|
||||
title: t.metadataEdit.originalTitle,
|
||||
label: t.metadataEdit.originalTitle,
|
||||
currentValue: _originalTitle,
|
||||
onChanged: (v) => _originalTitle = v,
|
||||
),
|
||||
),
|
||||
if (_showReleaseDate)
|
||||
_buildFieldTile(
|
||||
label: t.metadataEdit.releaseDate,
|
||||
value: _originallyAvailableAt,
|
||||
onTap: _editDate,
|
||||
),
|
||||
if (_showContentRating)
|
||||
_buildFieldTile(
|
||||
label: t.metadataEdit.contentRating,
|
||||
value: _contentRating,
|
||||
onTap: () => _editTextField(
|
||||
title: t.metadataEdit.contentRating,
|
||||
label: t.metadataEdit.contentRating,
|
||||
currentValue: _contentRating,
|
||||
onChanged: (v) => _contentRating = v,
|
||||
),
|
||||
),
|
||||
if (_showStudio)
|
||||
_buildFieldTile(
|
||||
label: t.metadataEdit.studio,
|
||||
value: _studio,
|
||||
onTap: () => _editTextField(
|
||||
title: t.metadataEdit.studio,
|
||||
label: t.metadataEdit.studio,
|
||||
currentValue: _studio,
|
||||
onChanged: (v) => _studio = v,
|
||||
),
|
||||
),
|
||||
if (_showTagline)
|
||||
_buildFieldTile(
|
||||
label: t.metadataEdit.tagline,
|
||||
value: _tagline,
|
||||
onTap: () => _editTextField(
|
||||
title: t.metadataEdit.tagline,
|
||||
label: t.metadataEdit.tagline,
|
||||
currentValue: _tagline,
|
||||
onChanged: (v) => _tagline = v,
|
||||
),
|
||||
),
|
||||
_buildFieldTile(
|
||||
label: t.metadataEdit.summary,
|
||||
value: _summary,
|
||||
onTap: () => _editTextField(
|
||||
title: t.metadataEdit.summary,
|
||||
label: t.metadataEdit.summary,
|
||||
currentValue: _summary,
|
||||
onChanged: (v) => _summary = v,
|
||||
multiline: true,
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Widget _buildFieldTile({required String label, String? value, required VoidCallback onTap}) {
|
||||
final displayValue = (value == null || value.isEmpty) ? t.metadataEdit.notSet : value;
|
||||
final isNotSet = value == null || value.isEmpty;
|
||||
|
||||
return ListTile(
|
||||
title: Text(label),
|
||||
subtitle: Text(
|
||||
displayValue,
|
||||
maxLines: 2,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
style: isNotSet ? TextStyle(color: Theme.of(context).colorScheme.onSurfaceVariant.withValues(alpha: 0.5)) : null,
|
||||
),
|
||||
trailing: const AppIcon(Symbols.chevron_right_rounded),
|
||||
onTap: onTap,
|
||||
);
|
||||
}
|
||||
|
||||
Widget _buildArtworkCard() {
|
||||
final meta = _fullMetadata ?? widget.metadata;
|
||||
|
||||
return Card(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: Text(
|
||||
t.metadataEdit.artwork,
|
||||
style: Theme.of(context).textTheme.titleMedium?.copyWith(fontWeight: FontWeight.bold),
|
||||
),
|
||||
),
|
||||
ListTile(
|
||||
leading: SizedBox(
|
||||
width: 40,
|
||||
height: 60,
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(4),
|
||||
child: PlexOptimizedImage(
|
||||
client: _client,
|
||||
imagePath: meta.thumb,
|
||||
width: 40,
|
||||
height: 60,
|
||||
fit: BoxFit.cover,
|
||||
),
|
||||
),
|
||||
),
|
||||
title: Text(t.metadataEdit.poster),
|
||||
trailing: const AppIcon(Symbols.chevron_right_rounded),
|
||||
onTap: () => _openArtworkPicker('posters'),
|
||||
),
|
||||
if (_showBackground)
|
||||
ListTile(
|
||||
leading: SizedBox(
|
||||
width: 80,
|
||||
height: 45,
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.circular(4),
|
||||
child: PlexOptimizedImage(
|
||||
client: _client,
|
||||
imagePath: meta.art,
|
||||
width: 80,
|
||||
height: 45,
|
||||
fit: BoxFit.cover,
|
||||
),
|
||||
),
|
||||
),
|
||||
title: Text(t.metadataEdit.background),
|
||||
trailing: const AppIcon(Symbols.chevron_right_rounded),
|
||||
onTap: () => _openArtworkPicker('arts'),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Widget _buildAdvancedSettingsCard() {
|
||||
return Card(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: Text(
|
||||
t.metadataEdit.advancedSettings,
|
||||
style: Theme.of(context).textTheme.titleMedium?.copyWith(fontWeight: FontWeight.bold),
|
||||
),
|
||||
),
|
||||
if (_mediaType == PlexMediaType.show) ..._buildShowAdvancedSettings(),
|
||||
if (_mediaType == PlexMediaType.movie) ..._buildMovieAdvancedSettings(),
|
||||
if (_mediaType == PlexMediaType.season) ..._buildSeasonAdvancedSettings(),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
List<Widget> _buildShowAdvancedSettings() {
|
||||
return [
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.episodeSorting,
|
||||
prefKey: 'episodeSort',
|
||||
options: [
|
||||
(value: '-1', label: t.metadataEdit.libraryDefault),
|
||||
(value: '0', label: t.metadataEdit.oldestFirst),
|
||||
(value: '1', label: t.metadataEdit.newestFirst),
|
||||
],
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.keep,
|
||||
prefKey: 'autoDeletionItemPolicyUnwatchedLibrary',
|
||||
options: [
|
||||
(value: '0', label: t.metadataEdit.allEpisodes),
|
||||
(value: '5', label: t.metadataEdit.latestEpisodes(count: '5')),
|
||||
(value: '3', label: t.metadataEdit.latestEpisodes(count: '3')),
|
||||
(value: '1', label: t.metadataEdit.latestEpisode),
|
||||
(value: '-3', label: t.metadataEdit.episodesAddedPastDays(count: '3')),
|
||||
(value: '-7', label: t.metadataEdit.episodesAddedPastDays(count: '7')),
|
||||
(value: '-30', label: t.metadataEdit.episodesAddedPastDays(count: '30')),
|
||||
],
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.deleteAfterPlaying,
|
||||
prefKey: 'autoDeletionItemPolicyWatchedLibrary',
|
||||
options: [
|
||||
(value: '0', label: t.metadataEdit.never),
|
||||
(value: '1', label: t.metadataEdit.afterADay),
|
||||
(value: '7', label: t.metadataEdit.afterAWeek),
|
||||
(value: '30', label: t.metadataEdit.afterAMonth),
|
||||
(value: '100', label: t.metadataEdit.onNextRefresh),
|
||||
],
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.seasons,
|
||||
prefKey: 'flattenSeasons',
|
||||
options: [
|
||||
(value: '-1', label: t.metadataEdit.libraryDefault),
|
||||
(value: '0', label: t.metadataEdit.show),
|
||||
(value: '1', label: t.metadataEdit.hide),
|
||||
],
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.episodeOrdering,
|
||||
prefKey: 'showOrdering',
|
||||
options: [
|
||||
(value: '', label: t.metadataEdit.libraryDefault),
|
||||
(value: 'tmdbAiring', label: t.metadataEdit.tmdbAiring),
|
||||
(value: 'tvdbAiring', label: t.metadataEdit.tvdbAiring),
|
||||
(value: 'tvdbAbsolute', label: t.metadataEdit.tvdbAbsolute),
|
||||
],
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.metadataLanguage,
|
||||
prefKey: 'languageOverride',
|
||||
options: _metadataLanguageOptions(t.metadataEdit.libraryDefault),
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.useOriginalTitle,
|
||||
prefKey: 'useOriginalTitle',
|
||||
options: [
|
||||
(value: '-1', label: t.metadataEdit.libraryDefault),
|
||||
(value: '0', label: t.common.no),
|
||||
(value: '1', label: t.common.yes),
|
||||
],
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.preferredAudioLanguage,
|
||||
prefKey: 'audioLanguage',
|
||||
options: _audioSubtitleLanguageOptions(t.metadataEdit.accountDefault),
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.preferredSubtitleLanguage,
|
||||
prefKey: 'subtitleLanguage',
|
||||
options: _audioSubtitleLanguageOptions(t.metadataEdit.accountDefault),
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.subtitleMode,
|
||||
prefKey: 'subtitleMode',
|
||||
options: [
|
||||
(value: '-1', label: t.metadataEdit.accountDefault),
|
||||
(value: '0', label: t.metadataEdit.manuallySelected),
|
||||
(value: '1', label: t.metadataEdit.shownWithForeignAudio),
|
||||
(value: '2', label: t.metadataEdit.alwaysEnabled),
|
||||
],
|
||||
),
|
||||
];
|
||||
}
|
||||
|
||||
List<Widget> _buildMovieAdvancedSettings() {
|
||||
return [
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.metadataLanguage,
|
||||
prefKey: 'languageOverride',
|
||||
options: _metadataLanguageOptions(t.metadataEdit.libraryDefault),
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.useOriginalTitle,
|
||||
prefKey: 'useOriginalTitle',
|
||||
options: [
|
||||
(value: '-1', label: t.metadataEdit.libraryDefault),
|
||||
(value: '0', label: t.common.no),
|
||||
(value: '1', label: t.common.yes),
|
||||
],
|
||||
),
|
||||
];
|
||||
}
|
||||
|
||||
List<Widget> _buildSeasonAdvancedSettings() {
|
||||
return [
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.preferredAudioLanguage,
|
||||
prefKey: 'audioLanguage',
|
||||
options: _audioSubtitleLanguageOptions(t.metadataEdit.seriesDefault),
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.preferredSubtitleLanguage,
|
||||
prefKey: 'subtitleLanguage',
|
||||
options: _audioSubtitleLanguageOptions(t.metadataEdit.seriesDefault),
|
||||
),
|
||||
_buildAdvancedTile(
|
||||
title: t.metadataEdit.subtitleMode,
|
||||
prefKey: 'subtitleMode',
|
||||
options: [
|
||||
(value: '-1', label: t.metadataEdit.seriesDefault),
|
||||
(value: '0', label: t.metadataEdit.manuallySelected),
|
||||
(value: '1', label: t.metadataEdit.shownWithForeignAudio),
|
||||
(value: '2', label: t.metadataEdit.alwaysEnabled),
|
||||
],
|
||||
),
|
||||
];
|
||||
}
|
||||
|
||||
Widget _buildAdvancedTile({
|
||||
required String title,
|
||||
required String prefKey,
|
||||
required List<({String value, String label})> options,
|
||||
}) {
|
||||
return ListTile(
|
||||
title: Text(title),
|
||||
subtitle: Text(_getDisplayValueForPref(prefKey, options)),
|
||||
trailing: const AppIcon(Symbols.chevron_right_rounded),
|
||||
onTap: () => _showAdvancedSettingDialog(title: title, prefKey: prefKey, options: options),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// ===== Language option lists =====
|
||||
|
||||
// Plex locale codes for metadata agent language.
|
||||
const _plexLocaleCodes = [
|
||||
'ar-SA', 'bg-BG', 'ca-ES', 'zh-CN', 'zh-HK', 'zh-TW', 'hr-HR', 'cs-CZ',
|
||||
'da-DK', 'nl-NL', 'en-US', 'en-AU', 'en-CA', 'en-GB', 'et-EE', 'fi-FI',
|
||||
'fr-FR', 'fr-CA', 'de-DE', 'el-GR', 'he-IL', 'hi-IN', 'hu-HU', 'is-IS',
|
||||
'id-ID', 'it-IT', 'ja-JP', 'ko-KR', 'lv-LV', 'lt-LT', 'nb-NO', 'fa-IR',
|
||||
'pl-PL', 'pt-BR', 'pt-PT', 'ro-RO', 'ru-RU', 'sk-SK', 'es-ES', 'es-MX',
|
||||
'sv-SE', 'th-TH', 'tr-TR', 'uk-UA', 'vi-VN',
|
||||
];
|
||||
|
||||
// Common 2-letter codes shown at the top of audio/subtitle pickers.
|
||||
const _commonAudioSubtitleCodes = ['en', 'ja', 'fr', 'de', 'it', 'es', 'pt', 'ru', 'ar'];
|
||||
|
||||
List<({String value, String label})> _buildLanguageOptions(String defaultLabel, List<String> codes) {
|
||||
return [
|
||||
(value: '', label: defaultLabel),
|
||||
...codes.map((c) => (value: c, label: LanguageCodes.getDisplayName(c))),
|
||||
];
|
||||
}
|
||||
|
||||
List<({String value, String label})> _metadataLanguageOptions(String defaultLabel) =>
|
||||
_buildLanguageOptions(defaultLabel, _plexLocaleCodes);
|
||||
|
||||
List<({String value, String label})> _audioSubtitleLanguageOptions(String defaultLabel) =>
|
||||
_buildLanguageOptions(defaultLabel, [..._commonAudioSubtitleCodes, ..._plexLocaleCodes]);
|
||||
@@ -8,6 +8,7 @@ import '../../focus/dpad_navigator.dart';
|
||||
import '../../focus/focus_theme.dart';
|
||||
import '../../focus/input_mode_tracker.dart';
|
||||
import '../../focus/key_event_utils.dart';
|
||||
import '../../focus/focusable_button.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
import '../../utils/platform_detector.dart';
|
||||
import '../../widgets/app_icon.dart';
|
||||
@@ -100,9 +101,18 @@ class _PinEntryDialogState extends State<PinEntryDialog> with SingleTickerProvid
|
||||
],
|
||||
),
|
||||
actions: [
|
||||
TextButton(onPressed: _cancel, child: Text(t.common.cancel)),
|
||||
FocusableButton(
|
||||
onPressed: _cancel,
|
||||
child: TextButton(onPressed: _cancel, child: Text(t.common.cancel)),
|
||||
),
|
||||
if (!isMobile)
|
||||
FilledButton(onPressed: () => _pinInputKey.currentState?._trySubmit(), child: Text(t.common.submit)),
|
||||
FocusableButton(
|
||||
onPressed: () => _pinInputKey.currentState?._trySubmit(),
|
||||
child: FilledButton(
|
||||
onPressed: () => _pinInputKey.currentState?._trySubmit(),
|
||||
child: Text(t.common.submit),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
@@ -13,6 +13,7 @@ class ProfileListTile extends StatelessWidget {
|
||||
final VoidCallback onTap;
|
||||
final bool isCurrentUser;
|
||||
final bool showTrailingIcon;
|
||||
final bool allowCurrentUserTap;
|
||||
|
||||
const ProfileListTile({
|
||||
super.key,
|
||||
@@ -20,6 +21,7 @@ class ProfileListTile extends StatelessWidget {
|
||||
required this.onTap,
|
||||
this.isCurrentUser = false,
|
||||
this.showTrailingIcon = true,
|
||||
this.allowCurrentUserTap = false,
|
||||
});
|
||||
|
||||
@override
|
||||
@@ -53,7 +55,7 @@ class ProfileListTile extends StatelessWidget {
|
||||
title: Text(user.displayName),
|
||||
subtitle: _hasUserAttributes() ? Row(children: _buildUserAttributes(theme)) : null,
|
||||
trailing: trailing,
|
||||
onTap: isCurrentUser ? null : onTap,
|
||||
onTap: isCurrentUser && !allowCurrentUserTap ? null : onTap,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -98,11 +98,12 @@ class _ProfileSwitchScreenState extends State<ProfileSwitchScreen> {
|
||||
autofocus: isFirstSelectable,
|
||||
focusNode: isFirstSelectable ? _firstSelectableFocusNode : null,
|
||||
disableScale: true,
|
||||
onSelect: isCurrentUser ? null : () => _switchToUser(context, user),
|
||||
onSelect: isCurrentUser && !widget.requireSelection ? null : () => _switchToUser(context, user),
|
||||
child: Card(
|
||||
child: ProfileListTile(
|
||||
user: user,
|
||||
isCurrentUser: isCurrentUser,
|
||||
allowCurrentUserTap: widget.requireSelection,
|
||||
onTap: () => _switchToUser(context, user),
|
||||
),
|
||||
),
|
||||
@@ -120,7 +121,7 @@ class _ProfileSwitchScreenState extends State<ProfileSwitchScreen> {
|
||||
void _switchToUser(BuildContext context, PlexHomeUser user) async {
|
||||
final userProvider = context.userProfile;
|
||||
final navigator = Navigator.of(context);
|
||||
final success = await userProvider.switchToUser(user, context);
|
||||
final success = await userProvider.switchToUser(user, context, verifyPin: widget.requireSelection);
|
||||
|
||||
if (success) {
|
||||
if (widget.requireSelection) {
|
||||
|
||||
@@ -5,6 +5,7 @@ import 'package:cached_network_image/cached_network_image.dart';
|
||||
import '../../models/plex_home_user.dart';
|
||||
import '../../theme/mono_tokens.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
import '../../widgets/plex_optimized_image.dart' show blurArtwork;
|
||||
|
||||
class UserAvatarWidget extends StatelessWidget {
|
||||
final PlexHomeUser user;
|
||||
@@ -141,14 +142,14 @@ class UserAvatarWidget extends StatelessWidget {
|
||||
children: [
|
||||
// Avatar image
|
||||
ClipOval(
|
||||
child: CachedNetworkImage(
|
||||
child: blurArtwork(CachedNetworkImage(
|
||||
imageUrl: user.thumb,
|
||||
width: size,
|
||||
height: size,
|
||||
fit: BoxFit.cover,
|
||||
placeholder: (ctx, url) => _buildPlaceholderAvatar(theme),
|
||||
errorWidget: (ctx, url, error) => _buildPlaceholderAvatar(theme),
|
||||
),
|
||||
)),
|
||||
),
|
||||
|
||||
// Indicators (only show icon indicators when not using text labels)
|
||||
|
||||
@@ -348,24 +348,27 @@ class _EpisodeCardState extends State<_EpisodeCard> {
|
||||
}
|
||||
|
||||
Widget _buildEpisodeMetaRow(BuildContext context) {
|
||||
final mutedStyle = Theme.of(context).textTheme.bodySmall?.copyWith(color: tokens(context).textMuted, fontSize: 12);
|
||||
final dot = Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 6),
|
||||
child: Text('•', style: mutedStyle),
|
||||
);
|
||||
return Row(
|
||||
children: [
|
||||
if (widget.episode.duration != null)
|
||||
Text(
|
||||
formatDurationTimestamp(Duration(milliseconds: widget.episode.duration!)),
|
||||
style: Theme.of(context).textTheme.bodySmall?.copyWith(color: tokens(context).textMuted, fontSize: 12),
|
||||
),
|
||||
if (widget.episode.duration != null) Text(formatDurationTimestamp(Duration(milliseconds: widget.episode.duration!)), style: mutedStyle),
|
||||
if (widget.episode.originallyAvailableAt != null) ...[
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 6),
|
||||
child: Text(
|
||||
'•',
|
||||
style: Theme.of(context).textTheme.bodySmall?.copyWith(color: tokens(context).textMuted, fontSize: 12),
|
||||
),
|
||||
),
|
||||
dot,
|
||||
Text(formatFullDate(widget.episode.originallyAvailableAt!), style: mutedStyle),
|
||||
],
|
||||
if (widget.episode.userRating != null && widget.episode.userRating! > 0) ...[
|
||||
dot,
|
||||
Padding(padding: const EdgeInsets.only(top: 2), child: Icon(Symbols.star_rounded, size: 12, fill: 1, color: Colors.amber)),
|
||||
const SizedBox(width: 2),
|
||||
Text(
|
||||
formatFullDate(widget.episode.originallyAvailableAt!),
|
||||
style: Theme.of(context).textTheme.bodySmall?.copyWith(color: tokens(context).textMuted, fontSize: 12),
|
||||
(widget.episode.userRating! / 2) == (widget.episode.userRating! / 2).truncateToDouble()
|
||||
? '${(widget.episode.userRating! / 2).toInt()}'
|
||||
: (widget.episode.userRating! / 2).toStringAsFixed(1),
|
||||
style: mutedStyle,
|
||||
),
|
||||
],
|
||||
],
|
||||
|
||||
@@ -4,10 +4,11 @@ import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:plezy/widgets/app_icon.dart';
|
||||
import 'package:material_symbols_icons/symbols.dart';
|
||||
import '../../focus/focusable_button.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
import '../../models/external_player_models.dart';
|
||||
import '../../services/settings_service.dart';
|
||||
import '../../widgets/desktop_app_bar.dart';
|
||||
import '../../widgets/focused_scroll_scaffold.dart';
|
||||
|
||||
class ExternalPlayerScreen extends StatefulWidget {
|
||||
const ExternalPlayerScreen({super.key});
|
||||
@@ -45,65 +46,66 @@ class _ExternalPlayerScreenState extends State<ExternalPlayerScreen> {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
if (_isLoading) {
|
||||
return const Scaffold(body: Center(child: CircularProgressIndicator()));
|
||||
return FocusedScrollScaffold(
|
||||
title: Text(t.externalPlayer.title),
|
||||
slivers: [const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))],
|
||||
);
|
||||
}
|
||||
|
||||
final knownPlayers = KnownPlayers.getForCurrentPlatform();
|
||||
|
||||
return Scaffold(
|
||||
body: CustomScrollView(
|
||||
slivers: [
|
||||
CustomAppBar(title: Text(t.externalPlayer.title), pinned: true),
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
sliver: SliverList(
|
||||
delegate: SliverChildListDelegate([
|
||||
return FocusedScrollScaffold(
|
||||
title: Text(t.externalPlayer.title),
|
||||
slivers: [
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
sliver: SliverList(
|
||||
delegate: SliverChildListDelegate([
|
||||
Card(
|
||||
child: SwitchListTile(
|
||||
secondary: const AppIcon(Symbols.open_in_new_rounded, fill: 1),
|
||||
title: Text(t.externalPlayer.useExternalPlayer),
|
||||
subtitle: Text(t.externalPlayer.useExternalPlayerDescription),
|
||||
value: _useExternalPlayer,
|
||||
onChanged: (value) async {
|
||||
setState(() => _useExternalPlayer = value);
|
||||
await _settingsService.setUseExternalPlayer(value);
|
||||
},
|
||||
),
|
||||
),
|
||||
if (_useExternalPlayer) ...[
|
||||
const SizedBox(height: 16),
|
||||
Card(
|
||||
child: SwitchListTile(
|
||||
secondary: const AppIcon(Symbols.open_in_new_rounded, fill: 1),
|
||||
title: Text(t.externalPlayer.useExternalPlayer),
|
||||
subtitle: Text(t.externalPlayer.useExternalPlayerDescription),
|
||||
value: _useExternalPlayer,
|
||||
onChanged: (value) async {
|
||||
setState(() => _useExternalPlayer = value);
|
||||
await _settingsService.setUseExternalPlayer(value);
|
||||
},
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: Text(
|
||||
t.externalPlayer.selectPlayer,
|
||||
style: Theme.of(context).textTheme.titleMedium?.copyWith(fontWeight: FontWeight.bold),
|
||||
),
|
||||
),
|
||||
// Known players
|
||||
...knownPlayers.map((player) => _buildPlayerTile(player)),
|
||||
// Custom players
|
||||
if (_customPlayers.isNotEmpty) const Divider(),
|
||||
..._customPlayers.map((player) => _buildPlayerTile(player, isCustom: true)),
|
||||
// Add custom player button
|
||||
const Divider(),
|
||||
ListTile(
|
||||
leading: const AppIcon(Symbols.add_rounded, fill: 1),
|
||||
title: Text(t.externalPlayer.addCustomPlayer),
|
||||
onTap: _showAddCustomPlayerDialog,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
if (_useExternalPlayer) ...[
|
||||
const SizedBox(height: 16),
|
||||
Card(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
Padding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
child: Text(
|
||||
t.externalPlayer.selectPlayer,
|
||||
style: Theme.of(context).textTheme.titleMedium?.copyWith(fontWeight: FontWeight.bold),
|
||||
),
|
||||
),
|
||||
// Known players
|
||||
...knownPlayers.map((player) => _buildPlayerTile(player)),
|
||||
// Custom players
|
||||
if (_customPlayers.isNotEmpty) const Divider(),
|
||||
..._customPlayers.map((player) => _buildPlayerTile(player, isCustom: true)),
|
||||
// Add custom player button
|
||||
const Divider(),
|
||||
ListTile(
|
||||
leading: const AppIcon(Symbols.add_rounded, fill: 1),
|
||||
title: Text(t.externalPlayer.addCustomPlayer),
|
||||
onTap: _showAddCustomPlayerDialog,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
]),
|
||||
),
|
||||
],
|
||||
]),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
@@ -168,6 +170,8 @@ class _ExternalPlayerScreenState extends State<ExternalPlayerScreen> {
|
||||
Future<void> _showAddCustomPlayerDialog() async {
|
||||
final nameController = TextEditingController();
|
||||
final valueController = TextEditingController();
|
||||
final valueFocusNode = FocusNode();
|
||||
final saveFocusNode = FocusNode();
|
||||
var selectedType = CustomPlayerType.command;
|
||||
|
||||
final result = await showDialog<bool>(
|
||||
@@ -200,6 +204,7 @@ class _ExternalPlayerScreenState extends State<ExternalPlayerScreen> {
|
||||
decoration: InputDecoration(labelText: t.externalPlayer.playerName, hintText: 'My Player'),
|
||||
autofocus: true,
|
||||
textInputAction: TextInputAction.next,
|
||||
onSubmitted: (_) => primaryFocus?.nextFocus(),
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
SizedBox(
|
||||
@@ -223,21 +228,34 @@ class _ExternalPlayerScreenState extends State<ExternalPlayerScreen> {
|
||||
const SizedBox(height: 16),
|
||||
TextField(
|
||||
controller: valueController,
|
||||
focusNode: valueFocusNode,
|
||||
decoration: InputDecoration(labelText: fieldLabel, hintText: fieldHint),
|
||||
textInputAction: TextInputAction.done,
|
||||
onSubmitted: (_) => saveFocusNode.requestFocus(),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(context), child: Text(t.common.cancel)),
|
||||
FilledButton(
|
||||
FocusableButton(
|
||||
onPressed: () => Navigator.pop(context),
|
||||
child: TextButton(onPressed: () => Navigator.pop(context), child: Text(t.common.cancel)),
|
||||
),
|
||||
FocusableButton(
|
||||
focusNode: saveFocusNode,
|
||||
onPressed: () {
|
||||
if (nameController.text.isNotEmpty && valueController.text.isNotEmpty) {
|
||||
Navigator.pop(context, true);
|
||||
}
|
||||
},
|
||||
child: Text(t.common.save),
|
||||
child: FilledButton(
|
||||
onPressed: () {
|
||||
if (nameController.text.isNotEmpty && valueController.text.isNotEmpty) {
|
||||
Navigator.pop(context, true);
|
||||
}
|
||||
},
|
||||
child: Text(t.common.save),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
@@ -245,6 +263,9 @@ class _ExternalPlayerScreenState extends State<ExternalPlayerScreen> {
|
||||
),
|
||||
);
|
||||
|
||||
valueFocusNode.dispose();
|
||||
saveFocusNode.dispose();
|
||||
|
||||
if (result != true) return;
|
||||
|
||||
final id = 'custom_${DateTime.now().millisecondsSinceEpoch}';
|
||||
|
||||
@@ -6,10 +6,11 @@ import 'package:plezy/widgets/app_icon.dart';
|
||||
import 'package:material_symbols_icons/symbols.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:logger/logger.dart';
|
||||
import '../../focus/focusable_button.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
import '../../utils/app_logger.dart';
|
||||
import '../../utils/snackbar_helper.dart';
|
||||
import '../../widgets/desktop_app_bar.dart';
|
||||
import '../../widgets/focused_scroll_scaffold.dart';
|
||||
|
||||
class LogsScreen extends StatefulWidget {
|
||||
const LogsScreen({super.key});
|
||||
@@ -119,7 +120,16 @@ class _LogsScreenState extends State<LogsScreen> {
|
||||
),
|
||||
],
|
||||
),
|
||||
actions: [TextButton(onPressed: () => Navigator.of(ctx).pop(), child: Text(t.common.close))],
|
||||
actions: [
|
||||
FocusableButton(
|
||||
autofocus: true,
|
||||
onPressed: () => Navigator.of(ctx).pop(),
|
||||
child: TextButton(
|
||||
onPressed: () => Navigator.of(ctx).pop(),
|
||||
child: Text(t.common.close),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
} catch (_) {
|
||||
@@ -165,54 +175,49 @@ class _LogsScreenState extends State<LogsScreen> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
body: CustomScrollView(
|
||||
slivers: [
|
||||
CustomAppBar(
|
||||
title: Text(t.screens.logs),
|
||||
pinned: true,
|
||||
actions: [
|
||||
IconButton(
|
||||
icon: const AppIcon(Symbols.refresh_rounded, fill: 1),
|
||||
onPressed: _loadLogs,
|
||||
tooltip: t.common.refresh,
|
||||
),
|
||||
IconButton(
|
||||
icon: const AppIcon(Symbols.upload_rounded, fill: 1),
|
||||
onPressed: _logs.isNotEmpty ? _uploadLogs : null,
|
||||
tooltip: t.logs.uploadLogs,
|
||||
),
|
||||
IconButton(
|
||||
icon: const AppIcon(Symbols.content_copy_rounded, fill: 1),
|
||||
onPressed: _logs.isNotEmpty ? _copyAllLogs : null,
|
||||
tooltip: t.logs.copyLogs,
|
||||
),
|
||||
IconButton(
|
||||
icon: const AppIcon(Symbols.delete_outline_rounded, fill: 1),
|
||||
onPressed: _logs.isNotEmpty ? _clearLogs : null,
|
||||
tooltip: t.logs.clearLogs,
|
||||
),
|
||||
],
|
||||
),
|
||||
if (_logs.isEmpty)
|
||||
SliverFillRemaining(child: Center(child: Text(t.messages.noLogsAvailable)))
|
||||
else
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(8),
|
||||
sliver: SliverList(
|
||||
delegate: SliverChildBuilderDelegate((context, index) {
|
||||
final log = _logs[index];
|
||||
return _LogEntryCard(
|
||||
log: log,
|
||||
formatTime: _formatTime,
|
||||
levelColor: _getLevelColor(log.level),
|
||||
levelIcon: _getLevelIcon(log.level),
|
||||
);
|
||||
}, childCount: _logs.length),
|
||||
),
|
||||
return FocusedScrollScaffold(
|
||||
title: Text(t.screens.logs),
|
||||
actions: [
|
||||
IconButton(
|
||||
icon: const AppIcon(Symbols.refresh_rounded, fill: 1),
|
||||
onPressed: _loadLogs,
|
||||
tooltip: t.common.refresh,
|
||||
),
|
||||
IconButton(
|
||||
icon: const AppIcon(Symbols.upload_rounded, fill: 1),
|
||||
onPressed: _logs.isNotEmpty ? _uploadLogs : null,
|
||||
tooltip: t.logs.uploadLogs,
|
||||
),
|
||||
IconButton(
|
||||
icon: const AppIcon(Symbols.content_copy_rounded, fill: 1),
|
||||
onPressed: _logs.isNotEmpty ? _copyAllLogs : null,
|
||||
tooltip: t.logs.copyLogs,
|
||||
),
|
||||
IconButton(
|
||||
icon: const AppIcon(Symbols.delete_outline_rounded, fill: 1),
|
||||
onPressed: _logs.isNotEmpty ? _clearLogs : null,
|
||||
tooltip: t.logs.clearLogs,
|
||||
),
|
||||
],
|
||||
slivers: [
|
||||
if (_logs.isEmpty)
|
||||
SliverFillRemaining(child: Center(child: Text(t.messages.noLogsAvailable)))
|
||||
else
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(8),
|
||||
sliver: SliverList(
|
||||
delegate: SliverChildBuilderDelegate((context, index) {
|
||||
final log = _logs[index];
|
||||
return _LogEntryCard(
|
||||
log: log,
|
||||
formatTime: _formatTime,
|
||||
levelColor: _getLevelColor(log.level),
|
||||
levelIcon: _getLevelIcon(log.level),
|
||||
);
|
||||
}, childCount: _logs.length),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,10 +3,11 @@ import 'package:plezy/widgets/app_icon.dart';
|
||||
import 'package:material_symbols_icons/symbols.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
import '../../models/mpv_config_models.dart';
|
||||
import '../../focus/focusable_button.dart';
|
||||
import '../../utils/dialogs.dart';
|
||||
import '../../utils/snackbar_helper.dart';
|
||||
import '../../services/settings_service.dart';
|
||||
import '../../widgets/desktop_app_bar.dart';
|
||||
import '../../widgets/focused_scroll_scaffold.dart';
|
||||
|
||||
class MpvConfigScreen extends StatefulWidget {
|
||||
const MpvConfigScreen({super.key});
|
||||
@@ -110,15 +111,25 @@ class _MpvConfigScreenState extends State<MpvConfigScreen> {
|
||||
],
|
||||
),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(context, false), child: Text(t.common.cancel)),
|
||||
TextButton(
|
||||
FocusableButton(
|
||||
onPressed: () => Navigator.pop(context, false),
|
||||
child: TextButton(onPressed: () => Navigator.pop(context, false), child: Text(t.common.cancel)),
|
||||
),
|
||||
FocusableButton(
|
||||
focusNode: saveFocusNode,
|
||||
onPressed: () {
|
||||
if (keyController.text.isNotEmpty && valueController.text.isNotEmpty) {
|
||||
Navigator.pop(context, true);
|
||||
}
|
||||
},
|
||||
child: Text(t.common.save),
|
||||
child: TextButton(
|
||||
onPressed: () {
|
||||
if (keyController.text.isNotEmpty && valueController.text.isNotEmpty) {
|
||||
Navigator.pop(context, true);
|
||||
}
|
||||
},
|
||||
child: Text(t.common.save),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
@@ -163,6 +174,7 @@ class _MpvConfigScreenState extends State<MpvConfigScreen> {
|
||||
if (_entries.isEmpty) return;
|
||||
|
||||
final nameController = TextEditingController();
|
||||
final saveFocusNode = FocusNode();
|
||||
|
||||
final result = await showDialog<bool>(
|
||||
context: context,
|
||||
@@ -172,21 +184,36 @@ class _MpvConfigScreenState extends State<MpvConfigScreen> {
|
||||
controller: nameController,
|
||||
decoration: InputDecoration(labelText: t.mpvConfig.presetName, hintText: t.mpvConfig.presetNameHint),
|
||||
autofocus: true,
|
||||
textInputAction: TextInputAction.done,
|
||||
onSubmitted: (_) => saveFocusNode.requestFocus(),
|
||||
),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(context, false), child: Text(t.common.cancel)),
|
||||
TextButton(
|
||||
FocusableButton(
|
||||
onPressed: () => Navigator.pop(context, false),
|
||||
child: TextButton(onPressed: () => Navigator.pop(context, false), child: Text(t.common.cancel)),
|
||||
),
|
||||
FocusableButton(
|
||||
focusNode: saveFocusNode,
|
||||
onPressed: () {
|
||||
if (nameController.text.isNotEmpty) {
|
||||
Navigator.pop(context, true);
|
||||
}
|
||||
},
|
||||
child: Text(t.common.save),
|
||||
child: FilledButton(
|
||||
onPressed: () {
|
||||
if (nameController.text.isNotEmpty) {
|
||||
Navigator.pop(context, true);
|
||||
}
|
||||
},
|
||||
child: Text(t.common.save),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
|
||||
saveFocusNode.dispose();
|
||||
|
||||
if (result == true) {
|
||||
await _settingsService.saveMpvPreset(nameController.text.trim(), _entries);
|
||||
if (!mounted) return;
|
||||
@@ -235,27 +262,23 @@ class _MpvConfigScreenState extends State<MpvConfigScreen> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
if (_isLoading) {
|
||||
return const Scaffold(body: Center(child: CircularProgressIndicator()));
|
||||
}
|
||||
|
||||
return Scaffold(
|
||||
body: CustomScrollView(
|
||||
slivers: [
|
||||
CustomAppBar(title: Text(t.screens.mpvConfig), pinned: true),
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
sliver: SliverList(
|
||||
delegate: SliverChildListDelegate([
|
||||
_buildPresetsCard(),
|
||||
const SizedBox(height: 16),
|
||||
_buildEntriesCard(),
|
||||
const SizedBox(height: 24),
|
||||
]),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
return FocusedScrollScaffold(
|
||||
title: Text(t.screens.mpvConfig),
|
||||
slivers: _isLoading
|
||||
? [const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))]
|
||||
: [
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
sliver: SliverList(
|
||||
delegate: SliverChildListDelegate([
|
||||
_buildPresetsCard(),
|
||||
const SizedBox(height: 16),
|
||||
_buildEntriesCard(),
|
||||
const SizedBox(height: 24),
|
||||
]),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -9,7 +9,9 @@ import '../../models/hotkey_model.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:url_launcher/url_launcher.dart';
|
||||
|
||||
|
||||
import '../../focus/focus_memory_tracker.dart';
|
||||
import '../../focus/input_mode_tracker.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
import '../main_screen.dart';
|
||||
import '../../mixins/refreshable.dart';
|
||||
@@ -20,11 +22,13 @@ import '../../providers/settings_provider.dart';
|
||||
import '../../providers/theme_provider.dart';
|
||||
import '../../providers/user_profile_provider.dart';
|
||||
import '../../services/keyboard_shortcuts_service.dart';
|
||||
import '../../mpv/player/player_android.dart';
|
||||
import '../../services/settings_service.dart' as settings;
|
||||
import '../../services/update_service.dart';
|
||||
import '../../utils/snackbar_helper.dart';
|
||||
import '../../utils/platform_detector.dart';
|
||||
import '../../widgets/desktop_app_bar.dart';
|
||||
import '../../widgets/focused_scroll_scaffold.dart';
|
||||
import '../../widgets/tv_number_spinner.dart';
|
||||
import 'hotkey_recorder_widget.dart';
|
||||
import '../../providers/companion_remote_provider.dart';
|
||||
@@ -102,7 +106,7 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
|
||||
bool _enableDebugLogging = false;
|
||||
bool _enableHardwareDecoding = true;
|
||||
int _bufferSize = 128;
|
||||
int _bufferSize = 0;
|
||||
int _seekTimeSmall = 10;
|
||||
int _seekTimeLarge = 30;
|
||||
int _sleepTimerDuration = 30;
|
||||
@@ -147,7 +151,9 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
|
||||
@override
|
||||
void focusActiveTabIfReady() {
|
||||
_focusTracker.restoreFocus(fallbackKey: _kTheme);
|
||||
if (InputModeTracker.isKeyboardMode(context)) {
|
||||
_focusTracker.restoreFocus(fallbackKey: _kTheme);
|
||||
}
|
||||
}
|
||||
|
||||
/// Navigate focus to the sidebar
|
||||
@@ -208,7 +214,7 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
onKeyEvent: _handleKeyEvent,
|
||||
child: CustomScrollView(
|
||||
slivers: [
|
||||
CustomAppBar(title: Text(t.settings.title), pinned: true),
|
||||
ExcludeFocus(child: CustomAppBar(title: Text(t.settings.title), pinned: true)),
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
sliver: SliverList(
|
||||
@@ -481,7 +487,7 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
focusNode: _focusTracker.get(_kBufferSize),
|
||||
leading: const AppIcon(Symbols.memory_rounded, fill: 1),
|
||||
title: Text(t.settings.bufferSize),
|
||||
subtitle: Text(t.settings.bufferSizeMB(size: _bufferSize.toString())),
|
||||
subtitle: Text(_bufferSize == 0 ? t.settings.bufferSizeAuto : t.settings.bufferSizeMB(size: _bufferSize.toString())),
|
||||
trailing: const AppIcon(Symbols.chevron_right_rounded, fill: 1),
|
||||
onTap: () => _showBufferSizeDialog(),
|
||||
),
|
||||
@@ -1052,7 +1058,7 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
}
|
||||
|
||||
void _showBufferSizeDialog() {
|
||||
final options = [64, 128, 256, 512, 1024];
|
||||
final options = [0, 64, 128, 256, 512, 1024];
|
||||
|
||||
showDialog(
|
||||
context: context,
|
||||
@@ -1067,13 +1073,19 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
_bufferSize == size ? Symbols.radio_button_checked_rounded : Symbols.radio_button_unchecked_rounded,
|
||||
fill: 1,
|
||||
),
|
||||
title: Text('${size}MB'),
|
||||
onTap: () {
|
||||
title: Text(size == 0 ? t.settings.bufferSizeAuto : '${size}MB'),
|
||||
onTap: () async {
|
||||
setState(() {
|
||||
_bufferSize = size;
|
||||
_settingsService.setBufferSize(size);
|
||||
});
|
||||
Navigator.pop(context);
|
||||
if (Platform.isAndroid && size > 0) {
|
||||
final heapMB = await PlayerAndroid.getHeapSize();
|
||||
if (heapMB > 0 && size > heapMB ~/ 4 && mounted) {
|
||||
showAppSnackBar(this.context, t.settings.bufferSizeWarning(heap: heapMB.toString(), size: size.toString()));
|
||||
}
|
||||
}
|
||||
},
|
||||
);
|
||||
}).toList(),
|
||||
@@ -1096,9 +1108,9 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
required int currentValue,
|
||||
required Future<void> Function(int value) onSave,
|
||||
}) {
|
||||
final isTV = PlatformDetector.isTV();
|
||||
final useDpadControls = InputModeTracker.isKeyboardMode(context);
|
||||
|
||||
if (isTV) {
|
||||
if (useDpadControls) {
|
||||
_showNumericInputDialogTV(
|
||||
title: title,
|
||||
suffixText: suffixText,
|
||||
@@ -1405,7 +1417,11 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
title: Text(t.settings.clearCache),
|
||||
content: Text(t.settings.clearCacheDescription),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(context), child: Text(t.common.cancel)),
|
||||
TextButton(
|
||||
autofocus: true,
|
||||
onPressed: () => Navigator.pop(context),
|
||||
child: Text(t.common.cancel),
|
||||
),
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
final navigator = Navigator.of(context);
|
||||
@@ -1431,7 +1447,11 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
title: Text(t.settings.resetSettings),
|
||||
content: Text(t.settings.resetSettingsDescription),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(context), child: Text(t.common.cancel)),
|
||||
TextButton(
|
||||
autofocus: true,
|
||||
onPressed: () => Navigator.pop(context),
|
||||
child: Text(t.common.cancel),
|
||||
),
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
final navigator = Navigator.of(context);
|
||||
@@ -1440,7 +1460,6 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
if (mounted) {
|
||||
navigator.pop();
|
||||
showSuccessSnackBar(this.context, t.settings.resetSettingsSuccess);
|
||||
// Reload settings
|
||||
_loadSettings();
|
||||
}
|
||||
},
|
||||
@@ -1578,7 +1597,11 @@ class _SettingsScreenState extends State<SettingsScreen> with FocusableTab {
|
||||
],
|
||||
),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(context), child: Text(t.common.close)),
|
||||
TextButton(
|
||||
autofocus: true,
|
||||
onPressed: () => Navigator.pop(context),
|
||||
child: Text(t.common.close),
|
||||
),
|
||||
FilledButton(
|
||||
onPressed: () async {
|
||||
final url = Uri.parse(_updateInfo!['releaseUrl']);
|
||||
@@ -1739,61 +1762,54 @@ class _KeyboardShortcutsScreenState extends State<_KeyboardShortcutsScreen> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
if (_isLoading) {
|
||||
return const Scaffold(body: Center(child: CircularProgressIndicator()));
|
||||
}
|
||||
return FocusedScrollScaffold(
|
||||
title: Text(t.settings.keyboardShortcuts),
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
await widget.keyboardService.resetToDefaults();
|
||||
await _loadHotkeys();
|
||||
if (mounted) {
|
||||
showSuccessSnackBar(this.context, t.settings.shortcutsReset);
|
||||
}
|
||||
},
|
||||
child: Text(t.common.reset),
|
||||
),
|
||||
],
|
||||
slivers: _isLoading
|
||||
? [const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))]
|
||||
: [
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
sliver: SliverList(
|
||||
delegate: SliverChildBuilderDelegate((context, index) {
|
||||
final actions = _hotkeys.keys.toList();
|
||||
final action = actions[index];
|
||||
final hotkey = _hotkeys[action]!;
|
||||
|
||||
return Scaffold(
|
||||
body: CustomScrollView(
|
||||
slivers: [
|
||||
CustomAppBar(
|
||||
title: Text(t.settings.keyboardShortcuts),
|
||||
pinned: true,
|
||||
actions: [
|
||||
TextButton(
|
||||
onPressed: () async {
|
||||
await widget.keyboardService.resetToDefaults();
|
||||
await _loadHotkeys();
|
||||
if (mounted) {
|
||||
showSuccessSnackBar(this.context, t.settings.shortcutsReset);
|
||||
}
|
||||
},
|
||||
child: Text(t.common.reset),
|
||||
return Card(
|
||||
margin: const EdgeInsets.only(bottom: 8),
|
||||
child: ListTile(
|
||||
title: Text(widget.keyboardService.getActionDisplayName(action)),
|
||||
subtitle: Text(action),
|
||||
trailing: Container(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 6),
|
||||
decoration: BoxDecoration(
|
||||
border: Border.fromBorderSide(BorderSide(color: Theme.of(context).dividerColor)),
|
||||
borderRadius: const BorderRadius.all(Radius.circular(6)),
|
||||
),
|
||||
child: Text(
|
||||
widget.keyboardService.formatHotkey(hotkey),
|
||||
style: const TextStyle(fontFamily: 'monospace'),
|
||||
),
|
||||
),
|
||||
onTap: () => _editHotkey(action, hotkey),
|
||||
),
|
||||
);
|
||||
}, childCount: _hotkeys.length),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
sliver: SliverList(
|
||||
delegate: SliverChildBuilderDelegate((context, index) {
|
||||
final actions = _hotkeys.keys.toList();
|
||||
final action = actions[index];
|
||||
final hotkey = _hotkeys[action]!;
|
||||
|
||||
return Card(
|
||||
margin: const EdgeInsets.only(bottom: 8),
|
||||
child: ListTile(
|
||||
title: Text(widget.keyboardService.getActionDisplayName(action)),
|
||||
subtitle: Text(action),
|
||||
trailing: Container(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 12, vertical: 6),
|
||||
decoration: BoxDecoration(
|
||||
border: Border.fromBorderSide(BorderSide(color: Theme.of(context).dividerColor)),
|
||||
borderRadius: const BorderRadius.all(Radius.circular(6)),
|
||||
),
|
||||
child: Text(
|
||||
widget.keyboardService.formatHotkey(hotkey),
|
||||
style: const TextStyle(fontFamily: 'monospace'),
|
||||
),
|
||||
),
|
||||
onTap: () => _editHotkey(action, hotkey),
|
||||
),
|
||||
);
|
||||
}, childCount: _hotkeys.length),
|
||||
),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -2,10 +2,11 @@ import 'package:flutter/material.dart';
|
||||
import 'package:plezy/widgets/app_icon.dart';
|
||||
import 'package:material_symbols_icons/symbols.dart';
|
||||
import 'package:flex_color_picker/flex_color_picker.dart';
|
||||
import '../../focus/focusable_button.dart';
|
||||
import '../../i18n/strings.g.dart';
|
||||
import '../../services/settings_service.dart';
|
||||
import '../../utils/platform_detector.dart';
|
||||
import '../../widgets/desktop_app_bar.dart';
|
||||
import '../../focus/input_mode_tracker.dart';
|
||||
import '../../widgets/focused_scroll_scaffold.dart';
|
||||
import '../../widgets/tv_color_picker.dart';
|
||||
import '../../widgets/tv_number_spinner.dart';
|
||||
|
||||
@@ -197,14 +198,23 @@ class _SubtitleStylingScreenState extends State<SubtitleStylingScreen> {
|
||||
],
|
||||
),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(dialogContext), child: Text(t.common.cancel)),
|
||||
TextButton(
|
||||
FocusableButton(
|
||||
onPressed: () => Navigator.pop(dialogContext),
|
||||
child: TextButton(onPressed: () => Navigator.pop(dialogContext), child: Text(t.common.cancel)),
|
||||
),
|
||||
FocusableButton(
|
||||
focusNode: saveFocusNode,
|
||||
onPressed: () {
|
||||
onSave(spinnerValue);
|
||||
Navigator.pop(dialogContext);
|
||||
},
|
||||
child: Text(t.common.save),
|
||||
child: TextButton(
|
||||
onPressed: () {
|
||||
onSave(spinnerValue);
|
||||
Navigator.pop(dialogContext);
|
||||
},
|
||||
child: Text(t.common.save),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
@@ -262,14 +272,23 @@ class _SubtitleStylingScreenState extends State<SubtitleStylingScreen> {
|
||||
onConfirm: () => saveFocusNode.requestFocus(),
|
||||
),
|
||||
actions: [
|
||||
TextButton(onPressed: () => Navigator.pop(dialogContext), child: Text(t.common.cancel)),
|
||||
TextButton(
|
||||
FocusableButton(
|
||||
onPressed: () => Navigator.pop(dialogContext),
|
||||
child: TextButton(onPressed: () => Navigator.pop(dialogContext), child: Text(t.common.cancel)),
|
||||
),
|
||||
FocusableButton(
|
||||
focusNode: saveFocusNode,
|
||||
onPressed: () {
|
||||
onColorSelected(_colorToHex(pickerColor));
|
||||
Navigator.pop(dialogContext);
|
||||
},
|
||||
child: Text(t.common.save),
|
||||
child: TextButton(
|
||||
onPressed: () {
|
||||
onColorSelected(_colorToHex(pickerColor));
|
||||
Navigator.pop(dialogContext);
|
||||
},
|
||||
child: Text(t.common.save),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
@@ -281,24 +300,24 @@ class _SubtitleStylingScreenState extends State<SubtitleStylingScreen> {
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
if (_isLoading) {
|
||||
return const Scaffold(body: Center(child: CircularProgressIndicator()));
|
||||
}
|
||||
|
||||
return Scaffold(
|
||||
body: CustomScrollView(
|
||||
slivers: [
|
||||
CustomAppBar(title: Text(t.screens.subtitleStyling), pinned: true),
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
sliver: SliverList(delegate: SliverChildListDelegate([_buildStylingCard(), const SizedBox(height: 24)])),
|
||||
),
|
||||
],
|
||||
),
|
||||
return FocusedScrollScaffold(
|
||||
title: Text(t.screens.subtitleStyling),
|
||||
slivers: _isLoading
|
||||
? [const SliverFillRemaining(child: Center(child: CircularProgressIndicator()))]
|
||||
: [
|
||||
SliverPadding(
|
||||
padding: const EdgeInsets.all(16),
|
||||
sliver: SliverList(
|
||||
delegate: SliverChildListDelegate([_buildStylingCard(), const SizedBox(height: 24)]),
|
||||
),
|
||||
),
|
||||
],
|
||||
);
|
||||
}
|
||||
|
||||
Widget _buildStylingCard() {
|
||||
final useDpadControls = InputModeTracker.isKeyboardMode(context);
|
||||
|
||||
return Card(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
@@ -311,7 +330,7 @@ class _SubtitleStylingScreenState extends State<SubtitleStylingScreen> {
|
||||
),
|
||||
),
|
||||
// Font Size Slider
|
||||
if (PlatformDetector.isTV())
|
||||
if (useDpadControls)
|
||||
ListTile(
|
||||
title: Text(t.subtitlingStyling.fontSize),
|
||||
trailing: Text('$_fontSize'),
|
||||
@@ -344,7 +363,7 @@ class _SubtitleStylingScreenState extends State<SubtitleStylingScreen> {
|
||||
),
|
||||
const Divider(),
|
||||
// Subtitle Position Slider
|
||||
if (PlatformDetector.isTV())
|
||||
if (useDpadControls)
|
||||
ListTile(
|
||||
title: Text(t.subtitlingStyling.position),
|
||||
trailing: Text(() {
|
||||
@@ -397,7 +416,7 @@ class _SubtitleStylingScreenState extends State<SubtitleStylingScreen> {
|
||||
_settingsService.setSubtitleTextColor(color);
|
||||
}
|
||||
|
||||
if (PlatformDetector.isTV()) {
|
||||
if (useDpadControls) {
|
||||
_showTvColorPicker(t.subtitlingStyling.textColor, _textColor, onColorSelected);
|
||||
} else {
|
||||
_showColorPicker(t.subtitlingStyling.textColor, _textColor, onColorSelected);
|
||||
@@ -406,7 +425,7 @@ class _SubtitleStylingScreenState extends State<SubtitleStylingScreen> {
|
||||
),
|
||||
const Divider(),
|
||||
// Border Size Slider
|
||||
if (PlatformDetector.isTV())
|
||||
if (useDpadControls)
|
||||
ListTile(
|
||||
title: Text(t.subtitlingStyling.borderSize),
|
||||
trailing: Text('$_borderSize'),
|
||||
@@ -449,7 +468,7 @@ class _SubtitleStylingScreenState extends State<SubtitleStylingScreen> {
|
||||
_settingsService.setSubtitleBorderColor(color);
|
||||
}
|
||||
|
||||
if (PlatformDetector.isTV()) {
|
||||
if (useDpadControls) {
|
||||
_showTvColorPicker(t.subtitlingStyling.borderColor, _borderColor, onColorSelected);
|
||||
} else {
|
||||
_showColorPicker(t.subtitlingStyling.borderColor, _borderColor, onColorSelected);
|
||||
@@ -458,7 +477,7 @@ class _SubtitleStylingScreenState extends State<SubtitleStylingScreen> {
|
||||
),
|
||||
const Divider(),
|
||||
// Background Opacity Slider
|
||||
if (PlatformDetector.isTV())
|
||||
if (useDpadControls)
|
||||
ListTile(
|
||||
title: Text(t.subtitlingStyling.backgroundOpacity),
|
||||
trailing: Text('$_backgroundOpacity%'),
|
||||
@@ -504,7 +523,7 @@ class _SubtitleStylingScreenState extends State<SubtitleStylingScreen> {
|
||||
_settingsService.setSubtitleBackgroundColor(color);
|
||||
}
|
||||
|
||||
if (PlatformDetector.isTV()) {
|
||||
if (useDpadControls) {
|
||||
_showTvColorPicker(t.subtitlingStyling.backgroundColor, _backgroundColor, onColorSelected);
|
||||
} else {
|
||||
_showColorPicker(t.subtitlingStyling.backgroundColor, _backgroundColor, onColorSelected);
|
||||
|
||||
@@ -36,9 +36,11 @@ import '../services/offline_watch_sync_service.dart';
|
||||
import '../services/settings_service.dart';
|
||||
import '../services/sleep_timer_service.dart';
|
||||
import '../services/track_selection_service.dart';
|
||||
import '../services/ambient_lighting_service.dart';
|
||||
import '../services/video_filter_manager.dart';
|
||||
import '../services/video_pip_manager.dart';
|
||||
import '../services/pip_service.dart';
|
||||
import '../models/shader_preset.dart';
|
||||
import '../services/shader_service.dart';
|
||||
import '../providers/shader_provider.dart';
|
||||
import '../providers/user_profile_provider.dart';
|
||||
@@ -53,8 +55,9 @@ import '../utils/snackbar_helper.dart';
|
||||
import '../utils/track_label_builder.dart' as tlb;
|
||||
import '../utils/plex_url_helper.dart';
|
||||
import '../utils/video_player_navigation.dart';
|
||||
import '../widgets/overlay_sheet.dart';
|
||||
import '../widgets/video_controls/video_controls.dart';
|
||||
import '../focus/focusable_wrapper.dart';
|
||||
import '../focus/focusable_button.dart';
|
||||
import '../focus/input_mode_tracker.dart';
|
||||
import '../focus/dpad_navigator.dart';
|
||||
import '../focus/key_event_utils.dart';
|
||||
@@ -167,6 +170,7 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
VideoFilterManager? _videoFilterManager;
|
||||
VideoPIPManager? _videoPIPManager;
|
||||
ShaderService? _shaderService;
|
||||
AmbientLightingService? _ambientLightingService;
|
||||
final EpisodeNavigationService _episodeNavigation = EpisodeNavigationService();
|
||||
|
||||
// Watch Together provider reference (stored early to use in dispose)
|
||||
@@ -376,7 +380,6 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
// Load buffer size from settings
|
||||
final settingsService = await SettingsService.getInstance();
|
||||
final bufferSizeMB = settingsService.getBufferSize();
|
||||
final bufferSizeBytes = bufferSizeMB * 1024 * 1024;
|
||||
final enableHardwareDecoding = settingsService.getEnableHardwareDecoding();
|
||||
final debugLoggingEnabled = settingsService.getEnableDebugLogging();
|
||||
final useExoPlayer = settingsService.getUseExoPlayer();
|
||||
@@ -385,8 +388,12 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
player = Player(useExoPlayer: useExoPlayer);
|
||||
|
||||
await player!.setProperty('sub-ass', 'yes'); // Enable libass
|
||||
await player!.setProperty('demuxer-max-bytes', bufferSizeBytes.toString());
|
||||
if (bufferSizeMB > 0) {
|
||||
final bufferSizeBytes = bufferSizeMB * 1024 * 1024;
|
||||
await player!.setProperty('demuxer-max-bytes', bufferSizeBytes.toString());
|
||||
}
|
||||
await player!.setProperty('msg-level', debugLoggingEnabled ? 'all=debug' : 'all=error');
|
||||
await player!.setLogLevel(debugLoggingEnabled ? 'v' : 'warn');
|
||||
await player!.setProperty('hwdec', _getHwdecValue(enableHardwareDecoding));
|
||||
|
||||
// Subtitle styling
|
||||
@@ -1022,7 +1029,13 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
// Shader Service (MPV only)
|
||||
_shaderService = ShaderService(player!);
|
||||
if (_shaderService!.isSupported) {
|
||||
// Ambient Lighting Service
|
||||
_ambientLightingService = AmbientLightingService(player!);
|
||||
_shaderService!.ambientLightingService = _ambientLightingService;
|
||||
_videoFilterManager?.ambientLightingService = _ambientLightingService;
|
||||
|
||||
await _applySavedShaderPreset();
|
||||
await _restoreAmbientLighting();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1138,13 +1151,102 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
}
|
||||
}
|
||||
|
||||
/// Restore ambient lighting from persisted setting
|
||||
Future<void> _restoreAmbientLighting() async {
|
||||
final settings = await SettingsService.getInstance();
|
||||
if (!settings.getAmbientLighting()) return;
|
||||
|
||||
final ambientLighting = _ambientLightingService;
|
||||
if (ambientLighting == null || !ambientLighting.isSupported) return;
|
||||
|
||||
// Same enable logic as _toggleAmbientLighting
|
||||
final dwidth = await player?.getProperty('dwidth');
|
||||
final dheight = await player?.getProperty('dheight');
|
||||
if (dwidth == null || dheight == null) return;
|
||||
final w = double.tryParse(dwidth);
|
||||
final h = double.tryParse(dheight);
|
||||
if (w == null || h == null || h == 0) return;
|
||||
final videoAspect = w / h;
|
||||
|
||||
final playerSize = _videoFilterManager?.playerSize;
|
||||
if (playerSize == null || playerSize.height == 0) return;
|
||||
final outputAspect = playerSize.width / playerSize.height;
|
||||
|
||||
// Clear shaders — ambient lighting and shaders are mutually exclusive
|
||||
final shaderProvider = context.read<ShaderProvider>();
|
||||
if (shaderProvider.isShaderEnabled) {
|
||||
await _shaderService!.applyPreset(ShaderPreset.none);
|
||||
shaderProvider.setCurrentPreset(ShaderPreset.none);
|
||||
}
|
||||
|
||||
_videoFilterManager?.resetToContain();
|
||||
await ambientLighting.enable(videoAspect, outputAspect);
|
||||
if (mounted) setState(() {});
|
||||
}
|
||||
|
||||
/// Cycle through BoxFit modes: contain → cover → fill → contain (for button)
|
||||
void _cycleBoxFitMode() {
|
||||
// Disable ambient lighting when switching boxfit modes
|
||||
// (cover/fill change the video rect, making the baked-in shader incorrect)
|
||||
_ambientLightingService?.disable();
|
||||
setState(() {
|
||||
_videoFilterManager?.cycleBoxFitMode();
|
||||
});
|
||||
}
|
||||
|
||||
/// Update video-aspect-override when player size changes.
|
||||
/// The shader adapts automatically via built-in target_size uniform.
|
||||
void _updateAmbientLightingOnResize(Size newSize) {
|
||||
final ambientLighting = _ambientLightingService;
|
||||
if (ambientLighting == null || !ambientLighting.isEnabled) return;
|
||||
if (newSize.height == 0) return;
|
||||
|
||||
ambientLighting.updateOutputAspect(newSize.width / newSize.height);
|
||||
}
|
||||
|
||||
/// Toggle ambient lighting effect on/off
|
||||
Future<void> _toggleAmbientLighting() async {
|
||||
final ambientLighting = _ambientLightingService;
|
||||
if (ambientLighting == null || !ambientLighting.isSupported) return;
|
||||
|
||||
if (ambientLighting.isEnabled) {
|
||||
await ambientLighting.disable();
|
||||
_videoFilterManager?.updateVideoFilter();
|
||||
} else {
|
||||
// Get video display aspect ratio
|
||||
final dwidth = await player?.getProperty('dwidth');
|
||||
final dheight = await player?.getProperty('dheight');
|
||||
if (dwidth == null || dheight == null) return;
|
||||
final w = double.tryParse(dwidth);
|
||||
final h = double.tryParse(dheight);
|
||||
if (w == null || h == null || h == 0) return;
|
||||
final videoAspect = w / h;
|
||||
|
||||
// Get player widget aspect ratio
|
||||
final playerSize = _videoFilterManager?.playerSize;
|
||||
if (playerSize == null || playerSize.height == 0) return;
|
||||
final outputAspect = playerSize.width / playerSize.height;
|
||||
|
||||
// Clear shaders — ambient lighting and shaders are mutually exclusive
|
||||
final shaderProvider = context.read<ShaderProvider>();
|
||||
if (shaderProvider.isShaderEnabled) {
|
||||
await _shaderService!.applyPreset(ShaderPreset.none);
|
||||
shaderProvider.setCurrentPreset(ShaderPreset.none);
|
||||
}
|
||||
|
||||
// Force contain mode when enabling ambient lighting
|
||||
_videoFilterManager?.resetToContain();
|
||||
|
||||
await ambientLighting.enable(videoAspect, outputAspect);
|
||||
}
|
||||
|
||||
// Persist ambient lighting state
|
||||
final settings = await SettingsService.getInstance();
|
||||
settings.setAmbientLighting(ambientLighting.isEnabled);
|
||||
|
||||
setState(() {});
|
||||
}
|
||||
|
||||
/// Toggle between contain and cover modes only (for pinch gesture)
|
||||
void _toggleContainCover() {
|
||||
setState(() {
|
||||
@@ -1658,6 +1760,12 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
await _navigateToEpisode(_previousEpisode!);
|
||||
}
|
||||
|
||||
/// Navigate to a specific queue item (called from QueueSheet)
|
||||
Future<void> navigateToQueueItem(PlexMetadata metadata) async {
|
||||
_notifyWatchTogetherMediaChange(metadata: metadata);
|
||||
await _navigateToEpisode(metadata);
|
||||
}
|
||||
|
||||
bool _isSwitchingChannel = false;
|
||||
|
||||
/// Switch to an adjacent live TV channel (delta: +1 for next, -1 for previous)
|
||||
@@ -2125,23 +2233,21 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
final isCurrentRoute = ModalRoute.of(context)?.isCurrent ?? true;
|
||||
// Screen-level Focus wraps ALL phases (loading + initialized).
|
||||
// - autofocus: grabs focus when no deeper child claims it.
|
||||
// - onKeyEvent: catch-all that consumes any event children didn't handle,
|
||||
// preventing leaks to previous routes.
|
||||
// - onKeyEvent: self-heals when this node has primary focus (no descendant
|
||||
// focused). Nav keys are only consumed in that case; otherwise they pass
|
||||
// through so DirectionalFocusAction can drive dpad nav in overlay sheets.
|
||||
return Focus(
|
||||
focusNode: _screenFocusNode,
|
||||
autofocus: isCurrentRoute,
|
||||
canRequestFocus: isCurrentRoute,
|
||||
onKeyEvent: (node, event) {
|
||||
if (!isCurrentRoute) return KeyEventResult.ignored;
|
||||
// Safety net: if this screen-level node itself has primary focus
|
||||
// (no descendant focused, e.g. after controls auto-hide), self-heal.
|
||||
// BACK is excluded: on Android TV the BACK button fires both a key event
|
||||
// and a system back gesture. Handling it here would double-pop because
|
||||
// PopScope.onPopInvokedWithResult also processes the system back gesture.
|
||||
// PopScope handles BACK navigation exclusively.
|
||||
if (node.hasPrimaryFocus && !event.logicalKey.isBackKey) {
|
||||
// Redirect focus to the first traversable descendant (video controls)
|
||||
// and show controls immediately so the first key press isn't swallowed.
|
||||
// Back keys always pass through — handled by PopScope (system back
|
||||
// gesture) or overlay sheet's onKeyEvent.
|
||||
if (event.logicalKey.isBackKey) return KeyEventResult.ignored;
|
||||
// Self-heal: if this node itself has primary focus (no descendant
|
||||
// focused, e.g. after controls auto-hide), redirect to first descendant.
|
||||
if (node.hasPrimaryFocus) {
|
||||
if (event.isActionable) {
|
||||
_controlsVisible.value = true;
|
||||
final descendants = node.traversalDescendants;
|
||||
@@ -2149,10 +2255,19 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
descendants.first.requestFocus();
|
||||
}
|
||||
}
|
||||
return event.logicalKey.isNavigationKey ? KeyEventResult.handled : KeyEventResult.ignored;
|
||||
}
|
||||
return KeyEventResult.handled;
|
||||
// A descendant has focus — let events pass through so
|
||||
// DirectionalFocusAction / ActivateAction can process them.
|
||||
return KeyEventResult.ignored;
|
||||
},
|
||||
child: _isPlayerInitialized && player != null ? _buildVideoPlayer(context) : _buildLoadingSpinner(),
|
||||
child: OverlaySheetHost(
|
||||
child: Builder(
|
||||
builder: (sheetContext) => _isPlayerInitialized && player != null
|
||||
? _buildVideoPlayer(sheetContext)
|
||||
: _buildLoadingSpinner(),
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
@@ -2163,11 +2278,16 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
return PopScope(
|
||||
canPop: false, // Disable swipe-back gesture to prevent interference with timeline scrubbing
|
||||
onPopInvokedWithResult: (didPop, result) {
|
||||
// Only process system-initiated back gestures (didPop: false).
|
||||
// Programmatic Navigator.pop() triggers didPop: true — ignore it here
|
||||
// to avoid consuming the BackKeyCoordinator flag before the system back
|
||||
// gesture arrives (which would cause a double-pop on Android TV).
|
||||
if (!didPop) {
|
||||
// If an overlay sheet is open, delegate back to it instead of
|
||||
// exiting the player. This prevents the double-pop on Android TV
|
||||
// where the system back gesture would otherwise reach both the
|
||||
// sheet and the player's PopScope.
|
||||
final sheetController = OverlaySheetController.maybeOf(context);
|
||||
if (sheetController != null && sheetController.isOpen) {
|
||||
sheetController.pop();
|
||||
return;
|
||||
}
|
||||
if (BackKeyCoordinator.consumeIfHandled()) return;
|
||||
BackKeyCoordinator.markHandled();
|
||||
_handleBackButton();
|
||||
@@ -2214,6 +2334,8 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
if (mounted && player != null) {
|
||||
_videoFilterManager?.updatePlayerSize(newSize);
|
||||
_videoPIPManager?.updatePlayerSize(newSize);
|
||||
// Update ambient lighting shader if active (output aspect changed)
|
||||
_updateAmbientLightingOnResize(newSize);
|
||||
// Update Metal layer frame on iOS/macOS for rotation
|
||||
player!.updateFrame();
|
||||
}
|
||||
@@ -2283,6 +2405,8 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
: null,
|
||||
isLive: widget.isLive,
|
||||
liveChannelName: _liveChannelName,
|
||||
isAmbientLightingEnabled: _ambientLightingService?.isEnabled ?? false,
|
||||
onToggleAmbientLighting: _toggleAmbientLighting,
|
||||
),
|
||||
);
|
||||
},
|
||||
@@ -2378,27 +2502,13 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
Row(
|
||||
children: [
|
||||
Expanded(
|
||||
child: FocusableWrapper(
|
||||
child: FocusableButton(
|
||||
focusNode: _playNextCancelFocusNode,
|
||||
onSelect: _cancelAutoPlay,
|
||||
useBackgroundFocus: true,
|
||||
onPressed: _cancelAutoPlay,
|
||||
autoScroll: false,
|
||||
borderRadius: 20,
|
||||
onKeyEvent: (node, event) {
|
||||
if (event is KeyDownEvent) {
|
||||
// RIGHT arrow moves focus to Play Next button
|
||||
if (event.logicalKey == LogicalKeyboardKey.arrowRight) {
|
||||
_playNextConfirmFocusNode.requestFocus();
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
// Trap focus - consume UP/DOWN to prevent escape
|
||||
if (event.logicalKey == LogicalKeyboardKey.arrowUp ||
|
||||
event.logicalKey == LogicalKeyboardKey.arrowDown) {
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
}
|
||||
return KeyEventResult.ignored;
|
||||
},
|
||||
onNavigateRight: () => _playNextConfirmFocusNode.requestFocus(),
|
||||
onNavigateUp: () {}, // Trap focus
|
||||
onNavigateDown: () {}, // Trap focus
|
||||
child: OutlinedButton(
|
||||
onPressed: _cancelAutoPlay,
|
||||
style: OutlinedButton.styleFrom(
|
||||
@@ -2412,27 +2522,13 @@ class VideoPlayerScreenState extends State<VideoPlayerScreen> with WidgetsBindin
|
||||
),
|
||||
const SizedBox(width: 8),
|
||||
Expanded(
|
||||
child: FocusableWrapper(
|
||||
child: FocusableButton(
|
||||
focusNode: _playNextConfirmFocusNode,
|
||||
onSelect: _playNext,
|
||||
useBackgroundFocus: true,
|
||||
onPressed: _playNext,
|
||||
autoScroll: false,
|
||||
borderRadius: 20,
|
||||
onKeyEvent: (node, event) {
|
||||
if (event is KeyDownEvent) {
|
||||
// LEFT arrow moves focus to Cancel button
|
||||
if (event.logicalKey == LogicalKeyboardKey.arrowLeft) {
|
||||
_playNextCancelFocusNode.requestFocus();
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
// Trap focus - consume UP/DOWN to prevent escape
|
||||
if (event.logicalKey == LogicalKeyboardKey.arrowUp ||
|
||||
event.logicalKey == LogicalKeyboardKey.arrowDown) {
|
||||
return KeyEventResult.handled;
|
||||
}
|
||||
}
|
||||
return KeyEventResult.ignored;
|
||||
},
|
||||
onNavigateLeft: () => _playNextCancelFocusNode.requestFocus(),
|
||||
onNavigateUp: () {}, // Trap focus
|
||||
onNavigateDown: () {}, // Trap focus
|
||||
child: FilledButton(
|
||||
onPressed: _playNext,
|
||||
style: FilledButton.styleFrom(
|
||||
|
||||
@@ -0,0 +1,249 @@
|
||||
import 'dart:io';
|
||||
|
||||
import 'package:flutter/foundation.dart';
|
||||
import 'package:path_provider/path_provider.dart';
|
||||
import 'package:path/path.dart' as path;
|
||||
|
||||
import '../mpv/player/player.dart';
|
||||
|
||||
/// Generates and manages an ambient lighting GLSL shader that fills letterbox/pillarbox
|
||||
/// bars with a blurred, dimmed version of the video edges.
|
||||
///
|
||||
/// Uses video-aspect-override to fill the window (eliminating black bars), then
|
||||
/// a GLSL shader composites the sharp original video centered at correct aspect
|
||||
/// over a blurred background.
|
||||
///
|
||||
/// The shader uses MPV's built-in `input_size` and `target_size` uniforms to
|
||||
/// dynamically compute the video rect position. On window resize, only
|
||||
/// `video-aspect-override` needs updating — no shader regeneration required.
|
||||
class AmbientLightingService {
|
||||
final Player _player;
|
||||
String? _shaderPath;
|
||||
bool _enabled = false;
|
||||
|
||||
/// Brightness multiplier for the blurred background (0.0-1.0).
|
||||
static const double _brightness = 0.5;
|
||||
|
||||
AmbientLightingService(this._player);
|
||||
|
||||
bool get isEnabled => _enabled;
|
||||
bool get isSupported => _player.playerType == 'mpv';
|
||||
|
||||
/// Enable ambient lighting effect.
|
||||
///
|
||||
/// [videoAspect] - the source video's display aspect ratio (width/height).
|
||||
/// [outputAspect] - the player widget's aspect ratio (width/height).
|
||||
Future<void> enable(double videoAspect, double outputAspect) async {
|
||||
if (!isSupported) return;
|
||||
|
||||
try {
|
||||
// Write static shader (only needs to happen once)
|
||||
if (_shaderPath == null) {
|
||||
_shaderPath = await _writeShaderToTemp(_generateShader());
|
||||
}
|
||||
|
||||
if (kDebugMode) {
|
||||
debugPrint('AmbientLightingService: Shader path: $_shaderPath');
|
||||
}
|
||||
|
||||
// Set video-aspect-override to fill the entire output area
|
||||
await _player.setProperty('video-aspect-override', outputAspect.toString());
|
||||
|
||||
// Append ambient lighting shader
|
||||
await _player.command(['change-list', 'glsl-shaders', 'append', _shaderPath!]);
|
||||
|
||||
_enabled = true;
|
||||
|
||||
if (kDebugMode) {
|
||||
debugPrint('AmbientLightingService: Enabled (video=$videoAspect, output=$outputAspect)');
|
||||
}
|
||||
} catch (e) {
|
||||
if (kDebugMode) {
|
||||
debugPrint('AmbientLightingService: Failed to enable: $e');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Disable ambient lighting effect and restore normal letterboxing.
|
||||
Future<void> disable() async {
|
||||
if (!_enabled) return;
|
||||
|
||||
try {
|
||||
if (_shaderPath != null) {
|
||||
await _player.command(['change-list', 'glsl-shaders', 'remove', _shaderPath!]);
|
||||
}
|
||||
|
||||
await _player.setProperty('video-aspect-override', 'no');
|
||||
|
||||
_enabled = false;
|
||||
|
||||
if (kDebugMode) {
|
||||
debugPrint('AmbientLightingService: Disabled');
|
||||
}
|
||||
} catch (e) {
|
||||
if (kDebugMode) {
|
||||
debugPrint('AmbientLightingService: Failed to disable: $e');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Re-append the ambient lighting shader to the chain.
|
||||
/// Called by ShaderService after it rebuilds the shader chain (clr + append).
|
||||
Future<void> reappendShader() async {
|
||||
if (!_enabled || _shaderPath == null) return;
|
||||
await _player.command(['change-list', 'glsl-shaders', 'append', _shaderPath!]);
|
||||
}
|
||||
|
||||
/// Update video-aspect-override when the window resizes.
|
||||
/// The shader adapts automatically via dynamic `target_size` uniform.
|
||||
void updateOutputAspect(double outputAspect) {
|
||||
if (!_enabled) return;
|
||||
_player.setProperty('video-aspect-override', outputAspect.toString());
|
||||
}
|
||||
|
||||
/// Generate a static multi-pass GLSL shader.
|
||||
///
|
||||
/// Uses MPV's built-in `input_size` (video dimensions) and `target_size`
|
||||
/// (output dimensions) uniforms which update automatically on resize.
|
||||
/// No baked-in aspect constants — fully adaptive.
|
||||
///
|
||||
/// Pipeline (all MAIN hooks):
|
||||
/// 1. Save original video as ORIGINAL
|
||||
/// 2. Downscale to 1/8 as SMALL (center 60% zoom)
|
||||
/// 3-5. Three Kawase blur passes at 1/8 -> BLUR8C
|
||||
/// 6. Downscale BLUR8C to 1/64 as TINY
|
||||
/// 7-8. Two more Kawase blur passes at 1/64 -> GLOW
|
||||
/// 9. Composite: video rect -> ORIGINAL, bars -> GLOW
|
||||
String _generateShader() {
|
||||
final br = _brightness.toStringAsFixed(2);
|
||||
final buf = StringBuffer();
|
||||
|
||||
// Pass 1: Save original video
|
||||
buf.writeln('//!HOOK MAIN');
|
||||
buf.writeln('//!BIND HOOKED');
|
||||
buf.writeln('//!SAVE ORIGINAL');
|
||||
buf.writeln('//!DESC Ambient Lighting Save');
|
||||
buf.writeln('vec4 hook() {');
|
||||
buf.writeln(' return HOOKED_tex(HOOKED_pos);');
|
||||
buf.writeln('}');
|
||||
buf.writeln();
|
||||
|
||||
// Pass 2: Downscale to 1/8 with center zoom.
|
||||
buf.writeln('//!HOOK MAIN');
|
||||
buf.writeln('//!BIND ORIGINAL');
|
||||
buf.writeln('//!SAVE SMALL');
|
||||
buf.writeln('//!WIDTH ORIGINAL.w 8 /');
|
||||
buf.writeln('//!HEIGHT ORIGINAL.h 8 /');
|
||||
buf.writeln('//!DESC Ambient Lighting Downscale');
|
||||
buf.writeln('vec4 hook() {');
|
||||
buf.writeln(' vec2 uv = ORIGINAL_pos * 0.6 + 0.2;');
|
||||
buf.writeln(' return ORIGINAL_tex(uv);');
|
||||
buf.writeln('}');
|
||||
buf.writeln();
|
||||
|
||||
// Pass 3-5: Three Kawase blur passes at 1/8 resolution.
|
||||
const blur8Steps = [
|
||||
('SMALL', 'BLUR8A', '2.0', 'Blur1'),
|
||||
('BLUR8A', 'BLUR8B', '6.0', 'Blur2'),
|
||||
('BLUR8B', 'BLUR8C', '12.0', 'Blur3'),
|
||||
];
|
||||
for (final (input, output, offset, desc) in blur8Steps) {
|
||||
buf.writeln('//!HOOK MAIN');
|
||||
buf.writeln('//!BIND $input');
|
||||
buf.writeln('//!SAVE $output');
|
||||
buf.writeln('//!WIDTH $input.w');
|
||||
buf.writeln('//!HEIGHT $input.h');
|
||||
buf.writeln('//!DESC Ambient Lighting $desc');
|
||||
buf.writeln('vec4 hook() {');
|
||||
buf.writeln(' vec2 ps = ${input}_pt;');
|
||||
buf.writeln(' vec4 s = ${input}_tex(${input}_pos + vec2( $offset, $offset) * ps)');
|
||||
buf.writeln(' + ${input}_tex(${input}_pos + vec2( $offset, -$offset) * ps)');
|
||||
buf.writeln(' + ${input}_tex(${input}_pos + vec2(-$offset, $offset) * ps)');
|
||||
buf.writeln(' + ${input}_tex(${input}_pos + vec2(-$offset, -$offset) * ps);');
|
||||
buf.writeln(' return s * 0.25;');
|
||||
buf.writeln('}');
|
||||
buf.writeln();
|
||||
}
|
||||
|
||||
// Pass 6: Downscale the already-blurred 1/8 texture to 1/64.
|
||||
buf.writeln('//!HOOK MAIN');
|
||||
buf.writeln('//!BIND BLUR8C');
|
||||
buf.writeln('//!SAVE TINY');
|
||||
buf.writeln('//!WIDTH BLUR8C.w 8 /');
|
||||
buf.writeln('//!HEIGHT BLUR8C.h 8 /');
|
||||
buf.writeln('//!DESC Ambient Lighting Downscale2');
|
||||
buf.writeln('vec4 hook() {');
|
||||
buf.writeln(' return BLUR8C_tex(BLUR8C_pos);');
|
||||
buf.writeln('}');
|
||||
buf.writeln();
|
||||
|
||||
// Pass 7-8: Two more Kawase blur passes at 1/64 for maximum diffusion.
|
||||
const blur64Steps = [
|
||||
('TINY', 'GLOW1', '3.0', 'Blur4'),
|
||||
('GLOW1', 'GLOW', '6.0', 'Blur5'),
|
||||
];
|
||||
for (final (input, output, offset, desc) in blur64Steps) {
|
||||
buf.writeln('//!HOOK MAIN');
|
||||
buf.writeln('//!BIND $input');
|
||||
buf.writeln('//!SAVE $output');
|
||||
buf.writeln('//!WIDTH $input.w');
|
||||
buf.writeln('//!HEIGHT $input.h');
|
||||
buf.writeln('//!DESC Ambient Lighting $desc');
|
||||
buf.writeln('vec4 hook() {');
|
||||
buf.writeln(' vec2 ps = ${input}_pt;');
|
||||
buf.writeln(' vec4 s = ${input}_tex(${input}_pos + vec2( $offset, $offset) * ps)');
|
||||
buf.writeln(' + ${input}_tex(${input}_pos + vec2( $offset, -$offset) * ps)');
|
||||
buf.writeln(' + ${input}_tex(${input}_pos + vec2(-$offset, $offset) * ps)');
|
||||
buf.writeln(' + ${input}_tex(${input}_pos + vec2(-$offset, -$offset) * ps);');
|
||||
buf.writeln(' return s * 0.25;');
|
||||
buf.writeln('}');
|
||||
buf.writeln();
|
||||
}
|
||||
|
||||
// Pass 9: Composite — no //!SAVE so this replaces MAIN.
|
||||
// Uses built-in input_size (video coded dims) and target_size (output dims)
|
||||
// to dynamically compute where the video rect sits. These auto-update on resize.
|
||||
buf.writeln('//!HOOK MAIN');
|
||||
buf.writeln('//!BIND ORIGINAL');
|
||||
buf.writeln('//!BIND GLOW');
|
||||
buf.writeln('//!DESC Ambient Lighting Composite');
|
||||
buf.writeln('vec4 hook() {');
|
||||
buf.writeln(' float vid_aspect = input_size.x / input_size.y;');
|
||||
buf.writeln(' float out_aspect = target_size.x / target_size.y;');
|
||||
buf.writeln();
|
||||
buf.writeln(' vec2 scale, off;');
|
||||
buf.writeln(' if (vid_aspect > out_aspect) {');
|
||||
buf.writeln(' float s = out_aspect / vid_aspect;');
|
||||
buf.writeln(' scale = vec2(1.0, s);');
|
||||
buf.writeln(' off = vec2(0.0, (1.0 - s) * 0.5);');
|
||||
buf.writeln(' } else {');
|
||||
buf.writeln(' float s = vid_aspect / out_aspect;');
|
||||
buf.writeln(' scale = vec2(s, 1.0);');
|
||||
buf.writeln(' off = vec2((1.0 - s) * 0.5, 0.0);');
|
||||
buf.writeln(' }');
|
||||
buf.writeln();
|
||||
buf.writeln(' vec2 vid_pos = (ORIGINAL_pos - off) / scale;');
|
||||
buf.writeln();
|
||||
buf.writeln(' if (all(greaterThanEqual(vid_pos, vec2(0.0))) &&');
|
||||
buf.writeln(' all(lessThanEqual(vid_pos, vec2(1.0)))) {');
|
||||
buf.writeln(' return ORIGINAL_tex(vid_pos);');
|
||||
buf.writeln(' }');
|
||||
buf.writeln();
|
||||
buf.writeln(' return GLOW_tex(ORIGINAL_pos) * $br;');
|
||||
buf.writeln('}');
|
||||
|
||||
return buf.toString();
|
||||
}
|
||||
|
||||
/// Write the shader to a temp file and return the path.
|
||||
Future<String> _writeShaderToTemp(String shader) async {
|
||||
final cacheDir = await getTemporaryDirectory();
|
||||
final shaderDir = Directory(path.join(cacheDir.path, 'shaders'));
|
||||
if (!shaderDir.existsSync()) {
|
||||
shaderDir.createSync(recursive: true);
|
||||
}
|
||||
final file = File(path.join(shaderDir.path, 'ambient_lighting.glsl'));
|
||||
await file.writeAsString(shader);
|
||||
return file.path;
|
||||
}
|
||||
}
|
||||
@@ -240,6 +240,7 @@ class DownloadManagerService {
|
||||
|
||||
// Prevents concurrent _processQueue calls
|
||||
bool _isProcessingQueue = false;
|
||||
bool _disposed = false;
|
||||
|
||||
// Debounce timers for DB progress writes (keyed by globalKey).
|
||||
// UI progress streams are still real-time; only the DB write is debounced.
|
||||
@@ -626,6 +627,7 @@ class DownloadManagerService {
|
||||
|
||||
/// Callback: background_downloader progress update
|
||||
void _onTaskProgress(TaskProgressUpdate update) {
|
||||
if (_disposed) return;
|
||||
final globalKey = update.task.metaData;
|
||||
if (globalKey.isEmpty || update.progress < 0) return;
|
||||
|
||||
@@ -666,44 +668,49 @@ class DownloadManagerService {
|
||||
|
||||
/// Callback: background_downloader status change
|
||||
void _onTaskStatusChanged(TaskStatusUpdate update) {
|
||||
if (_disposed) return;
|
||||
final globalKey = update.task.metaData;
|
||||
if (globalKey.isEmpty) return;
|
||||
|
||||
appLogger.d('Background task status: ${update.status} for $globalKey');
|
||||
|
||||
switch (update.status) {
|
||||
case TaskStatus.complete:
|
||||
_onDownloadComplete(globalKey, update.task);
|
||||
case TaskStatus.failed:
|
||||
_onDownloadFailed(globalKey, update.exception?.description ?? 'Download failed');
|
||||
case TaskStatus.notFound:
|
||||
_onDownloadFailed(globalKey, 'File not found (404)');
|
||||
case TaskStatus.canceled:
|
||||
if (_pausingKeys.contains(globalKey)) {
|
||||
// Expected cancel from holding-queue promotion during pause — ignore
|
||||
try {
|
||||
switch (update.status) {
|
||||
case TaskStatus.complete:
|
||||
_onDownloadComplete(globalKey, update.task);
|
||||
case TaskStatus.failed:
|
||||
_onDownloadFailed(globalKey, update.exception?.description ?? 'Download failed');
|
||||
case TaskStatus.notFound:
|
||||
_onDownloadFailed(globalKey, 'File not found (404)');
|
||||
case TaskStatus.canceled:
|
||||
if (_pausingKeys.contains(globalKey)) {
|
||||
// Expected cancel from holding-queue promotion during pause — ignore
|
||||
break;
|
||||
}
|
||||
final ctx = _pendingDownloadContext.remove(globalKey);
|
||||
if (ctx != null) {
|
||||
// Context still present → OS cancelled the task, not user code
|
||||
// (user-initiated pause/cancel/delete removes context before cancellation completes)
|
||||
appLogger.w('Download cancelled by system for $globalKey, re-queuing');
|
||||
_database.updateBgTaskId(globalKey, null);
|
||||
_transitionStatus(globalKey, DownloadStatus.queued);
|
||||
_database.addToQueue(mediaGlobalKey: globalKey);
|
||||
if (_lastClient != null) _processQueue(_lastClient!);
|
||||
}
|
||||
case TaskStatus.paused:
|
||||
appLogger.d('Download paused by system for $globalKey');
|
||||
case TaskStatus.waitingToRetry:
|
||||
appLogger.d('Download waiting to retry for $globalKey');
|
||||
case TaskStatus.enqueued:
|
||||
case TaskStatus.running:
|
||||
// If this item is being paused, the holding queue promoted it — cancel it
|
||||
if (_pausingKeys.contains(globalKey)) {
|
||||
FileDownloader().cancelTaskWithId(update.task.taskId);
|
||||
}
|
||||
break;
|
||||
}
|
||||
final ctx = _pendingDownloadContext.remove(globalKey);
|
||||
if (ctx != null) {
|
||||
// Context still present → OS cancelled the task, not user code
|
||||
// (user-initiated pause/cancel/delete removes context before cancellation completes)
|
||||
appLogger.w('Download cancelled by system for $globalKey, re-queuing');
|
||||
_database.updateBgTaskId(globalKey, null);
|
||||
_transitionStatus(globalKey, DownloadStatus.queued);
|
||||
_database.addToQueue(mediaGlobalKey: globalKey);
|
||||
if (_lastClient != null) _processQueue(_lastClient!);
|
||||
}
|
||||
case TaskStatus.paused:
|
||||
appLogger.d('Download paused by system for $globalKey');
|
||||
case TaskStatus.waitingToRetry:
|
||||
appLogger.d('Download waiting to retry for $globalKey');
|
||||
case TaskStatus.enqueued:
|
||||
case TaskStatus.running:
|
||||
// If this item is being paused, the holding queue promoted it — cancel it
|
||||
if (_pausingKeys.contains(globalKey)) {
|
||||
FileDownloader().cancelTaskWithId(update.task.taskId);
|
||||
}
|
||||
break;
|
||||
}
|
||||
} catch (e) {
|
||||
appLogger.e('Error handling download status change for $globalKey', error: e);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1661,6 +1668,7 @@ class DownloadManagerService {
|
||||
}
|
||||
|
||||
void dispose() {
|
||||
_disposed = true;
|
||||
for (final timer in _progressDebounceTimers.values) {
|
||||
timer.cancel();
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@ import 'package:flutter/scheduler.dart';
|
||||
import 'package:flutter/services.dart';
|
||||
import 'package:flutter/widgets.dart';
|
||||
import 'package:universal_gamepad/universal_gamepad.dart';
|
||||
import 'package:window_manager/window_manager.dart';
|
||||
|
||||
import '../utils/app_logger.dart';
|
||||
import '../utils/key_event_simulator.dart' as key_sim;
|
||||
@@ -14,7 +15,7 @@ import '../utils/key_event_simulator.dart' as key_sim;
|
||||
/// Listens to gamepad events from the `universal_gamepad` package and translates
|
||||
/// them into focus navigation actions and key events that integrate with the
|
||||
/// existing keyboard navigation system.
|
||||
class GamepadService {
|
||||
class GamepadService with WindowListener {
|
||||
static GamepadService? _instance;
|
||||
StreamSubscription<GamepadEvent>? _subscription;
|
||||
|
||||
@@ -48,6 +49,9 @@ class GamepadService {
|
||||
// Track button states to prevent repeated events from button holds
|
||||
final Set<GamepadButton> _pressedButtons = {};
|
||||
|
||||
// Whether the app window is currently focused — ignore gamepad input when false
|
||||
bool _windowFocused = true;
|
||||
|
||||
GamepadService._();
|
||||
|
||||
/// Get the singleton instance.
|
||||
@@ -75,6 +79,10 @@ class GamepadService {
|
||||
appLogger.e('GamepadService: Error listing gamepads', error: e);
|
||||
}
|
||||
|
||||
// Track window focus so we ignore gamepad input when another app is active
|
||||
windowManager.addListener(this);
|
||||
_windowFocused = await windowManager.isFocused();
|
||||
|
||||
_subscription?.cancel();
|
||||
_subscription = Gamepad.instance.events.listen(
|
||||
_handleGamepadEvent,
|
||||
@@ -88,9 +96,35 @@ class GamepadService {
|
||||
_stopDirectionRepeat();
|
||||
_subscription?.cancel();
|
||||
_subscription = null;
|
||||
windowManager.removeListener(this);
|
||||
Gamepad.instance.dispose();
|
||||
}
|
||||
|
||||
@override
|
||||
void onWindowFocus() => _windowFocused = true;
|
||||
|
||||
@override
|
||||
void onWindowBlur() {
|
||||
_windowFocused = false;
|
||||
_stopDirectionRepeat();
|
||||
|
||||
// Send key-up for any face buttons that are mid-hold so widgets
|
||||
// waiting for the release (e.g. long-press timers) don't get stuck.
|
||||
if (_pressedButtons.contains(GamepadButton.a)) {
|
||||
_simulateKeyUp(LogicalKeyboardKey.enter);
|
||||
}
|
||||
if (_pressedButtons.contains(GamepadButton.x)) {
|
||||
_simulateKeyUp(LogicalKeyboardKey.gameButtonX);
|
||||
}
|
||||
_pressedButtons.clear();
|
||||
|
||||
// Reset analog stick state so re-focus doesn't inherit stale direction
|
||||
_leftStickUp = false;
|
||||
_leftStickDown = false;
|
||||
_leftStickLeft = false;
|
||||
_leftStickRight = false;
|
||||
}
|
||||
|
||||
void _handleGamepadEvent(GamepadEvent event) {
|
||||
switch (event) {
|
||||
case GamepadConnectionEvent e:
|
||||
@@ -103,6 +137,8 @@ class GamepadService {
|
||||
}
|
||||
|
||||
void _handleButton(GamepadButtonEvent event) {
|
||||
if (!_windowFocused) return;
|
||||
|
||||
// Switch to keyboard mode on any button press
|
||||
if (event.pressed) {
|
||||
onGamepadInput?.call();
|
||||
@@ -167,6 +203,8 @@ class GamepadService {
|
||||
}
|
||||
|
||||
void _handleAxis(GamepadAxisEvent event) {
|
||||
if (!_windowFocused) return;
|
||||
|
||||
// Switch to keyboard mode on significant axis input
|
||||
if (event.value.abs() > 0.3) {
|
||||
onGamepadInput?.call();
|
||||
|
||||
@@ -177,6 +177,43 @@ class PlayQueueLauncher {
|
||||
);
|
||||
}
|
||||
|
||||
/// Launch playback from a folder's contents.
|
||||
Future<PlayQueueResult> launchFromFolder({
|
||||
required String folderKey,
|
||||
required bool shuffle,
|
||||
bool showLoadingIndicator = true,
|
||||
}) async {
|
||||
return _executeWithLoading(
|
||||
showLoading: showLoadingIndicator,
|
||||
action: shuffle ? t.common.shuffle : t.common.play,
|
||||
execute: (dismissLoading) async {
|
||||
final folderUri = await client.buildFolderUri(folderKey);
|
||||
|
||||
var playQueue = await client.createPlayQueue(
|
||||
uri: folderUri,
|
||||
type: 'video',
|
||||
shuffle: shuffle ? 1 : 0,
|
||||
);
|
||||
|
||||
if (playQueue != null && (playQueue.items == null || playQueue.items!.isEmpty)) {
|
||||
final fetchedQueue = await client.getPlayQueue(playQueue.playQueueID);
|
||||
if (fetchedQueue != null && fetchedQueue.items != null && fetchedQueue.items!.isNotEmpty) {
|
||||
playQueue = fetchedQueue;
|
||||
}
|
||||
}
|
||||
|
||||
await dismissLoading();
|
||||
|
||||
return _launchFromQueue(
|
||||
playQueue: playQueue,
|
||||
ratingKey: folderKey,
|
||||
serverId: serverId,
|
||||
serverName: serverName,
|
||||
);
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
/// Core method to launch playback from a play queue.
|
||||
Future<PlayQueueResult> _launchFromQueue({
|
||||
required PlayQueueResponse? playQueue,
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
import 'dart:convert';
|
||||
import 'dart:isolate';
|
||||
|
||||
import 'package:drift/drift.dart';
|
||||
|
||||
@@ -40,7 +41,7 @@ class PlexApiCache {
|
||||
final result = await (_db.select(_db.apiCache)..where((t) => t.cacheKey.equals(key))).getSingleOrNull();
|
||||
|
||||
if (result != null) {
|
||||
return jsonDecode(result.data) as Map<String, dynamic>;
|
||||
return await Isolate.run(() => jsonDecode(result.data) as Map<String, dynamic>);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
@@ -48,11 +49,10 @@ class PlexApiCache {
|
||||
/// Cache a response for an endpoint
|
||||
Future<void> put(String serverId, String endpoint, Map<String, dynamic> data) async {
|
||||
final key = _buildKey(serverId, endpoint);
|
||||
final encoded = await Isolate.run(() => jsonEncode(data));
|
||||
await _db
|
||||
.into(_db.apiCache)
|
||||
.insertOnConflictUpdate(
|
||||
ApiCacheCompanion(cacheKey: Value(key), data: Value(jsonEncode(data)), cachedAt: Value(DateTime.now())),
|
||||
);
|
||||
.insertOnConflictUpdate(ApiCacheCompanion(cacheKey: Value(key), data: Value(encoded), cachedAt: Value(DateTime.now())));
|
||||
}
|
||||
|
||||
/// Delete all cached data for a server
|
||||
@@ -130,27 +130,35 @@ class PlexApiCache {
|
||||
Future<Map<String, PlexMetadata>> getAllPinnedMetadata() async {
|
||||
final rows = await (_db.select(_db.apiCache)..where((t) => t.pinned.equals(true))).get();
|
||||
|
||||
final result = <String, PlexMetadata>{};
|
||||
// Extract (cacheKey, data) pairs and parse serverId/ratingKey on main thread (cheap string ops),
|
||||
// then send raw JSON strings to isolate for the expensive decode+parse.
|
||||
final entries = <(String serverId, String ratingKey, String data)>[];
|
||||
for (final row in rows) {
|
||||
// Extract serverId and ratingKey from cache key like "serverId:/library/metadata/12345"
|
||||
final colonIdx = row.cacheKey.indexOf(':');
|
||||
if (colonIdx < 0) continue;
|
||||
final serverId = row.cacheKey.substring(0, colonIdx);
|
||||
final match = RegExp(r'/library/metadata/([^/]+)$').firstMatch(row.cacheKey);
|
||||
if (match == null) continue;
|
||||
final ratingKey = match.group(1)!;
|
||||
|
||||
try {
|
||||
final data = jsonDecode(row.data) as Map<String, dynamic>;
|
||||
final json = PlexCacheParser.extractFirstMetadata(data);
|
||||
if (json == null) continue;
|
||||
final metadata = PlexMetadata.fromJsonWithImages(json).copyWith(serverId: serverId);
|
||||
result['$serverId:$ratingKey'] = metadata;
|
||||
} catch (_) {
|
||||
// Skip malformed entries
|
||||
}
|
||||
entries.add((serverId, match.group(1)!, row.data));
|
||||
}
|
||||
return result;
|
||||
|
||||
if (entries.isEmpty) return {};
|
||||
|
||||
return await Isolate.run(() {
|
||||
final result = <String, PlexMetadata>{};
|
||||
for (final (serverId, ratingKey, rawData) in entries) {
|
||||
try {
|
||||
final data = jsonDecode(rawData) as Map<String, dynamic>;
|
||||
final json = PlexCacheParser.extractFirstMetadata(data);
|
||||
if (json == null) continue;
|
||||
final metadata = PlexMetadata.fromJsonWithImages(json).copyWith(serverId: serverId);
|
||||
result['$serverId:$ratingKey'] = metadata;
|
||||
} catch (_) {
|
||||
// Skip malformed entries
|
||||
}
|
||||
}
|
||||
return result;
|
||||
});
|
||||
}
|
||||
|
||||
/// Clear all cached data (useful for debugging/testing)
|
||||
|
||||
+188
-86
@@ -1,4 +1,5 @@
|
||||
import 'dart:convert';
|
||||
import 'dart:isolate';
|
||||
import 'dart:math';
|
||||
import 'dart:ui' show VoidCallback;
|
||||
|
||||
@@ -33,6 +34,61 @@ import '../utils/plex_url_helper.dart';
|
||||
import '../utils/watch_state_notifier.dart';
|
||||
import 'plex_api_cache.dart';
|
||||
|
||||
/// Process hub JSON response in an isolate.
|
||||
/// Top-level function so it can be passed to [Isolate.run].
|
||||
List<PlexHub> _processHubResponse(String jsonStr, String serverId, String? serverName) {
|
||||
final decoded = jsonDecode(jsonStr) as Map<String, dynamic>;
|
||||
final container = decoded['MediaContainer'] as Map<String, dynamic>?;
|
||||
if (container == null || container['Hub'] == null) return [];
|
||||
|
||||
final hubs = <PlexHub>[];
|
||||
for (final hubJson in container['Hub'] as List) {
|
||||
try {
|
||||
final hub = PlexHub.fromJson(hubJson as Map<String, dynamic>);
|
||||
if (hub.items.isEmpty) continue;
|
||||
|
||||
final videoItems = hub.items
|
||||
.where((item) => item.isVideoContent)
|
||||
.map((item) => item.copyWith(serverId: serverId, serverName: serverName))
|
||||
.toList();
|
||||
|
||||
if (videoItems.isNotEmpty) {
|
||||
hubs.add(
|
||||
PlexHub(
|
||||
hubKey: hub.hubKey,
|
||||
title: hub.title,
|
||||
type: hub.type,
|
||||
hubIdentifier: hub.hubIdentifier,
|
||||
size: hub.size,
|
||||
more: hub.more,
|
||||
items: videoItems,
|
||||
serverId: serverId,
|
||||
serverName: serverName,
|
||||
),
|
||||
);
|
||||
}
|
||||
} catch (_) {
|
||||
// Skip hubs that fail to parse
|
||||
}
|
||||
}
|
||||
return hubs;
|
||||
}
|
||||
|
||||
/// Process on-deck JSON response in an isolate.
|
||||
/// Top-level function so it can be passed to [Isolate.run].
|
||||
List<PlexMetadata> _processOnDeckResponse(String jsonStr, String serverId, String? serverName) {
|
||||
final decoded = jsonDecode(jsonStr) as Map<String, dynamic>;
|
||||
final container = decoded['MediaContainer'] as Map<String, dynamic>?;
|
||||
if (container == null || container['Metadata'] == null) return [];
|
||||
|
||||
final allItems = (container['Metadata'] as List)
|
||||
.map((json) => PlexMetadata.fromJsonWithImages(json as Map<String, dynamic>)
|
||||
.copyWith(serverId: serverId, serverName: serverName))
|
||||
.toList();
|
||||
|
||||
return allItems.where((item) => !item.isMusicContent).toList();
|
||||
}
|
||||
|
||||
/// Constants for Plex stream types
|
||||
class PlexStreamType {
|
||||
static const int video = 1;
|
||||
@@ -376,6 +432,16 @@ class PlexClient {
|
||||
return 'server://$machineId/com.plexapp.plugins.library/library/metadata/$ratingKey';
|
||||
}
|
||||
|
||||
/// Build a server URI from a folder key for play queue creation.
|
||||
/// Folder keys are like `/library/sections/1/folder?parent=123`.
|
||||
Future<String> buildFolderUri(String folderKey) async {
|
||||
final machineId = config.machineIdentifier ?? await getMachineIdentifier();
|
||||
if (machineId == null) {
|
||||
throw Exception('Could not get server machine identifier');
|
||||
}
|
||||
return 'server://$machineId/com.plexapp.plugins.library$folderKey';
|
||||
}
|
||||
|
||||
/// Get metadata by rating key with images (includes clearLogo and OnDeck)
|
||||
/// Uses cache when offline or as fallback on network error
|
||||
/// Note: OnDeck data is not relevant for offline mode
|
||||
@@ -702,17 +768,13 @@ class PlexClient {
|
||||
|
||||
/// Get on deck items (continue watching, filtered to video content only)
|
||||
Future<List<PlexMetadata>> getOnDeck() async {
|
||||
final response = await _dio.get('/library/onDeck');
|
||||
final container = _getMediaContainer(response);
|
||||
if (container != null && container['Metadata'] != null) {
|
||||
final allItems = (container['Metadata'] as List)
|
||||
.map((json) => _tagMetadata(PlexMetadata.fromJsonWithImages(json)))
|
||||
.toList();
|
||||
|
||||
// Filter out music content (artists, albums, tracks)
|
||||
return allItems.where((item) => !item.isMusicContent).toList();
|
||||
}
|
||||
return [];
|
||||
final response = await _dio.get(
|
||||
'/library/onDeck',
|
||||
options: Options(responseType: ResponseType.plain),
|
||||
);
|
||||
final sid = serverId;
|
||||
final sname = serverName;
|
||||
return Isolate.run(() => _processOnDeckResponse(response.data as String, sid, sname));
|
||||
}
|
||||
|
||||
/// Get on deck items filtered by a specific library section
|
||||
@@ -945,7 +1007,7 @@ class PlexClient {
|
||||
}
|
||||
}
|
||||
|
||||
return PlaybackExtras(chapters: chapters, markers: markers);
|
||||
return PlaybackExtras.withChapterFallback(chapters: chapters, markers: markers);
|
||||
}
|
||||
|
||||
/// Get consolidated video playback data (URL, media info, versions, and markers) in a single API call.
|
||||
@@ -1177,6 +1239,19 @@ class PlexClient {
|
||||
await _dio.put('/actions/removeFromContinueWatching', queryParameters: {'ratingKey': ratingKey});
|
||||
}
|
||||
|
||||
/// Rate a media item (0.0-10.0 scale, where each integer = half a star)
|
||||
/// Pass -1 to clear an existing rating
|
||||
Future<bool> rateItem(String ratingKey, double rating) {
|
||||
return _wrapBoolApiCall(
|
||||
() => _dio.put('/:/rate', queryParameters: {
|
||||
'key': ratingKey,
|
||||
'identifier': 'com.plexapp.plugins.library',
|
||||
'rating': rating,
|
||||
}),
|
||||
'Failed to rate item',
|
||||
);
|
||||
}
|
||||
|
||||
/// Delete a media item from the library
|
||||
/// This permanently removes the item and its associated files from the server
|
||||
/// Returns true if deletion was successful, false otherwise
|
||||
@@ -1292,44 +1367,11 @@ class PlexClient {
|
||||
final response = await _dio.get(
|
||||
'/hubs/sections/$sectionId',
|
||||
queryParameters: {'count': limit, 'includeGuids': 1},
|
||||
options: Options(responseType: ResponseType.plain),
|
||||
);
|
||||
|
||||
final container = _getMediaContainer(response);
|
||||
if (container != null && container['Hub'] != null) {
|
||||
final hubs = <PlexHub>[];
|
||||
for (final hubJson in container['Hub'] as List) {
|
||||
try {
|
||||
final hub = PlexHub.fromJson(hubJson);
|
||||
// Only include hubs that have items and are movie/show content
|
||||
if (hub.items.isNotEmpty) {
|
||||
// Filter to only video content (movies, shows, seasons, episodes) and tag with server info
|
||||
final videoItems = hub.items
|
||||
.where((item) => item.isVideoContent)
|
||||
.map((item) => item.copyWith(serverId: serverId, serverName: serverName))
|
||||
.toList();
|
||||
|
||||
if (videoItems.isNotEmpty) {
|
||||
hubs.add(
|
||||
PlexHub(
|
||||
hubKey: hub.hubKey,
|
||||
title: hub.title,
|
||||
type: hub.type,
|
||||
hubIdentifier: hub.hubIdentifier,
|
||||
size: hub.size,
|
||||
more: hub.more,
|
||||
items: videoItems,
|
||||
serverId: serverId,
|
||||
serverName: serverName,
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
appLogger.w('Failed to parse hub', error: e);
|
||||
}
|
||||
}
|
||||
return hubs;
|
||||
}
|
||||
final sid = serverId;
|
||||
final sname = serverName;
|
||||
return Isolate.run(() => _processHubResponse(response.data as String, sid, sname));
|
||||
} catch (e) {
|
||||
appLogger.e('Failed to get library hubs: $e');
|
||||
}
|
||||
@@ -1341,43 +1383,14 @@ class PlexClient {
|
||||
/// This matches the official Plex client's home page layout.
|
||||
Future<List<PlexHub>> getGlobalHubs({int limit = 10}) async {
|
||||
try {
|
||||
final response = await _dio.get('/hubs', queryParameters: {'count': limit, 'includeGuids': 1});
|
||||
|
||||
final container = _getMediaContainer(response);
|
||||
if (container != null && container['Hub'] != null) {
|
||||
final hubs = <PlexHub>[];
|
||||
for (final hubJson in container['Hub'] as List) {
|
||||
try {
|
||||
final hub = PlexHub.fromJson(hubJson);
|
||||
if (hub.items.isEmpty) continue;
|
||||
|
||||
// Filter to only video content (movies, shows, seasons, episodes) and tag with server info
|
||||
final videoItems = hub.items
|
||||
.where((item) => item.isVideoContent)
|
||||
.map((item) => item.copyWith(serverId: serverId, serverName: serverName))
|
||||
.toList();
|
||||
|
||||
if (videoItems.isNotEmpty) {
|
||||
hubs.add(
|
||||
PlexHub(
|
||||
hubKey: hub.hubKey,
|
||||
title: hub.title,
|
||||
type: hub.type,
|
||||
hubIdentifier: hub.hubIdentifier,
|
||||
size: hub.size,
|
||||
more: hub.more,
|
||||
items: videoItems,
|
||||
serverId: serverId,
|
||||
serverName: serverName,
|
||||
),
|
||||
);
|
||||
}
|
||||
} catch (e) {
|
||||
appLogger.w('Failed to parse global hub', error: e);
|
||||
}
|
||||
}
|
||||
return hubs;
|
||||
}
|
||||
final response = await _dio.get(
|
||||
'/hubs',
|
||||
queryParameters: {'count': limit, 'includeGuids': 1},
|
||||
options: Options(responseType: ResponseType.plain),
|
||||
);
|
||||
final sid = serverId;
|
||||
final sname = serverName;
|
||||
return Isolate.run(() => _processHubResponse(response.data as String, sid, sname));
|
||||
} catch (e) {
|
||||
appLogger.e('Failed to get global hubs: $e');
|
||||
}
|
||||
@@ -1562,6 +1575,94 @@ class PlexClient {
|
||||
);
|
||||
}
|
||||
|
||||
// ============================================================================
|
||||
// Metadata Editing Methods
|
||||
// ============================================================================
|
||||
|
||||
/// Update metadata fields for a media item
|
||||
Future<bool> updateMetadata({
|
||||
required int sectionId,
|
||||
required String ratingKey,
|
||||
required int typeNumber,
|
||||
String? title,
|
||||
String? titleSort,
|
||||
String? originalTitle,
|
||||
String? originallyAvailableAt,
|
||||
String? contentRating,
|
||||
String? studio,
|
||||
String? tagline,
|
||||
String? summary,
|
||||
}) {
|
||||
final queryParams = <String, dynamic>{
|
||||
'type': typeNumber,
|
||||
'id': ratingKey,
|
||||
};
|
||||
|
||||
void addField(String name, String? value) {
|
||||
if (value != null) {
|
||||
queryParams['$name.value'] = value;
|
||||
queryParams['$name.locked'] = '1';
|
||||
}
|
||||
}
|
||||
|
||||
addField('title', title);
|
||||
addField('titleSort', titleSort);
|
||||
addField('originalTitle', originalTitle);
|
||||
addField('originallyAvailableAt', originallyAvailableAt);
|
||||
addField('contentRating', contentRating);
|
||||
addField('studio', studio);
|
||||
addField('tagline', tagline);
|
||||
addField('summary', summary);
|
||||
|
||||
return _wrapBoolApiCall(
|
||||
() => _dio.put('/library/sections/$sectionId/all', queryParameters: queryParams),
|
||||
'Failed to update metadata',
|
||||
);
|
||||
}
|
||||
|
||||
/// Get available artwork (posters or backgrounds) for a media item
|
||||
Future<List<Map<String, dynamic>>> getAvailableArtwork(String ratingKey, String element) async {
|
||||
try {
|
||||
final response = await _dio.get('/library/metadata/$ratingKey/$element');
|
||||
final container = _getMediaContainer(response);
|
||||
if (container != null && container['Metadata'] != null) {
|
||||
return (container['Metadata'] as List).cast<Map<String, dynamic>>();
|
||||
}
|
||||
return [];
|
||||
} catch (e) {
|
||||
appLogger.e('Failed to get available artwork', error: e);
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
/// Set artwork from a URL (can be a Plex internal path or external URL)
|
||||
Future<bool> setArtworkFromUrl(String ratingKey, String element, String url) {
|
||||
return _wrapBoolApiCall(
|
||||
() => _dio.post('/library/metadata/$ratingKey/$element', queryParameters: {'url': url}),
|
||||
'Failed to set artwork from URL',
|
||||
);
|
||||
}
|
||||
|
||||
/// Upload artwork from binary data
|
||||
Future<bool> uploadArtwork(String ratingKey, String element, List<int> bytes) {
|
||||
return _wrapBoolApiCall(
|
||||
() => _dio.post(
|
||||
'/library/metadata/$ratingKey/$element',
|
||||
data: bytes,
|
||||
options: Options(headers: {'Content-Length': bytes.length}),
|
||||
),
|
||||
'Failed to upload artwork',
|
||||
);
|
||||
}
|
||||
|
||||
/// Update per-media advanced preferences
|
||||
Future<bool> updateMetadataPrefs(String ratingKey, Map<String, String> prefs) {
|
||||
return _wrapBoolApiCall(
|
||||
() => _dio.put('/library/metadata/$ratingKey/prefs', queryParameters: prefs),
|
||||
'Failed to update metadata preferences',
|
||||
);
|
||||
}
|
||||
|
||||
// ============================================================================
|
||||
// Collection Methods
|
||||
// ============================================================================
|
||||
@@ -2037,6 +2138,7 @@ class PlexClient {
|
||||
.where((ch) => ch.key.isNotEmpty)
|
||||
.toList();
|
||||
}
|
||||
appLogger.d('EPG channels: container keys=${container?.keys.toList()}, size=${container?['size']}');
|
||||
return [];
|
||||
}, 'Failed to get EPG channels');
|
||||
}
|
||||
|
||||
@@ -20,6 +20,7 @@ class SettingsService extends BaseSharedPreferencesService {
|
||||
static const String _keyThemeMode = 'theme_mode';
|
||||
static const String _keyEnableDebugLogging = 'enable_debug_logging';
|
||||
static const String _keyBufferSize = 'buffer_size';
|
||||
static const String _keyBufferSizeMigratedToAuto = 'buffer_size_migrated_to_auto';
|
||||
static const String _keyKeyboardShortcuts = 'keyboard_shortcuts';
|
||||
static const String _keyKeyboardHotkeys = 'keyboard_hotkeys';
|
||||
static const String _keyEnableHardwareDecoding = 'enable_hardware_decoding';
|
||||
@@ -75,6 +76,7 @@ class SettingsService extends BaseSharedPreferencesService {
|
||||
static const String _keySelectedExternalPlayer = 'selected_external_player';
|
||||
static const String _keyCustomExternalPlayers = 'custom_external_players';
|
||||
static const String _keyConfirmExitOnBack = 'confirm_exit_on_back';
|
||||
static const String _keyAmbientLighting = 'ambient_lighting';
|
||||
|
||||
SettingsService._();
|
||||
|
||||
@@ -120,7 +122,14 @@ class SettingsService extends BaseSharedPreferencesService {
|
||||
}
|
||||
|
||||
int getBufferSize() {
|
||||
return prefs.getInt(_keyBufferSize) ?? 128; // Default 128MB
|
||||
// One-time migration: reset existing users to Auto.
|
||||
// SharedPreferences updates in-memory cache synchronously, so the
|
||||
// unawaited disk-flush futures are safe here (idempotent if re-run).
|
||||
if (prefs.getBool(_keyBufferSizeMigratedToAuto) != true) {
|
||||
prefs.remove(_keyBufferSize);
|
||||
prefs.setBool(_keyBufferSizeMigratedToAuto, true);
|
||||
}
|
||||
return prefs.getInt(_keyBufferSize) ?? 0; // 0 = Auto
|
||||
}
|
||||
|
||||
// Hardware Decoding
|
||||
@@ -1117,6 +1126,15 @@ class SettingsService extends BaseSharedPreferencesService {
|
||||
return prefs.getBool(_keyConfirmExitOnBack) ?? true; // Default: enabled
|
||||
}
|
||||
|
||||
// Ambient Lighting
|
||||
Future<void> setAmbientLighting(bool enabled) async {
|
||||
await prefs.setBool(_keyAmbientLighting, enabled);
|
||||
}
|
||||
|
||||
bool getAmbientLighting() {
|
||||
return prefs.getBool(_keyAmbientLighting) ?? false;
|
||||
}
|
||||
|
||||
// Reset all settings to defaults
|
||||
Future<void> resetAllSettings() async {
|
||||
await Future.wait([
|
||||
@@ -1171,6 +1189,8 @@ class SettingsService extends BaseSharedPreferencesService {
|
||||
prefs.remove(_keySelectedExternalPlayer),
|
||||
prefs.remove(_keyCustomExternalPlayers),
|
||||
prefs.remove(_keyConfirmExitOnBack),
|
||||
prefs.remove(_keyAmbientLighting),
|
||||
prefs.remove(_keyBufferSizeMigratedToAuto),
|
||||
]);
|
||||
}
|
||||
|
||||
|
||||
@@ -2,15 +2,21 @@ import 'package:flutter/foundation.dart';
|
||||
|
||||
import '../models/shader_preset.dart';
|
||||
import '../mpv/player/player.dart';
|
||||
import 'ambient_lighting_service.dart';
|
||||
import 'shader_asset_loader.dart';
|
||||
|
||||
/// Service for applying GLSL shaders to the MPV video player.
|
||||
///
|
||||
/// Handles shader chain building, HDR detection, and runtime switching.
|
||||
/// When ambient lighting is active, the ambient lighting shader is always appended last
|
||||
/// in the chain after any upscaling/processing shaders.
|
||||
class ShaderService {
|
||||
final Player _player;
|
||||
ShaderPreset _currentPreset = ShaderPreset.none;
|
||||
|
||||
/// Reference to ambient lighting service for re-appending its shader after chain rebuilds.
|
||||
AmbientLightingService? ambientLightingService;
|
||||
|
||||
ShaderService(this._player);
|
||||
|
||||
/// The currently applied shader preset
|
||||
@@ -41,6 +47,7 @@ class ShaderService {
|
||||
}
|
||||
await _clearShaders();
|
||||
_currentPreset = ShaderPreset.none;
|
||||
await _reappendAmbientLighting();
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -52,6 +59,7 @@ class ShaderService {
|
||||
// No shaders - clear any existing ones
|
||||
await _clearShaders();
|
||||
_currentPreset = preset;
|
||||
await _reappendAmbientLighting();
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -65,6 +73,9 @@ class ShaderService {
|
||||
|
||||
_currentPreset = preset;
|
||||
|
||||
// Re-append ambient lighting shader at end of chain
|
||||
await _reappendAmbientLighting();
|
||||
|
||||
if (kDebugMode) {
|
||||
debugPrint('ShaderService: Applied ${preset.name} with ${shaderPaths.length} shaders');
|
||||
}
|
||||
@@ -87,6 +98,21 @@ class ShaderService {
|
||||
}
|
||||
}
|
||||
|
||||
/// Re-append the ambient lighting shader if it's active.
|
||||
/// Called after shader chain rebuilds to keep ambient lighting last.
|
||||
Future<void> _reappendAmbientLighting() async {
|
||||
final service = ambientLightingService;
|
||||
if (service == null || !service.isEnabled) return;
|
||||
|
||||
try {
|
||||
await service.reappendShader();
|
||||
} catch (e) {
|
||||
if (kDebugMode) {
|
||||
debugPrint('ShaderService: Failed to re-append ambient lighting: $e');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// Check if the current video content is HDR.
|
||||
Future<bool> _isHdrContent() async {
|
||||
try {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user