mirror of
https://github.com/openharmony/applications_notes.git
synced 2026-07-19 13:16:40 -04:00
fix onbackpress return type, fix note edit input method behavior
Signed-off-by: guozejun <guozejun@huawei.com>
This commit is contained in:
@@ -93,7 +93,7 @@ export struct MyNoteHomeComp {
|
||||
this.refreshFlag = (this.refreshFlag == 0 ? 1 : 0)
|
||||
}
|
||||
|
||||
onBackPress():void{
|
||||
onBackPress() {
|
||||
LogUtil.info(this.TAG, "onBackPress")
|
||||
// 退出键盘
|
||||
inputMethod.getInputMethodController().stopInput();
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
import {NoteContent} from '@ohos/component/src/main/ets/components/NoteContent'
|
||||
import {LogUtil} from '@ohos/utils/src/main/ets/default/baseUtil/LogUtil'
|
||||
import RdbStoreUtil from '@ohos/utils/src/main/ets/default/baseUtil/RdbStoreUtil'
|
||||
import inputMethod from '@ohos.inputmethod'
|
||||
|
||||
@Entry
|
||||
@Component
|
||||
@@ -40,6 +41,7 @@ struct NoteContentHome {
|
||||
LogUtil.info(this.TAG, "onBackPress")
|
||||
this.controllerShow.runJavaScript({ script: "RICH_EDITOR.setInputEnabled(false)" })
|
||||
this.controllerShow.runJavaScript({ script: "get_html_content()" })
|
||||
inputMethod.getInputMethodController().stopInput()
|
||||
}
|
||||
|
||||
aboutToAppear(): void{
|
||||
|
||||
Reference in New Issue
Block a user