openharmony 鸿蒙 capi-oh-window-comm-h

2025-06-12 浏览 (1)

oh_window_comm.h

Overview

The oh_window_comm.h file declares the common enums and definitions of the window manager.

File to include: <window_manager/oh_window_comm.h>

Library: libnative_window_manager.so

System capability: SystemCapability.Window.SessionManager

Since: 12

Related module: WindowManager

Summary

Structs

Nametypedef KeywordDescription
WindowManager_RectWindowManager_RectDescribes the window rectangle, including the window position, width, and height.
structOH_PixelmapNativeDescribes the native pixel image information.
WindowManager_WindowPropertiesWindowManager_WindowPropertiesDescribes the window properties.
WindowManager_AvoidAreaWindowManager_AvoidAreaDescribes the avoid area.

Enums

Nametypedef KeywordDescription
WindowManager_ErrorCodeWindowManager_ErrorCodeEnumerates the status codes returned by the window manager interface.
WindowManager_AvoidAreaTypeWindowManager_AvoidAreaTypeEnumerates the avoid area types.
WindowManager_WindowTypeWindowManager_WindowTypeEnumerates the window types.

Enum Description

WindowManager_ErrorCode

enum WindowManager_ErrorCode

Description

Enumerates the status codes returned by the window manager interface.

Since: 12

Enum ItemDescription
OK = 0Operation successful.
WINDOW_MANAGER_ERRORCODE_NO_PERMISSION = 201No permission.
Since: 15
WINDOW_MANAGER_ERRORCODE_INVALID_PARAM = 401Invalid parameter.
Since: 15
WINDOW_MANAGER_ERRORCODE_DEVICE_NOT_SUPPORTED = 801Not supported by the device.
Since: 15
INVAILD_WINDOW_ID = 1000Invalid window ID.
SERVICE_ERROR = 2000Service error.
WINDOW_MANAGER_ERRORCODE_STATE_ABNORMAL = 1300002Abnormal window status.
Since: 15
WINDOW_MANAGER_ERRORCODE_SYSTEM_ABNORMAL = 1300003Abnormal window manager service.
Since: 15
WINDOW_MANAGER_ERRORCODE_PIP_DESTROY_FAILED = 1300011Failed to destroy the PiP window.
Since: 20
WINDOW_MANAGER_ERRORCODE_PIP_STATE_ABNORMAL = 1300012Abnormal PiP status.
Since: 20
WINDOW_MANAGER_ERRORCODE_PIP_CREATE_FAILED = 1300013Failed to create the PiP window.
Since: 20
WINDOW_MANAGER_ERRORCODE_PIP_INTERNAL_ERROR = 1300014An internal error occurs in PiP. Possible causes:
1. The window on which the PiP feature depends is abnormal. For example, the window is empty. 2. The PiP controller is abnormal.
Since: 20
WINDOW_MANAGER_ERRORCODE_PIP_REPEATED_OPERATION = 1300015Repeated PiP operation.
Since: 20
WINDOW_MANAGER_ERRORCODE_INCORRECT_PARAM = 1300016Incorrect parameter. Possible causes:
1. The parameter value range is invalid. 2. The number of parameters is invalid. 3. The parameter type is invalid.
Since: 20

WindowManager_AvoidAreaType

enum WindowManager_AvoidAreaType

Description

Enumerates the avoid area types.

Since: 15

Enum ItemDescription
WINDOW_MANAGER_AVOID_AREA_TYPE_SYSTEM = 0System avoid area.
WINDOW_MANAGER_AVOID_AREA_TYPE_CUTOUT = 1Cutout area.
WINDOW_MANAGER_AVOID_AREA_TYPE_SYSTEM_GESTURE = 2System gesture area.
WINDOW_MANAGER_AVOID_AREA_TYPE_KEYBOARD = 3Keyboard area.
WINDOW_MANAGER_AVOID_AREA_TYPE_NAVIGATION_INDICATOR = 4Navigation bar area.

WindowManager_WindowType

enum WindowManager_WindowType

Description

Enumerates the window types.

Since: 15

Enum ItemDescription
WINDOW_MANAGER_WINDOW_TYPE_APP = 0Child window.
WINDOW_MANAGER_WINDOW_TYPE_MAIN = 1Main window.
WINDOW_MANAGER_WINDOW_TYPE_FLOAT = 8Floating window.
WINDOW_MANAGER_WINDOW_TYPE_DIALOG = 16Modal window.

你可能感兴趣的鸿蒙文章

harmony 鸿蒙ArkUI

harmony 鸿蒙ARKUI_TextPickerCascadeRangeContent

harmony 鸿蒙ARKUI_TextPickerRangeContent

harmony 鸿蒙ArkUI_AnimateCompleteCallback

harmony 鸿蒙ArkUI_AttributeItem

harmony 鸿蒙ArkUI_ColorStop

harmony 鸿蒙ArkUI_ContextCallback

harmony 鸿蒙ArkUI_EventModule

harmony 鸿蒙ArkUI_ExpectedFrameRateRange

harmony 鸿蒙ArkUI_IntOffset

  • 所属分类: 后端技术
  • 本文标签: 软件 鸿蒙
  • 版权声明: 本文链接 https://seaxiang.com/blog/o4SMAu