Skip to content
Open

Ldc1 #800

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
57 commits
Select commit Hold shift + click to select a range
e355a35
vcoder base upload
Apr 24, 2026
5da4128
rm hnp
Apr 24, 2026
44ad98f
Merge branch 'GCWing:main' into main
SWangHash Apr 26, 2026
ea7b3ae
modify path_manager
Apr 25, 2026
ca8749c
adapt ohos
Apr 25, 2026
bf7895e
update storage
Apr 25, 2026
337f346
compile fix
Apr 27, 2026
c62603d
Merge pull request #1 from SWangHash/ljl
SWangHash Apr 27, 2026
3fd3500
compile fix
Apr 27, 2026
e395caf
move vcoder to apps
Apr 27, 2026
dd3c031
Merge pull request #2 from SWangHash/ljl
SWangHash Apr 27, 2026
c07d975
compile fix
Apr 28, 2026
506986d
Merge pull request #3 from SWangHash/ljl
SWangHash Apr 28, 2026
9a54bf4
fix white screen
Apr 28, 2026
27e1cf3
Merge pull request #4 from SWangHash/ljl
SWangHash Apr 28, 2026
d962ec9
feat: add Harmony build tool and bump-to-interact feature
SWangHash Apr 27, 2026
a368b88
Merge pull request #6 from SWangHash/hly_branch
SWangHash Apr 29, 2026
7010ab8
adapt oh filePicker
Apr 29, 2026
35d68e3
Merge pull request #7 from SWangHash/zz/filepicker
SWangHash Apr 30, 2026
6d88bb5
default terminal use bash
Apr 30, 2026
936d600
Merge pull request #8 from SWangHash/zz/filepicker
SWangHash Apr 30, 2026
9547b56
change import
Apr 28, 2026
5f9b234
Merge pull request #5 from SWangHash/ljl
SWangHash Apr 30, 2026
d34930c
fix log path
SWangHash Apr 30, 2026
9617a39
Merge pull request #9 from SWangHash/hly_branch
SWangHash Apr 30, 2026
419122c
adapt theme
Apr 30, 2026
6099467
Merge pull request #10 from SWangHash/zz/theme
SWangHash Apr 30, 2026
64de5f0
zsh adapt && remote unused permissions
May 7, 2026
a5f5fce
Merge pull request #11 from SWangHash/ljl
SWangHash May 7, 2026
a283fa8
fix knock share issue.
SWangHash May 7, 2026
29d8160
Merge pull request #12 from SWangHash/hly_branch
SWangHash May 7, 2026
1fd08f2
adapt window move
May 8, 2026
ea4f5ff
Merge pull request #13 from SWangHash/zz/move
SWangHash May 8, 2026
52e07a8
Merge remote-tracking branch 'upstream/main'
SWangHash May 8, 2026
49ab57f
Merge pull request #15 from SWangHash/wc/bugfix
SWangHash May 8, 2026
aa1ace0
Fix the issue of url not opening
SWangHash May 9, 2026
06997bb
Merge pull request #16 from SWangHash/hly_branch
SWangHash May 9, 2026
6306559
feat: populate about dialog open-source and user-agreement pages
SWangHash May 11, 2026
7e6f169
Merge pull request #17 from SWangHash/hly_branch
SWangHash May 12, 2026
08cc090
fix knock share issue.
SWangHash May 12, 2026
cad9230
Merge pull request #18 from SWangHash/hly_branch
SWangHash May 12, 2026
bda3aee
use bash first
May 13, 2026
c8121fb
Merge pull request #19 from SWangHash/ljl
SWangHash May 13, 2026
c726dfd
Merge remote-tracking branch 'upstream/main' into rebase
SWangHash May 16, 2026
88a28cd
Merge pull request #37 from SWangHash/rebase
SWangHash May 16, 2026
bafc7b0
built-in remote resources
SWangHash May 13, 2026
95f441c
feat: update privacy agreement, format skill path display
SWangHash May 14, 2026
971ca61
[fix] Cancel the image export function
SWangHash May 17, 2026
c4881a0
[fix] Fix breadcrumb path issue
SWangHash May 18, 2026
67bd53b
Merge pull request #20 from SWangHash/hly_branch
SWangHash May 19, 2026
66f257c
remove indent in editor && fix expand in notification
May 18, 2026
1aaabc9
Merge pull request #38 from SWangHash/ljl
SWangHash May 19, 2026
2bfec88
fix esc
May 19, 2026
9297a03
Merge pull request #39 from SWangHash/zz/fix-esc
SWangHash May 19, 2026
6bdab44
fix click expanded
May 19, 2026
164e25b
Merge pull request #40 from SWangHash/zz/fix-click
SWangHash May 19, 2026
cd62f82
add copy menu bug
ldc111 May 19, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 16 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ toml = "0.8"
git2 = { version = "0.18", default-features = false, features = ["https", "vendored-libgit2"] }

