Commit c1f483c
committed
fix: handle notification closed signal properly
Added connection to the NotificationClosed signal in initNotifications
function to properly handle when notifications are closed. When a
notification is closed, the globalNotifyId should be reset to 0 to
prevent stale notification ID references. This ensures the system
correctly tracks active notifications and avoids potential issues with
notification management.
Influence:
1. Test notification creation and closure scenarios
2. Verify globalNotifyId is properly reset when notifications are closed
3. Check for any race conditions in notification ID management
4. Ensure notification system stability after multiple open/close cycles
fix: 正确处理通知关闭信号
在 initNotifications 函数中添加了对 NotificationClosed 信号的连接,以正
确处理通知关闭事件。当通知被关闭时,需要将 globalNotifyId 重置为 0,以
防止过时的通知ID引用。这确保系统能正确跟踪活动通知,避免通知管理中的潜在
问题。
主要为了,蓝牙模块在连接后,通知发出来后,此时等待通知bubble消失,然后断开蓝牙连接,会导致通知读取不到原来窗口,导致不显示窗口,
目前处理是监听通知横幅关闭,从而重置窗口id,保证断开后能够显示正确一个新窗口。
PMS: BUG-3521311 parent c225f14 commit c1f483c
1 file changed
Lines changed: 12 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
64 | 64 | | |
65 | 65 | | |
66 | 66 | | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
67 | 78 | | |
68 | 79 | | |
69 | 80 | | |
| |||
0 commit comments