应用启动框架sample

Signed-off-by: sunxuhui <sunxuhui7@huawei.com>
This commit is contained in:
sunxuhui 2024-07-16 17:41:34 +08:00
parent 1aa0db0a6c
commit 374ebf6274
4 changed files with 34 additions and 1 deletions

View File

@ -1,3 +1,17 @@
/*
* Copyright (c) 2024 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
{
"app": {
"products": [

View File

@ -90,7 +90,7 @@ struct Index {
build() {
Column() {
Button('手动模式')
Button($r('app.string.Manual_mode'))
.size({ width: 100, height: 100 })
.onClick(() => {
if (!startupManager.isStartupTaskInitialized('ImageKnifeTask')) {

View File

@ -11,6 +11,10 @@
{
"name": "EntryAbility_label",
"value": "label"
},
{
"name": "Manual_mode",
"value": "手动模式"
}
]
}

View File

@ -1,3 +1,18 @@
/*
* Copyright (c) 2024 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
{
"module": {
"name": "entry_test",