# Terminal
portable-pty = "0.8"
portable-pty = "0.9.0"
vte = "0.15.0"

# Grep (search)
Expand All @@ -113,15 +113,17 @@ similar = "2.5"
urlencoding = "2.1"

# Tauri (desktop only)
tauri = { version = "2", features = ["unstable", "macos-private-api", "tray-icon"] }
tauri = { git = "https://github.com/richerfu/tauri", branch = "feat/open-harmony", features = [] }
tauri-plugin-dialog = "2"
tauri-plugin-opener = "2"
tauri-plugin-dialog = "2.6"
tauri-plugin-fs = "2"
tauri-plugin-log = "2"
tauri-plugin-autostart = "2"
tauri-plugin-notification = "2"
tauri-plugin-updater = "2"
tauri-build = { version = "2", features = [] }
tauri-build = { git = "https://github.com/richerfu/tauri", branch = "feat/open-harmony", features = [] }
napi-ohos = { version = "1.1" }
napi-derive-ohos = { version = "1.1" }

# Windows-specific dependencies
win32job = "2.0"
Expand Down Expand Up @@ -163,3 +165,13 @@ lto = false
codegen-units = 16
strip = false
incremental = true

[patch.crates-io]
wry = { git = "https://github.com/richerfu/wry"}
tao = { git = "https://github.com/richerfu/tao", branch = "feat-ohos-webview"}
openharmony-ability = {git = "https://github.com/harmony-contrib/openharmony-ability.git"}
openharmony-ability-derive = {git = "https://github.com/harmony-contrib/openharmony-ability.git"}
tauri = { git = "https://github.com/richerfu/tauri", branch = "feat/open-harmony"}
tauri-runtime = { git = "https://github.com/richerfu/tauri", branch = "feat/open-harmony"}
tauri-macros = { git = "https://github.com/richerfu/tauri", branch = "feat/open-harmony"}
tauri-runtime-wry = { git = "https://github.com/richerfu/tauri", branch = "feat/open-harmony"}
12 changes: 4 additions & 8 deletions src/apps/desktop/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,8 @@ tauri-plugin-opener = { workspace = true }
tauri-plugin-dialog = { workspace = true }
tauri-plugin-fs = { workspace = true }
tauri-plugin-log = { workspace = true }
tauri-plugin-autostart = { workspace = true }
tauri-plugin-notification = { workspace = true }
tauri-plugin-updater = { workspace = true }
napi-ohos = { workspace = true }
napi-derive-ohos = { workspace = true }

# Inherited from workspace
tokio = { workspace = true }
Expand All @@ -44,7 +43,6 @@ chrono = { workspace = true }
uuid = { workspace = true }
regex = { workspace = true }
dirs = { workspace = true }
dark-light = { workspace = true }
similar = { workspace = true }
ignore = { workspace = true }
urlencoding = { workspace = true }
Expand All @@ -54,8 +52,6 @@ thiserror = "1.0"
futures = { workspace = true }
async-trait = { workspace = true }
sha1 = { workspace = true }
screenshots = "0.8"
enigo = "0.2"
image = { version = "0.24", default-features = false, features = ["png", "jpeg"] }
resvg = { version = "0.47.0", default-features = false }

Expand Down Expand Up @@ -90,6 +86,6 @@ default = []
# Never enabled in release profile intended for end users.
devtools = ["tauri/devtools"]

[target.'cfg(target_os = "linux")'.dependencies]
atspi = "0.29"
[target.'cfg(all(target_os = "linux", not(target_env = "ohos")))'.dependencies]
leptess = "0.14.0"
atspi = "0.29"
13 changes: 0 additions & 13 deletions src/apps/desktop/capabilities/browser-webview.json

