未验证 提交 7d3c56c2 编写于 作者: O openharmony_ci 提交者: Gitee

!14483 【轻量级 PR】:update zh-cn/application-dev/reference/apis/js-apis-window.md.

Merge pull request !14483 from 葛亚芳/N/A
......@@ -5903,9 +5903,9 @@ getMainWindow(callback: AsyncCallback<Window>): void
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
let windowClass = null;
......@@ -5949,9 +5949,9 @@ getMainWindow(): Promise<Window>
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
let windowClass = null;
......@@ -5994,9 +5994,9 @@ getMainWindowSync(): Window
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
try {
......@@ -6037,9 +6037,9 @@ createSubWindow(name: string, callback: AsyncCallback<Window>): void
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
let windowClass = null;
......@@ -6093,9 +6093,9 @@ createSubWindow(name: string): Promise<Window>
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
let windowClass = null;
......@@ -6141,9 +6141,9 @@ getSubWindow(callback: AsyncCallback<Array<Window>>): void
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
let windowClass = null;
......@@ -6185,9 +6185,9 @@ getSubWindow(): Promise<Array<Window>>
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
let windowClass = null;
......@@ -6231,9 +6231,9 @@ loadContent(path: string, storage: LocalStorage, callback: AsyncCallback<void
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
storage : LocalStorage
onWindowStageCreate(windowStage) {
this.storage = new LocalStorage();
......@@ -6289,9 +6289,9 @@ loadContent(path: string, storage?: LocalStorage): Promise<void>
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
storage : LocalStorage
onWindowStageCreate(windowStage) {
this.storage = new LocalStorage();
......@@ -6340,9 +6340,9 @@ loadContent(path: string, callback: AsyncCallback<void>): void
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
try {
......@@ -6389,9 +6389,9 @@ on(eventType: 'windowStageEvent', callback: Callback<WindowStageEventType>
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
try {
......@@ -6436,9 +6436,9 @@ off(eventType: 'windowStageEvent', callback?: Callback<WindowStageEventType&g
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
try {
......@@ -6475,9 +6475,9 @@ disableWindowDecor(): void
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('disableWindowDecor');
windowStage.disableWindowDecor();
......@@ -6515,9 +6515,9 @@ setShowOnLockScreen(showOnLockScreen: boolean): void
**示例:**
```ts
import Ability from '@ohos.application.Ability';
import UIAbility from '@ohos.app.ability.UIAbility';
class myAbility extends Ability {
class myAbility extends UIAbility {
onWindowStageCreate(windowStage) {
console.log('onWindowStageCreate');
try {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册