91 lines
2.7 KiB
TypeScript
91 lines
2.7 KiB
TypeScript
// Cynhyrchwyd y ffeil hon yn awtomatig. PEIDIWCH Â MODIWL
|
|
// This file is automatically generated. DO NOT EDIT
|
|
|
|
/**
|
|
* HotkeyService 全局热键服务
|
|
* @module
|
|
*/
|
|
|
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
// @ts-ignore: Unused imports
|
|
import {Call as $Call, Create as $Create} from "@wailsio/runtime";
|
|
|
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
// @ts-ignore: Unused imports
|
|
import * as application$0 from "../../../github.com/wailsapp/wails/v3/pkg/application/models.js";
|
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
// @ts-ignore: Unused imports
|
|
import * as models$0 from "../models/models.js";
|
|
|
|
/**
|
|
* GetCurrentHotkey 获取当前热键
|
|
*/
|
|
export function GetCurrentHotkey(): Promise<models$0.HotkeyCombo | null> & { cancel(): void } {
|
|
let $resultPromise = $Call.ByID(2572811187) as any;
|
|
let $typingPromise = $resultPromise.then(($result: any) => {
|
|
return $$createType1($result);
|
|
}) as any;
|
|
$typingPromise.cancel = $resultPromise.cancel.bind($resultPromise);
|
|
return $typingPromise;
|
|
}
|
|
|
|
/**
|
|
* Initialize 初始化热键服务
|
|
*/
|
|
export function Initialize(): Promise<void> & { cancel(): void } {
|
|
let $resultPromise = $Call.ByID(3671360458) as any;
|
|
return $resultPromise;
|
|
}
|
|
|
|
/**
|
|
* IsRegistered 检查是否已注册
|
|
*/
|
|
export function IsRegistered(): Promise<boolean> & { cancel(): void } {
|
|
let $resultPromise = $Call.ByID(106954156) as any;
|
|
return $resultPromise;
|
|
}
|
|
|
|
/**
|
|
* RegisterHotkey 注册全局热键
|
|
*/
|
|
export function RegisterHotkey(combo: models$0.HotkeyCombo | null): Promise<void> & { cancel(): void } {
|
|
let $resultPromise = $Call.ByID(1103945691, combo) as any;
|
|
return $resultPromise;
|
|
}
|
|
|
|
/**
|
|
* ServiceShutdown 关闭服务
|
|
*/
|
|
export function ServiceShutdown(): Promise<void> & { cancel(): void } {
|
|
let $resultPromise = $Call.ByID(157291181) as any;
|
|
return $resultPromise;
|
|
}
|
|
|
|
/**
|
|
* ServiceStartup 服务启动时初始化
|
|
*/
|
|
export function ServiceStartup(options: application$0.ServiceOptions): Promise<void> & { cancel(): void } {
|
|
let $resultPromise = $Call.ByID(3079990808, options) as any;
|
|
return $resultPromise;
|
|
}
|
|
|
|
/**
|
|
* UnregisterHotkey 取消注册全局热键
|
|
*/
|
|
export function UnregisterHotkey(): Promise<void> & { cancel(): void } {
|
|
let $resultPromise = $Call.ByID(3544283732) as any;
|
|
return $resultPromise;
|
|
}
|
|
|
|
/**
|
|
* UpdateHotkey 更新热键配置
|
|
*/
|
|
export function UpdateHotkey(enable: boolean, combo: models$0.HotkeyCombo | null): Promise<void> & { cancel(): void } {
|
|
let $resultPromise = $Call.ByID(823285555, enable, combo) as any;
|
|
return $resultPromise;
|
|
}
|
|
|
|
// Private type creation functions
|
|
const $$createType0 = models$0.HotkeyCombo.createFrom;
|
|
const $$createType1 = $Create.Nullable($$createType0);
|