This file was deleted.

197 changes: 88 additions & 109 deletions src/apps/desktop/capabilities/default.json
Original file line number Diff line number Diff line change
@@ -1,110 +1,89 @@
{
"$schema": "../gen/schemas/desktop-schema.json",
"identifier": "default",
"description": "BitFun default capabilities",
"windows": ["main", "agent-companion-pet"],
"permissions": [
"log:default",
"autostart:default",
"core:default",
"core:path:default",
"core:event:default",
"core:event:allow-listen",
"core:event:allow-emit",
"core:window:default",
"core:webview:default",
"core:webview:allow-create-webview",
"core:webview:allow-set-webview-position",
"core:webview:allow-set-webview-size",
"core:webview:allow-set-webview-focus",
"core:webview:allow-reparent",
"core:webview:allow-webview-show",
"core:webview:allow-webview-hide",
"core:webview:allow-webview-close",
"core:window:allow-create",
"core:window:allow-set-focus",
"core:window:allow-set-always-on-top",
"core:window:allow-set-position",
"core:window:allow-set-size",
"core:window:allow-set-decorations",
"core:window:allow-set-title-bar-style",
"core:window:allow-set-skip-taskbar",
"core:window:allow-set-resizable",
"core:window:allow-current-monitor",
"core:window:allow-outer-position",
"core:window:allow-outer-size",
"core:window:allow-is-fullscreen",
"core:window:allow-is-maximized",
"core:window:allow-center",
"core:window:allow-close",
"core:window:allow-hide",
"core:window:allow-maximize",
"core:window:allow-minimize",
"core:window:allow-show",
"core:window:allow-start-dragging",
"core:window:allow-unmaximize",
"core:window:allow-unminimize",
"core:window:allow-set-min-size",
"dialog:default",
"dialog:allow-open",
"dialog:allow-save",
"dialog:allow-ask",
"dialog:allow-confirm",
"dialog:allow-message",
"opener:default",
"opener:allow-open-url",
{
"identifier": "opener:allow-open-path",
"allow": [
{ "path": "$APPDATA/**" },
{ "path": "$HOME/**" }
]
},
"opener:allow-reveal-item-in-dir",
"fs:default",
"fs:allow-read-file",
"fs:allow-write-file",
"fs:allow-read-dir",
"fs:allow-copy-file",
"fs:allow-create",
"fs:allow-mkdir",
"fs:allow-remove",
"fs:allow-rename",
"fs:allow-exists",
"fs:allow-read-text-file",
"fs:allow-write-text-file",
"fs:allow-stat",
"fs:allow-lstat",
"fs:allow-fstat",
"fs:allow-truncate",
"fs:allow-ftruncate",
"fs:allow-open",
"fs:allow-read",
"fs:allow-write",
"fs:allow-seek",
"fs:allow-unwatch",
"fs:allow-watch",
"fs:read-all",
"fs:write-all",
"fs:scope-app-recursive",
{
"identifier": "fs:allow-home-read-recursive",
"allow": [
{ "path": "$HOME/**" }
]
},
{
"identifier": "fs:allow-home-write-recursive",
"allow": [
{ "path": "$HOME/**" }
]
},
"notification:default",
"notification:allow-notify",
"notification:allow-show",
"notification:allow-request-permission",
"notification:allow-check-permissions",
"notification:allow-permission-state",
"notification:allow-is-permission-granted"
]
}
"$schema": "../gen/schemas/desktop-schema.json",
"identifier": "default",
"description": "BitFun default capabilities",
"windows": ["main"],
"permissions": [
"log:default",
"core:default",
"core:path:default",
"core:event:default",
"core:event:allow-listen",
"core:event:allow-emit",
"core:window:default",
"core:webview:default",
"core:webview:allow-create-webview",
"core:webview:allow-set-webview-position",
"core:webview:allow-set-webview-size",
"core:webview:allow-set-webview-focus",
"core:webview:allow-reparent",
"core:webview:allow-webview-show",
"core:webview:allow-webview-hide",
"core:webview:allow-webview-close",
"core:window:allow-create",
"core:window:allow-set-focus",
"core:window:allow-set-always-on-top",
"core:window:allow-set-position",
"core:window:allow-set-size",
"core:window:allow-set-decorations",
"core:window:allow-set-title-bar-style",
"core:window:allow-set-skip-taskbar",
"core:window:allow-set-resizable",
"core:window:allow-current-monitor",
"core:window:allow-outer-position",
"core:window:allow-outer-size",
"core:window:allow-is-maximized",
"core:window:allow-center",
"core:window:allow-close",
"core:window:allow-hide",
"core:window:allow-maximize",
"core:window:allow-minimize",
"core:window:allow-show",
"core:window:allow-start-dragging",
"core:window:allow-unmaximize",
"core:window:allow-unminimize",
"core:window:allow-set-min-size",
"opener:default",
"opener:allow-open-url",
"opener:allow-open-path",
"opener:allow-reveal-item-in-dir",
"fs:default",
"fs:allow-read-file",
"fs:allow-write-file",
"fs:allow-read-dir",
"fs:allow-copy-file",
"fs:allow-create",
"fs:allow-mkdir",
"fs:allow-remove",
"fs:allow-rename",
"fs:allow-exists",
"fs:allow-read-text-file",
"fs:allow-write-text-file",
"fs:allow-stat",
"fs:allow-lstat",
"fs:allow-fstat",
"fs:allow-truncate",
"fs:allow-ftruncate",
"fs:allow-open",
"fs:allow-read",
"fs:allow-write",
"fs:allow-seek",
"fs:allow-unwatch",
"fs:allow-watch",
"fs:read-all",
"fs:write-all",
"fs:scope-app-recursive",
{
"identifier": "fs:allow-home-read-recursive",
"allow": [
{ "path": "$HOME/**" }
]
},
{
"identifier": "fs:allow-home-write-recursive",
"allow": [
{ "path": "$HOME/**" }
]
}
]
}
5 changes: 4 additions & 1 deletion src/apps/desktop/src/api/app_state.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@



