diff --git a/entry/src/main/ets/entryability/EntryAbility.ets b/entry/src/main/ets/entryability/EntryAbility.ets index eb42ddf32515c9ef3391641dc780bb832ebe3c41..1a66c939299926ae2cdb71424942f005a11b4d75 100644 --- a/entry/src/main/ets/entryability/EntryAbility.ets +++ b/entry/src/main/ets/entryability/EntryAbility.ets @@ -13,6 +13,10 @@ * limitations under the License. */ +/* +* 最佳实践: 桌面快捷方式开发实践 +*/ + import { AbilityConstant, UIAbility, Want } from '@kit.AbilityKit'; import { hilog } from '@kit.PerformanceAnalysisKit'; import { Router, window } from '@kit.ArkUI'; diff --git a/entry/src/main/module.json5 b/entry/src/main/module.json5 index 946cdea7f3a907e80a2018ab6a433e650716d4be..21457ae8d678eeb00f33004ea42d75b92d8e2825 100644 --- a/entry/src/main/module.json5 +++ b/entry/src/main/module.json5 @@ -1,5 +1,11 @@ +/* +* 最佳实践: 桌面快捷方式开发实践 +*/ + +// [Start module_json5] { "module": { + // [StartExclude module_json5] "name": "entry", "type": "entry", "description": "$string:module_desc", @@ -10,23 +16,26 @@ "deliveryWithInstall": true, "installationFree": false, "pages": "$profile:main_pages", + // [EndExclude module_json5] "abilities": [ { "name": "EntryAbility", "srcEntry": "./ets/entryability/EntryAbility.ets", + // [StartExclude module_json5] "description": "$string:EntryAbility_desc", "icon": "$media:app_icon", "label": "$string:EntryAbility_label", "startWindowIcon": "$media:app_icon", "startWindowBackground": "$color:start_window_background", "exported": true, + // [EndExclude module_json5] "skills": [ { "entities": [ "entity.system.home" ], "actions": [ - "action.system.home" + "ohos.want.action.home" ] } ], @@ -38,6 +47,7 @@ ] } ], + // [End module_json5] "extensionAbilities": [ { "name": "EntryBackupAbility", @@ -51,6 +61,8 @@ } ], } - ] + ], + // [Start module_json5] } -} \ No newline at end of file +} +// [End module_json5] \ No newline at end of file