harmony 鸿蒙杂散软件服务子系统JS API变更
杂散软件服务子系统JS API变更
OpenHarmony 3.2 Beta3版本相较于OpenHarmony 3.2 Beta2版本,杂散软件服务子系统的API变更如下:
接口变更
模块名 | 方法/事件名 | 方法/属性/枚举/常量 | 变更类型 |
---|---|---|---|
ohos.inputmethod | InputMethodController | hideSoftKeyboard(callback: AsyncCallback<void>): void; hideSoftKeyboard():Promise<void>; |
新增 |
ohos.inputmethod | InputMethodController | showSoftKeyboard(callback: AsyncCallback<void>): void; showSoftKeyboard():Promise<void>; |
新增 |
ohos.inputmethod | inputMethod | getCurrentInputMethod(): InputMethodProperty; | 新增 |
ohos.inputmethodengine | TextInputClient | moveCursor(direction: number, callback: AsyncCallback<void>): void; moveCursor(direction: number): Promise<void>; |
新增 |
ohos.inputmethodengine | InputMethodEngine | off(type: ‘setCallingWindow’, callback: (wid:number) => void): void; | 新增 |
ohos.inputmethodengine | InputMethodEngine | on(type: ‘setCallingWindow’, callback: (wid:number) => void): void; | 新增 |
ohos.inputmethodengine | InputMethodEngine | off(type: ‘inputStop’, callback: () => void): void; | 新增 |
ohos.inputmethodengine | InputMethodEngine | on(type: ‘inputStop’, callback: () => void): void; | 新增 |
ohos.inputmethodengine | inputMethodEngine | const WINDOW_TYPE_INPUT_METHOD_FLOAT: number; | 新增 |
ohos.inputmethodengine | inputMethodEngine | const CURSOR_RIGHT: number; | 新增 |
ohos.inputmethodengine | inputMethodEngine | const CURSOR_LEFT: number; | 新增 |
ohos.inputmethodengine | inputMethodEngine | const CURSOR_DOWN: number; | 新增 |
ohos.inputmethodengine | inputMethodEngine | const CURSOR_UP: number; | 新增 |
ohos.inputmethodextensionability | InputMethodExtensionAbility | onDestroy(): void; | 新增 |
ohos.inputmethodextensionability | InputMethodExtensionAbility | onCreate(want: Want): void; | 新增 |
ohos.inputmethodextensionability | InputMethodExtensionAbility | context: InputMethodExtensionContext; | 新增 |
ohos.inputmethodextensioncontext | InputMethodExtensionContext | terminateSelf(callback: AsyncCallback<void>): void; terminateSelf(): Promise<void>; |
新增 |
ohos.inputmethodextensioncontext | InputMethodExtensionContext | startAbility(want: Want, callback: AsyncCallback<void>): void; startAbility(want: Want, options: StartOptions, callback: AsyncCallback<void>): void; startAbility(want: Want, options?: StartOptions): Promise<void>; |
新增 |
ohos.pasteboard | PasteData | setProperty(property: PasteDataProperty): void; | 新增 |
ohos.pasteboard | PasteData | getPrimaryPixelMap(): image.PixelMap; | 新增 |
ohos.pasteboard | PasteData | addPixelMapRecord(pixelMap: image.PixelMap): void; | 新增 |
ohos.pasteboard | PasteDataRecord | data: { [mimeType: string]: ArrayBuffer } | 新增 |
ohos.pasteboard | PasteDataRecord | pixelMap: image.PixelMap; | 新增 |
ohos.pasteboard | PasteDataProperty | shareOption: ShareOption; | 新增 |
ohos.pasteboard | ShareOption | CrossDevice | 新增 |
ohos.pasteboard | ShareOption | LocalDevice | 新增 |
ohos.pasteboard | ShareOption | InApp | 新增 |
ohos.pasteboard | pasteboard | createRecord(mimeType: string, value: ArrayBuffer):PasteDataRecord; | 新增 |
ohos.pasteboard | pasteboard | createPixelMapRecord(pixelMap: image.PixelMap):PasteDataRecord; | 新增 |
ohos.pasteboard | pasteboard | createData(mimeType: string, value: ArrayBuffer): PasteData; | 新增 |
ohos.pasteboard | pasteboard | createPixelMapData(pixelMap: image.PixelMap): PasteData; | 新增 |
ohos.pasteboard | pasteboard | const MIMETYPE_PIXELMAP: string; | 新增 |
ohos.request | UploadTask | off(type:‘complete’ |‘fail’, callback?: Callback<Array<TaskState>>): void; | 新增 |
ohos.request | UploadTask | off(type:‘complete’ |‘fail’, callback?: Callback<Array<TaskState>>): void; | 新增 |
ohos.request | UploadTask | on(type:‘complete’ |‘fail’, callback: Callback<Array<TaskState>>): void; | 新增 |
ohos.request | UploadTask | on(type:‘complete’ |‘fail’, callback: Callback<Array<TaskState>>): void; | 新增 |
ohos.request | TaskState | message: string; | 新增 |
ohos.request | TaskState | responseCode: number; | 新增 |
ohos.request | TaskState | path: string; | 新增 |
ohos.request | DownloadConfig | background?: boolean; | 新增 |
ohos.screenLock | screenLock | onSystemEvent(callback: Callback<SystemEvent>): boolean; | 新增 |
ohos.screenLock | SystemEvent | params: string | 新增 |
ohos.screenLock | SystemEvent | eventType: EventType, | 新增 |
ohos.screenLock | screenLock | lockScreen(callback: AsyncCallback<boolean>): void; lockScreen():Promise<boolean>; |
新增 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | off(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’ |‘screenlockEnabled’ |‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘screenlockEnabled’, callback: Callback<boolean>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<number>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<number>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginSleep’ |‘endSleep’ |‘changeUser’, callback: Callback<number>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’, callback: Callback<void>): void; | 删除 |
ohos.screenLock | screenLock | on(type: ‘beginWakeUp’ |‘endWakeUp’ |‘beginScreenOn’ |‘endScreenOn’ |‘beginScreenOff’ |‘endScreenOff’ |‘unlockScreen’ |‘beginExitAnimation’, callback: Callback<void>): void; | 删除 |
你可能感兴趣的鸿蒙文章
0
赞
- 所属分类: 后端技术
- 本文标签:
热门推荐
-
2、 - 优质文章
-
3、 gate.io
-
8、 golang
-
9、 openharmony
-
10、 Vue中input框自动聚焦