mirror of
https://github.com/Stremio/stremio-shell-ng.git
synced 2026-03-11 13:05:49 +00:00
This commit is contained in:
parent
07d821012d
commit
15069204be
4 changed files with 18 additions and 5 deletions
14
Cargo.lock
generated
14
Cargo.lock
generated
|
|
@ -1598,7 +1598,7 @@ dependencies = [
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "stremio-shell-ng"
|
name = "stremio-shell-ng"
|
||||||
version = "5.0.16"
|
version = "5.0.17"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"anyhow",
|
"anyhow",
|
||||||
"bitflags 2.4.2",
|
"bitflags 2.4.2",
|
||||||
|
|
@ -1621,6 +1621,7 @@ dependencies = [
|
||||||
"sha2",
|
"sha2",
|
||||||
"url",
|
"url",
|
||||||
"urlencoding",
|
"urlencoding",
|
||||||
|
"uuid",
|
||||||
"webview2",
|
"webview2",
|
||||||
"webview2-sys",
|
"webview2-sys",
|
||||||
"whoami",
|
"whoami",
|
||||||
|
|
@ -1964,6 +1965,17 @@ version = "0.2.1"
|
||||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a"
|
checksum = "711b9620af191e0cdc7468a8d14e709c3dcdb115b36f838e601583af800a370a"
|
||||||
|
|
||||||
|
[[package]]
|
||||||
|
name = "uuid"
|
||||||
|
version = "1.20.0"
|
||||||
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||||
|
checksum = "ee48d38b119b0cd71fe4141b30f5ba9c7c5d9f4e7a3a8b4a674e4b6ef789976f"
|
||||||
|
dependencies = [
|
||||||
|
"getrandom 0.3.3",
|
||||||
|
"js-sys",
|
||||||
|
"wasm-bindgen",
|
||||||
|
]
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "vcpkg"
|
name = "vcpkg"
|
||||||
version = "0.2.15"
|
version = "0.2.15"
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
[package]
|
[package]
|
||||||
name = "stremio-shell-ng"
|
name = "stremio-shell-ng"
|
||||||
version = "5.0.16"
|
version = "5.0.17"
|
||||||
edition = "2018"
|
edition = "2018"
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
|
|
|
||||||
|
|
@ -16,6 +16,6 @@ $thread = Start-ThreadJob -InputObject ($pw) -ScriptBlock {
|
||||||
}
|
}
|
||||||
|
|
||||||
cargo build --release --target x86_64-pc-windows-msvc
|
cargo build --release --target x86_64-pc-windows-msvc
|
||||||
& "C:\Program Files (x86)\Inno Setup 6\ISCC.exe" /DSIGN "/Sstremiosign=`$qC:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x86\signtool.exe`$q sign /fd SHA256 /t http://timestamp.digicert.com /n `$qSmart Code OOD`$q `$f" "setup\Stremio.iss"
|
& "C:\Program Files (x86)\Inno Setup 6\ISCC.exe" /DSIGN "/Sstremiosign=`$qsigntool`$q sign /fd SHA256 /t http://timestamp.digicert.com /n `$qSmart Code OOD`$q `$f" "setup\Stremio.iss"
|
||||||
|
|
||||||
Stop-Job -Job $thread
|
Stop-Job -Job $thread
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,4 @@
|
||||||
|
use crate::stremio_app::constants::SERVER_IPC_KEY;
|
||||||
use crate::stremio_app::ipc;
|
use crate::stremio_app::ipc;
|
||||||
use native_windows_gui::{self as nwg, PartialUi};
|
use native_windows_gui::{self as nwg, PartialUi};
|
||||||
use once_cell::unsync::OnceCell;
|
use once_cell::unsync::OnceCell;
|
||||||
|
|
@ -15,7 +16,7 @@ use webview2::Controller;
|
||||||
use winapi::shared::windef::HWND;
|
use winapi::shared::windef::HWND;
|
||||||
use winapi::um::winuser::{GetClientRect, VK_F7, WM_SETFOCUS};
|
use winapi::um::winuser::{GetClientRect, VK_F7, WM_SETFOCUS};
|
||||||
|
|
||||||
use super::constants::{SERVER_IPC_KEY, WARNING_URL, WHITELISTED_HOSTS};
|
use super::constants::{WARNING_URL, WHITELISTED_HOSTS};
|
||||||
|
|
||||||
#[derive(Default)]
|
#[derive(Default)]
|
||||||
pub struct WebView {
|
pub struct WebView {
|
||||||
|
|
@ -156,7 +157,7 @@ impl PartialUi for WebView {
|
||||||
wv.execute_script(format!(
|
wv.execute_script(format!(
|
||||||
"window.stremio_server_ipc_key='{}'",
|
"window.stremio_server_ipc_key='{}'",
|
||||||
std::env::var(SERVER_IPC_KEY).unwrap_or_default()
|
std::env::var(SERVER_IPC_KEY).unwrap_or_default()
|
||||||
), |_| Ok(())
|
).as_str(), |_| Ok(())
|
||||||
).expect("Cannot add SERVER_IPC_KEY to webview");
|
).expect("Cannot add SERVER_IPC_KEY to webview");
|
||||||
|
|
||||||
wv.execute_script(r##"
|
wv.execute_script(r##"
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue