From 510fca645c0e56c6776f7a1731daf0747195c8a2 Mon Sep 17 00:00:00 2001 From: "ester.zhou" Date: Fri, 3 Mar 2023 08:52:16 +0800 Subject: [PATCH] Add doc (14623) Signed-off-by: ester.zhou --- .../OpenHarmony_4.0.3.2/changelogs-ces.md | 57 +++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 en/release-notes/changelogs/OpenHarmony_4.0.3.2/changelogs-ces.md diff --git a/en/release-notes/changelogs/OpenHarmony_4.0.3.2/changelogs-ces.md b/en/release-notes/changelogs/OpenHarmony_4.0.3.2/changelogs-ces.md new file mode 100644 index 0000000000..f42f231653 --- /dev/null +++ b/en/release-notes/changelogs/OpenHarmony_4.0.3.2/changelogs-ces.md @@ -0,0 +1,57 @@ +# Common Event Subsystem Changelog + +## cl.ces.1 Event Enum Change of ohos.commonEvent + +**Change Impact** + +For applications developed based on earlier versions, the following common events of the **.ohos.commonEvent** module must be adapted. + +| Common Event | +| ----------------------------------- | +| COMMON_EVENT_PACKAGE_CACHE_CLEARED | +| COMMON_EVENT_USB_STATE | +| COMMON_EVENT_USB_PORT_CHANGED | +| COMMON_EVENT_VOLUME_REMOVED | +| COMMON_EVENT_VOLUME_UNMOUNTED | +| COMMON_EVENT_VOLUME_MOUNTED | +| COMMON_EVENT_VOLUME_BAD_REMOVAL | +| COMMON_EVENT_VOLUME_EJECT | +| COMMON_EVENT_SLOT_CHANGE | +| COMMON_EVENT_SPN_INFO_CHANGED | +| COMMON_EVENT_QUICK_FIX_APPLY_RESULT | + +**Key API/Component Changes** + +Replace the common events in **ohos.commonEvent** with those in **ohos.commonEventManager**. + +| Module | ohos.commonEvent | ohos.commonEventManager | +| ---------- | ----------------------------------- | ----------------------------------- | +| | COMMON_EVENT_PACKAGE_CACHE_CLEARED | COMMON_EVENT_PACKAGE_CACHE_CLEARED | +| | COMMON_EVENT_USB_STATE | COMMON_EVENT_USB_STATE | +| | COMMON_EVENT_USB_PORT_CHANGED | COMMON_EVENT_USB_PORT_CHANGED | +| | COMMON_EVENT_VOLUME_REMOVED | COMMON_EVENT_VOLUME_REMOVED | +| | COMMON_EVENT_VOLUME_UNMOUNTED | COMMON_EVENT_VOLUME_UNMOUNTED | +| **Event**| COMMON_EVENT_VOLUME_MOUNTED | COMMON_EVENT_VOLUME_MOUNTED | +| | COMMON_EVENT_VOLUME_BAD_REMOVAL | COMMON_EVENT_VOLUME_BAD_REMOVAL | +| | COMMON_EVENT_VOLUME_EJECT | COMMON_EVENT_VOLUME_EJECT | +| | COMMON_EVENT_SLOT_CHANGE | COMMON_EVENT_SLOT_CHANGE | +| | COMMON_EVENT_SPN_INFO_CHANGED | COMMON_EVENT_SPN_INFO_CHANGED | +| | COMMON_EVENT_QUICK_FIX_APPLY_RESULT | COMMON_EVENT_QUICK_FIX_APPLY_RESULT | + +**Adaptation Guide** + +Replace the events in **ohos.commonEvent** with those in **ohos.commonEventManager**. + +Before change: + +```typescript +import commonEvent from '@ohos.commonEvent'; +let event: string = commonEvent.Support.COMMON_EVENT_PACKAGE_CACHE_CLEARED; +``` + +After change: + +```typescript +import commonEventManager from '@ohos.commonEventManager'; +let event: string = commonEventManager.Support.COMMON_EVENT_PACKAGE_CACHE_CLEARED; +``` -- GitLab