//! Application state management

use crate::api::workspace_activation::spawn_workspace_background_warmup;
Expand Down Expand Up @@ -181,7 +184,7 @@ impl AppState {
"worker_host.js not found in any candidate location; \
MiniApp Workers will not start"
);
std::path::PathBuf::from("worker_host.js")
std::path::PathBuf::from("/data/storage/el2/base/files").join("woker_host.js")
}
};
let js_worker_pool = JsWorkerPool::new(path_manager, worker_host_path)
Expand Down
20 changes: 2 additions & 18 deletions src/apps/desktop/src/api/browser_api.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,7 @@ pub async fn browser_webview_eval(
app: tauri::AppHandle,
request: WebviewEvalRequest,
) -> Result<(), String> {
let webview = app
.get_webview(&request.label)
.ok_or_else(|| format!("Webview not found: {}", request.label))?;

webview
.eval(&request.script)
.map_err(|e| format!("eval failed: {e}"))
Err("Webview not found".to_string())
}

#[derive(Debug, Deserialize)]
Expand All @@ -45,15 +39,5 @@ pub async fn browser_get_url(
app: tauri::AppHandle,
request: WebviewLabelRequest,
) -> Result<String, String> {
let webview = app
.get_webview(&request.label)
.ok_or_else(|| format!("Webview not found: {}", request.label))?;

let result = std::panic::catch_unwind(std::panic::AssertUnwindSafe(|| webview.url()));

match result {
Ok(Ok(url)) => Ok(url.to_string()),
Ok(Err(e)) => Err(format!("url failed: {e}")),
Err(_) => Err("url unavailable (webview URL is nil)".to_string()),
}
Err("Url is unavailable (webview URL is nil)".to_string())
}
6 changes: 6 additions & 0 deletions src/apps/desktop/src/api/commands.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2732,6 +2732,12 @@ pub async fn reveal_in_explorer(
))
}
};
#[cfg(target_env = "ohos")]
{
use crate::ohos::ohos_file_system::reveal_in_oh_explorer;
let _ = reveal_in_oh_explorer(path.to_string_lossy().to_string());
return Ok(());
}
if !path.exists() {
return Err(format!("Path does not exist: {}", request.path));
}
Expand Down
Loading