fix: query status bar height on Android, closes #943 (#947)

This commit is contained in:
Huang Xin
2025-04-23 20:01:37 +08:00
committed by GitHub
parent ad551a04a1
commit 172ab382bc
19 changed files with 148 additions and 20 deletions
+12
View File
@@ -33,6 +33,11 @@ export interface SetSystemUIVisibilityResponse {
error?: string;
}
export interface GetStatusBarHeightResponse {
height: number;
error?: string;
}
export async function copyURIToPath(request: CopyURIRequest): Promise<CopyURIResponse> {
const result = await invoke<CopyURIResponse>('plugin:native-bridge|copy_uri_to_path', {
payload: request,
@@ -67,3 +72,10 @@ export async function setSystemUIVisibility(
);
return result;
}
export async function getStatusBarHeight(): Promise<GetStatusBarHeightResponse> {
const result = await invoke<GetStatusBarHeightResponse>(
'plugin:native-bridge|get_status_bar_height',
);
return result;
}