Create Kaleido Desktop, a cinematic Plex client for Windows
Tauri 2 shell with a React/TypeScript interface and libmpv playback composed beneath the web view (DirectComposition on Windows). Shared code with per-OS platform modules and configs so macOS and Linux can follow. - Plex sign-in (browser, plex.tv/link or manual), server selection, Plex Home - Home, Movies and TV Shows (Discover, Library, Collections), search, people - Title pages with logos, ratings, cast, extras, seasons and episodes - Direct play with Plex conversion fallback, tracks, markers, autoplay - Metadata editing, artwork, fix match, refresh, analyze and deletion - Resumable offline downloads - App settings and Plex server administration with a live dashboard - Signed updater feed and Forgejo CI Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
commit
00d72e70f4
121 changed files with 25315 additions and 0 deletions
31
src-tauri/src/platform/macos.rs
Normal file
31
src-tauri/src/platform/macos.rs
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
//! macOS: render mpv through its render API (libplacebo) into a CAMetalLayer
|
||||
//! placed beneath the WKWebView, then implement `VideoSurface` here.
|
||||
//!
|
||||
//! Browsing, downloads, settings and updates already work here; only native
|
||||
//! video composition remains to be written.
|
||||
|
||||
use tauri::{Runtime, WebviewWindow};
|
||||
|
||||
use crate::mpv::Mpv;
|
||||
|
||||
pub const SURFACE_PROPERTIES: &[&str] = &[];
|
||||
pub const MPV_LIBRARIES: &[&str] = &["libmpv.2.dylib", "libmpv.dylib"];
|
||||
|
||||
pub struct VideoSurface;
|
||||
|
||||
impl VideoSurface {
|
||||
pub fn create<R: Runtime>(_: &WebviewWindow<R>) -> Result<VideoSurface, String> {
|
||||
Err("Video playback is not available on this platform yet.".into())
|
||||
}
|
||||
pub fn mpv_options(&self) -> Vec<(&'static str, String)> {
|
||||
Vec::new()
|
||||
}
|
||||
pub fn on_property(&mut self, _: &str, _: &serde_json::Value) {}
|
||||
pub fn show(&mut self, _: bool) {}
|
||||
pub fn fit<R: Runtime>(&mut self, _: &WebviewWindow<R>, _: Option<&Mpv>) {}
|
||||
}
|
||||
|
||||
pub fn hold_awake(rx: std::sync::mpsc::Receiver<()>) {
|
||||
// TODO(macOS): IOPMAssertionCreateWithName(PreventUserIdleDisplaySleep).
|
||||
let _ = rx.recv();
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue