From 4c40ff37678966b079a5f8ca7df578ca79f4cb11 Mon Sep 17 00:00:00 2001 From: yupeng Date: Wed, 24 May 2023 16:20:02 +0800 Subject: [PATCH] add-api Signed-off-by: yupeng --- .../entry/src/main/ets/MainAbility/pages/web.ets | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/arkui/ace_ets_web_dev_two/entry/src/main/ets/MainAbility/pages/web.ets b/arkui/ace_ets_web_dev_two/entry/src/main/ets/MainAbility/pages/web.ets index 65a21adbd..e80ea03cb 100644 --- a/arkui/ace_ets_web_dev_two/entry/src/main/ets/MainAbility/pages/web.ets +++ b/arkui/ace_ets_web_dev_two/entry/src/main/ets/MainAbility/pages/web.ets @@ -12,6 +12,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ + import UIAbility from '@ohos.app.ability.UIAbility'; import events_emitter from '@ohos.events.emitter'; import AbilityDelegatorRegistry from '@ohos.application.abilityDelegatorRegistry'; import { Hypium } from '@ohos/hypium'; @@ -19,6 +20,15 @@ import testsuite from '../../test/List.test'; import Utils from '../../test/Utils'; import web_webview from '@ohos.web.webview'; +export default class EntryAbility extends UIAbility { + onCreate(want, launchParam) { + console.log("EntryAbility onCreate") + web_webview.WebviewController.initializeWebEngine() + globalThis.abilityWant = want + console.log("EntryAbility onCreate done") + } +} + let loadedUrl; @Entry @Component -- GitLab