fcr-ui-scene 3.5.1 → 3.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/creator.d.ts +14 -0
- package/lib/creator.js +239 -14
- package/lib/electron/app.js +0 -21
- package/lib/electron/bootstrap-sdk.js +136 -7
- package/lib/electron/injections.d.ts +19 -7
- package/lib/electron/injections.js +206 -77
- package/lib/electron/ipc/ipc.d.ts +26 -0
- package/lib/electron/ipc/ipc.js +137 -0
- package/lib/electron/ipc/type.d.ts +11 -0
- package/lib/electron/ipc/type.js +19 -0
- package/lib/electron/logger.js +1 -1
- package/lib/electron/main.js +1 -1
- package/lib/electron/plugins/meeting-state.d.ts +1 -0
- package/lib/electron/plugins/meeting-state.js +3 -3
- package/lib/electron/plugins/screenshot.js +2 -2
- package/lib/electron/preload.js +67 -5
- package/lib/electron/window.js +0 -2
- package/lib/global.css +21 -0
- package/lib/modules/action-bar/components/apps/index.js +1 -0
- package/lib/modules/action-bar/components/apps/useWidgetList.js +1 -1
- package/lib/modules/action-bar/components/item/index.d.ts +2 -0
- package/lib/modules/action-bar/components/item/index.js +4 -2
- package/lib/modules/action-bar/components/leave/index.js +1 -0
- package/lib/modules/action-bar/components/more/index.js +1 -0
- package/lib/modules/action-bar/components/record/index.js +43 -106
- package/lib/modules/action-bar/components/record/popover.d.ts +4 -0
- package/lib/modules/action-bar/components/record/popover.js +57 -0
- package/lib/modules/action-bar/components/record/stop-record-dialog.js +1 -0
- package/lib/modules/action-bar/components/screen-share/index.js +15 -3
- package/lib/modules/action-bar/components/screen-share/submenu.js +2 -2
- package/lib/modules/action-bar/components/security/index.js +2 -1
- package/lib/modules/action-bar/components/smaller/index.js +1 -1
- package/lib/modules/action-bar/components/trigger-output-language/index.js +17 -22
- package/lib/modules/action-bar/components/trigger-subscribe-language/index.js +2 -1
- package/lib/modules/action-bar/index.css +3 -2
- package/lib/modules/action-bar/index.js +2 -1
- package/lib/modules/action-bar/store.d.ts +5 -0
- package/lib/modules/action-bar/store.js +30 -12
- package/lib/modules/action-bar/types.d.ts +1 -0
- package/lib/modules/chat/chat-room-store.js +1 -1
- package/lib/modules/chat/components/chat-bar/index.d.ts +1 -1
- package/lib/modules/chat/components/chat-bar/index.js +5 -3
- package/lib/modules/chat/components/chat-select/select-item/index.js +1 -1
- package/lib/modules/chat/components/message-list/index.js +1 -2
- package/lib/modules/chat/components/message-list/message-item/index.d.ts +0 -1
- package/lib/modules/chat/components/message-list/message-item/index.js +9 -10
- package/lib/modules/chat/index.css +24 -0
- package/lib/modules/chat/view.js +13 -3
- package/lib/modules/components/device-control/components/carmera/index.js +4 -5
- package/lib/modules/components/device-control/components/microphone/index.js +4 -5
- package/lib/modules/components/device-control/index.css +6 -3
- package/lib/modules/components/leave-meeting/components/assign-host.js +26 -4
- package/lib/modules/components/leave-meeting/components/index.css +35 -0
- package/lib/modules/components/leave-meeting/index.js +1 -0
- package/lib/modules/components/leave-meeting/store.js +25 -67
- package/lib/modules/components/member-window/components/member-actions/components/audio-control.js +3 -2
- package/lib/modules/components/member-window/components/member-actions/components/icon-buttons/index.js +1 -1
- package/lib/modules/components/member-window/components/member-actions/components/icon-status.js +10 -9
- package/lib/modules/components/member-window/components/member-actions/components/more-actions.js +2 -2
- package/lib/modules/components/member-window/components/member-actions/components/user-info.js +1 -1
- package/lib/modules/components/member-window/components/member-actions/index.js +2 -2
- package/lib/modules/components/member-window/components/video-player/components/remote-video-player.js +3 -14
- package/lib/modules/components/member-window/index.css +18 -7
- package/lib/modules/components/member-window/types.d.ts +1 -1
- package/lib/modules/components/security-menu/index.css +2 -2
- package/lib/modules/components/security-menu/index.js +80 -28
- package/lib/modules/components/tab-frame/index.css +1 -1
- package/lib/modules/control-bar/components/meeting-details/index.css +1 -1
- package/lib/modules/control-bar/components/meeting-details/index.js +15 -9
- package/lib/modules/control-bar/components/more-actions/index.js +3 -21
- package/lib/modules/control-bar/components/share-state-nav/index.js +4 -20
- package/lib/modules/control-bar/index.d.ts +2 -0
- package/lib/modules/control-bar/index.js +3 -1
- package/lib/modules/control-bar/store.d.ts +11 -2
- package/lib/modules/control-bar/store.js +103 -95
- package/lib/modules/control-bar/view.js +1 -6
- package/lib/modules/device-pretest/audio-preview/speaker-detection.js +1 -1
- package/lib/modules/dialog/components/chat/electron.d.ts +1 -3
- package/lib/modules/dialog/components/chat/index.js +24 -17
- package/lib/modules/dialog/components/confirm-leave-meeting/index.d.ts +6 -0
- package/lib/modules/dialog/components/confirm-leave-meeting/index.js +86 -0
- package/lib/modules/dialog/components/control-bar/index.d.ts +1 -2
- package/lib/modules/dialog/components/control-bar/index.js +5 -17
- package/lib/modules/dialog/components/dialog-container/component/body.d.ts +1 -0
- package/lib/modules/dialog/components/dialog-container/component/body.js +4 -2
- package/lib/modules/dialog/components/dialog-container/index.css +2 -1
- package/lib/modules/dialog/components/dialog-container/index.d.ts +1 -0
- package/lib/modules/dialog/components/dialog-container/index.js +3 -1
- package/lib/modules/dialog/components/participant/index.d.ts +0 -1
- package/lib/modules/dialog/components/participant/index.js +15 -24
- package/lib/modules/dialog/components/pre-setting/electron.d.ts +2 -0
- package/lib/modules/dialog/components/pre-setting/electron.js +51 -0
- package/lib/modules/dialog/components/pre-setting/index.css +26 -0
- package/lib/modules/dialog/components/pre-setting/index.d.ts +6 -0
- package/lib/modules/dialog/components/pre-setting/index.js +38 -0
- package/lib/modules/dialog/components/pre-setting-container/component/body.d.ts +8 -0
- package/lib/modules/dialog/components/pre-setting-container/component/body.js +80 -0
- package/lib/modules/dialog/components/pre-setting-container/index.css +82 -0
- package/lib/modules/dialog/components/pre-setting-container/index.d.ts +18 -0
- package/lib/modules/dialog/components/pre-setting-container/index.js +117 -0
- package/lib/modules/dialog/components/rename/index.d.ts +4 -0
- package/lib/modules/dialog/components/rename/index.js +72 -0
- package/lib/modules/dialog/components/video-window/index.js +18 -16
- package/lib/modules/dialog/components/widget/electron.d.ts +2 -1
- package/lib/modules/dialog/components/widget/electron.js +3 -2
- package/lib/modules/dialog/components/widget/index.d.ts +2 -1
- package/lib/modules/dialog/components/widget/index.js +4 -6
- package/lib/modules/dialog/dialogs.d.ts +1 -0
- package/lib/modules/dialog/dialogs.js +3 -2
- package/lib/modules/dialog/hooks/useElectron.d.ts +2 -0
- package/lib/modules/dialog/hooks/useElectron.js +11 -13
- package/lib/modules/dialog/index.d.ts +2 -0
- package/lib/modules/dialog/index.js +2 -1
- package/lib/modules/dialog/store.d.ts +8 -3
- package/lib/modules/dialog/store.js +38 -26
- package/lib/modules/dialog/type.d.ts +1 -0
- package/lib/modules/dialog/view.js +2 -1
- package/lib/modules/event-confirm/index.d.ts +2 -0
- package/lib/modules/event-confirm/index.js +2 -1
- package/lib/modules/event-confirm/store.d.ts +9 -1
- package/lib/modules/event-confirm/store.js +94 -8
- package/lib/modules/event-confirm/view.js +55 -46
- package/lib/modules/{sound-effect → event-sound}/index.d.ts +3 -2
- package/lib/modules/{sound-effect → event-sound}/index.js +9 -5
- package/lib/modules/event-toast/store.js +2 -0
- package/lib/modules/interpreter/dialog-content/index.js +4 -1
- package/lib/modules/interpreter/index.d.ts +2 -0
- package/lib/modules/interpreter/index.js +2 -1
- package/lib/modules/interpreter/interpreter-list/interpreter-item/components/pick-language/index.js +3 -0
- package/lib/modules/interpreter/store.d.ts +2 -2
- package/lib/modules/interpreter/store.js +30 -24
- package/lib/modules/interpreter/type.d.ts +2 -0
- package/lib/modules/invite/components/pstn-invite.js +3 -9
- package/lib/modules/invite/components/voip-invite.css +26 -0
- package/lib/modules/invite/components/voip-invite.d.ts +1 -0
- package/lib/modules/invite/components/voip-invite.js +8 -11
- package/lib/modules/invite/index.css +16 -3
- package/lib/modules/invite/index.d.ts +2 -1
- package/lib/modules/invite/index.js +2 -1
- package/lib/modules/invite/store.d.ts +5 -1
- package/lib/modules/invite/store.js +8 -1
- package/lib/modules/layout/components/Carousel.d.ts +1 -1
- package/lib/modules/layout/components/Carousel.js +16 -118
- package/lib/modules/layout/components/CommonVideoRenderer.d.ts +13 -0
- package/lib/modules/layout/components/CommonVideoRenderer.js +214 -0
- package/lib/modules/layout/components/Gallery.d.ts +1 -0
- package/lib/modules/layout/components/Gallery.js +62 -205
- package/lib/modules/layout/components/index.css +17 -34
- package/lib/modules/layout/index.d.ts +2 -0
- package/lib/modules/layout/index.js +2 -1
- package/lib/modules/layout/store.d.ts +5 -2
- package/lib/modules/layout/store.js +47 -39
- package/lib/modules/layout/type.d.ts +4 -0
- package/lib/modules/layout/type.js +6 -1
- package/lib/modules/live-streaming/store.d.ts +1 -0
- package/lib/modules/live-streaming/store.js +19 -8
- package/lib/modules/participant/components/confirm-input/index.d.ts +4 -4
- package/lib/modules/participant/components/confirm-input/index.js +74 -6
- package/lib/modules/participant/components/participants/components/footer/components/drop-menu/index.css +27 -3
- package/lib/modules/participant/components/participants/components/footer/components/footer/index.css +4 -0
- package/lib/modules/participant/components/participants/components/footer/components/footer/index.js +3 -2
- package/lib/modules/participant/components/participants/components/participants/components/attendee/index.css +4 -3
- package/lib/modules/participant/components/participants/components/participants/components/attendee/index.js +1 -0
- package/lib/modules/participant/components/participants/components/participants/components/participants-more/index.css +9 -1
- package/lib/modules/participant/components/participants/components/participants/components/participants-more/index.js +1 -1
- package/lib/modules/participant/components/participants/components/participants/index.css +1 -0
- package/lib/modules/participant/components/participants/components/render-user/components/attendee/index.css +18 -0
- package/lib/modules/participant/components/participants/components/render-user/components/attendee/index.js +12 -5
- package/lib/modules/participant/components/participants/components/render-user/components/user-action/components/move-actions-popover/index.js +1 -8
- package/lib/modules/participant/index.css +6 -0
- package/lib/modules/participant/index.d.ts +1 -0
- package/lib/modules/participant/index.js +9 -0
- package/lib/modules/participant/store.d.ts +6 -0
- package/lib/modules/participant/store.js +130 -96
- package/lib/modules/pc-audio-connect/store.js +1 -1
- package/lib/modules/phone-audio-connect/index.d.ts +2 -0
- package/lib/modules/phone-audio-connect/index.js +2 -1
- package/lib/modules/phone-audio-connect/store.d.ts +4 -1
- package/lib/modules/phone-audio-connect/store.js +4 -2
- package/lib/modules/setting/audio-settings/audio-settings.js +70 -48
- package/lib/modules/setting/audio-settings/index.css +23 -6
- package/lib/modules/setting/general-settings/general-settings.d.ts +1 -2
- package/lib/modules/setting/general-settings/general-settings.js +111 -37
- package/lib/modules/setting/general-settings/index.css +15 -0
- package/lib/modules/setting/index.d.ts +4 -1
- package/lib/modules/setting/index.js +7 -4
- package/lib/modules/setting/state/index.js +1 -1
- package/lib/modules/setting/store.d.ts +24 -11
- package/lib/modules/setting/store.js +203 -142
- package/lib/modules/setting/video-settings/index.css +13 -2
- package/lib/modules/setting/video-settings/video-settings-basic.js +18 -27
- package/lib/modules/setting/video-settings/video-settings.d.ts +0 -2
- package/lib/modules/setting/video-settings/video-settings.js +3 -2
- package/lib/modules/setting/view.d.ts +11 -2
- package/lib/modules/setting/view.js +93 -71
- package/lib/modules/share-screen/components/selection/index.js +6 -2
- package/lib/modules/share-screen/index.d.ts +4 -1
- package/lib/modules/share-screen/index.js +3 -1
- package/lib/modules/share-screen/store.d.ts +15 -5
- package/lib/modules/share-screen/store.js +105 -59
- package/lib/modules/share-screen/view.js +1 -1
- package/lib/modules/state-bar/index.css +4 -2
- package/lib/modules/state-bar/index.d.ts +2 -0
- package/lib/modules/state-bar/index.js +2 -1
- package/lib/modules/state-bar/layout-config.js +1 -0
- package/lib/modules/state-bar/live-streaming-state.js +1 -0
- package/lib/modules/state-bar/meeting-detail.css +10 -1
- package/lib/modules/state-bar/meeting-details.js +42 -26
- package/lib/modules/state-bar/meeting-network-state.css +8 -0
- package/lib/modules/state-bar/meeting-time.js +9 -20
- package/lib/modules/state-bar/store.d.ts +5 -1
- package/lib/modules/state-bar/store.js +10 -3
- package/lib/modules/state-bar/view.js +17 -6
- package/lib/modules/video-window/components/members/index.js +0 -3
- package/lib/modules/waiting-room-layout/index.css +13 -0
- package/lib/modules/waiting-room-layout/index.d.ts +2 -1
- package/lib/modules/waiting-room-layout/index.js +2 -1
- package/lib/modules/waiting-room-layout/store.d.ts +12 -1
- package/lib/modules/waiting-room-layout/store.js +42 -6
- package/lib/modules/waiting-room-layout/view.js +22 -5
- package/lib/modules/whiteboard/components/control-bar/index.css +1 -1
- package/lib/modules/whiteboard/components/switch-theme/libs.d.ts +1 -1
- package/lib/modules/whiteboard/components/switch-theme/libs.js +3 -1
- package/lib/modules/whiteboard/components/toolbar/ style.css +1 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/components/panel.js +1 -0
- package/lib/modules/whiteboard/components/toolbar/components/color-picker/components/picker.js +1 -0
- package/lib/modules/whiteboard/components/toolbar/components/eraser-picker.js +3 -14
- package/lib/modules/whiteboard/components/toolbar/components/expansion/index.d.ts +1 -0
- package/lib/modules/whiteboard/components/toolbar/components/expansion/index.js +83 -0
- package/lib/modules/whiteboard/components/toolbar/components/extra-tool-picker.js +2 -2
- package/lib/modules/whiteboard/components/toolbar/components/history.js +3 -3
- package/lib/modules/whiteboard/components/toolbar/components/item/index.d.ts +1 -0
- package/lib/modules/whiteboard/components/toolbar/components/item/index.js +42 -0
- package/lib/modules/whiteboard/components/toolbar/components/pen-picker.js +2 -2
- package/lib/modules/whiteboard/components/toolbar/components/screen-capture-picker.js +2 -2
- package/lib/modules/whiteboard/components/toolbar/components/shape-picker.js +3 -3
- package/lib/modules/whiteboard/components/toolbar/hooks/index.js +6 -6
- package/lib/modules/whiteboard/components/toolbar/index.js +9 -113
- package/lib/modules/whiteboard/components/toolbar/store.d.ts +18 -0
- package/lib/modules/whiteboard/components/toolbar/store.js +276 -83
- package/lib/modules/whiteboard/context.d.ts +1 -2
- package/lib/modules/whiteboard/index.d.ts +1 -14
- package/lib/modules/whiteboard/index.js +131 -426
- package/lib/modules/whiteboard/view.js +12 -10
- package/lib/modules/widget/sdk.js +2 -1
- package/lib/object-manager.d.ts +8 -0
- package/lib/object-manager.js +75 -0
- package/lib/plugins/browser-runtime-plugin.js +19 -14
- package/lib/providers/ability-provider.d.ts +8 -0
- package/lib/providers/ability-provider.js +14 -0
- package/lib/providers/device-privilege-provider.d.ts +1 -0
- package/lib/providers/device-privilege-provider.js +53 -75
- package/lib/providers/device-provider.d.ts +18 -8
- package/lib/providers/device-provider.js +397 -209
- package/lib/providers/device-stream-provider.js +0 -4
- package/lib/providers/dialog-provider.d.ts +1 -0
- package/lib/providers/dialog-provider.js +4 -18
- package/lib/providers/event-provider.js +45 -2
- package/lib/providers/interpreter-provider.d.ts +4 -0
- package/lib/providers/interpreter-provider.js +166 -137
- package/lib/providers/message-provider.js +44 -2
- package/lib/providers/privilege-provider.d.ts +33 -0
- package/lib/providers/privilege-provider.js +120 -45
- package/lib/providers/room-provider.d.ts +12 -10
- package/lib/providers/room-provider.js +162 -262
- package/lib/providers/screen-share-provider.d.ts +4 -0
- package/lib/providers/screen-share-provider.js +3 -6
- package/lib/providers/widget-provider.js +6 -4
- package/lib/runtime.d.ts +20 -8
- package/lib/scenes/main-scene.d.ts +2 -0
- package/lib/scenes/main-scene.js +95 -37
- package/lib/scenes/waiting-scene.js +16 -13
- package/lib/schema.d.ts +55 -32
- package/lib/schema.js +23 -9
- package/lib/shared-data-source/config.d.ts +6 -2
- package/lib/shared-data-source/config.js +81 -10
- package/lib/shared-data-source/member-data.d.ts +16 -20
- package/lib/shared-data-source/member-data.js +121 -110
- package/lib/shared-data-source/screen-share-data-source.d.ts +37 -0
- package/lib/shared-data-source/screen-share-data-source.js +134 -0
- package/lib/shared-data-source/security-data.d.ts +1 -0
- package/lib/shared-data-source/security-data.js +3 -5
- package/lib/shared-data-source/setting.d.ts +1 -0
- package/lib/shared-data-source/setting.js +33 -17
- package/lib/shared-data-source/video-window.d.ts +3 -3
- package/lib/shared-data-source/video-window.js +55 -38
- package/lib/translations/enUS.d.ts +48 -1
- package/lib/translations/enUS.js +101 -17
- package/lib/translations/zhCN.d.ts +48 -1
- package/lib/translations/zhCN.js +88 -4
- package/lib/type.d.ts +40 -20
- package/lib/type.js +14 -1
- package/lib/ui-manager.d.ts +11 -9
- package/lib/ui-manager.js +118 -29
- package/lib/ui-scene.d.ts +7 -4
- package/lib/ui-scene.js +111 -128
- package/lib/utilities/constant.d.ts +3 -1
- package/lib/utilities/constant.js +2 -0
- package/lib/utilities/copyText.js +15 -11
- package/lib/utilities/default-config.d.ts +2 -0
- package/lib/utilities/default-config.js +11 -5
- package/lib/utilities/i18n-common-data.d.ts +2 -0
- package/lib/utilities/i18n-common-data.js +15 -0
- package/lib/utilities/logger.d.ts +0 -1
- package/lib/utilities/logger.js +3 -4
- package/lib/utilities/renderer.d.ts +0 -9
- package/lib/utilities/renderer.js +1 -70
- package/lib/utilities/screen.js +3 -1
- package/lib/utilities/setting-config-storage.d.ts +6 -1
- package/lib/utilities/setting-config-storage.js +21 -4
- package/lib/utilities/tools.d.ts +7 -6
- package/lib/utilities/tools.js +56 -44
- package/lib/utilities/ui-resources.d.ts +6 -0
- package/lib/utilities/ui-resources.js +47 -9
- package/lib/waiting-room-control-manager.d.ts +4 -4
- package/lib/waiting-room-control-manager.js +29 -9
- package/package.json +6 -6
- package/public/assets/browser/images/default1.jpg +0 -0
- package/public/assets/browser/images/default2.jpg +0 -0
- package/public/assets/browser/images/default3.jpg +0 -0
- package/public/assets/browser/images/default4.jpg +0 -0
- package/public/assets/browser/images/default5.jpg +0 -0
- package/public/assets/browser/images/default6.jpg +0 -0
- package/public/assets/browser/images/default7.jpg +0 -0
- package/public/assets/browser/sound_effects/pretest.mp3 +0 -0
- package/public/assets/browser/sound_effects/recording_started.mp3 +0 -0
- package/public/assets/browser/sound_effects/remote_user_joined.mp3 +0 -0
- package/public/assets/browser/sound_effects/speaker_test.mp3 +0 -0
- package/public/assets/browser/videos/default8.mp4 +0 -0
- package/public/assets/browser/videos/default9.mp4 +0 -0
- package/public/assets/electron/images/default1.jpg +0 -0
- package/public/assets/electron/images/default2.jpg +0 -0
- package/public/assets/electron/sound_effects/pretest.mp3 +0 -0
- package/public/assets/electron/videos/default8.mp4 +0 -0
- package/public/index.html +103 -82
- package/lib/hooks/meeting-time.d.ts +0 -15
- package/lib/hooks/meeting-time.js +0 -92
- package/lib/login-confirm-dialog.d.ts +0 -13
- package/lib/login-confirm-dialog.js +0 -85
- package/lib/modules/action-bar/components/apps/appitems.d.ts +0 -3
- package/lib/modules/action-bar/components/apps/appitems.js +0 -45
- package/lib/modules/components/member-window/components/member-board.d.ts +0 -2
- package/lib/modules/components/member-window/components/member-board.js +0 -63
- package/lib/modules/dialog/components/system-preference/bg1.png +0 -0
- package/lib/modules/dialog/components/system-preference/bg2.png +0 -0
- package/lib/modules/dialog/types/index.d.ts +0 -70
- package/lib/modules/participant/components/attendee/components/microphone-indicator/index.d.ts +0 -6
- package/lib/modules/participant/components/attendee/components/microphone-indicator/index.js +0 -28
- package/lib/modules/participant/components/attendee/components/user-avatar/index.d.ts +0 -7
- package/lib/modules/participant/components/attendee/components/user-avatar/index.js +0 -39
- package/lib/modules/participant/components/attendee/index.css +0 -69
- package/lib/modules/participant/components/attendee/index.d.ts +0 -4
- package/lib/modules/participant/components/attendee/index.js +0 -337
- package/lib/modules/participant/components/drop-menu/index.css +0 -60
- package/lib/modules/participant/components/drop-menu/index.d.ts +0 -2
- package/lib/modules/participant/components/drop-menu/index.js +0 -189
- package/lib/modules/participant/components/footer/buttons.d.ts +0 -6
- package/lib/modules/participant/components/footer/buttons.js +0 -52
- package/lib/modules/participant/components/footer/index.d.ts +0 -4
- package/lib/modules/participant/components/footer/index.js +0 -37
- package/lib/modules/participant/components/merge/index.d.ts +0 -11
- package/lib/modules/participant/components/merge/index.js +0 -49
- package/lib/modules/participant/components/rename/index.d.ts +0 -4
- package/lib/modules/participant/components/rename/index.js +0 -45
- package/lib/modules/participant/components/user-action/index.d.ts +0 -17
- package/lib/modules/participant/components/user-action/index.js +0 -169
- package/lib/modules/video-window/deviceState/index.d.ts +0 -16
- package/lib/modules/video-window/deviceState/index.js +0 -75
- package/lib/modules/video-window/members/index.css +0 -51
- package/lib/modules/video-window/members/index.d.ts +0 -2
- package/lib/modules/video-window/members/index.js +0 -157
- package/lib/modules/video-window/speaking/index.css +0 -69
- package/lib/modules/video-window/speaking/index.d.ts +0 -3
- package/lib/modules/video-window/speaking/index.js +0 -57
- package/lib/modules/video-window/topControl/index.css +0 -35
- package/lib/modules/video-window/topControl/index.d.ts +0 -3
- package/lib/modules/video-window/topControl/index.js +0 -92
- /package/lib/modules/{sound-effect → event-sound}/sound-effect-player.d.ts +0 -0
- /package/lib/modules/{sound-effect → event-sound}/sound-effect-player.js +0 -0
|
@@ -7,6 +7,7 @@ require("core-js/modules/es.error.cause.js");
|
|
|
7
7
|
require("core-js/modules/es.error.to-string.js");
|
|
8
8
|
require("core-js/modules/es.array.is-array.js");
|
|
9
9
|
require("core-js/modules/es.date.to-primitive.js");
|
|
10
|
+
require("core-js/modules/es.function.bind.js");
|
|
10
11
|
require("core-js/modules/es.function.name.js");
|
|
11
12
|
require("core-js/modules/es.number.constructor.js");
|
|
12
13
|
require("core-js/modules/es.object.create.js");
|
|
@@ -32,7 +33,6 @@ require("core-js/modules/es.array.includes.js");
|
|
|
32
33
|
require("core-js/modules/es.array.iterator.js");
|
|
33
34
|
require("core-js/modules/es.array.push.js");
|
|
34
35
|
require("core-js/modules/es.array.some.js");
|
|
35
|
-
require("core-js/modules/es.function.bind.js");
|
|
36
36
|
require("core-js/modules/es.map.js");
|
|
37
37
|
require("core-js/modules/es.object.to-string.js");
|
|
38
38
|
require("core-js/modules/es.string.includes.js");
|
|
@@ -80,9 +80,10 @@ var _dialogProvider = require("../../providers/dialog-provider");
|
|
|
80
80
|
var _type2 = require("agora-rte-sdk/lib/core/rtc/type");
|
|
81
81
|
var _logger = require("../../utilities/logger");
|
|
82
82
|
var _tools = require("../../utilities/tools");
|
|
83
|
+
var _useElectron = require("./hooks/useElectron");
|
|
83
84
|
var _excluded = ["x", "y"];
|
|
84
85
|
var _DialogStore;
|
|
85
|
-
var _initProto, _init_openedDialogs, _init_confirmDialogs, _init_userCount, _init_participantElectronDialogContainer, _init_currentDialogBounds, _init_videoWindowBounds, _init_currentShareId, _init_currentShareType, _init_currentShareBounds, _init_recordShareBounds, _setVideoWindowBoundsDecs, _updateCurrentShareContentDecs,
|
|
86
|
+
var _initProto, _init_openedDialogs, _init_confirmDialogs, _init_userCount, _init_participantElectronDialogContainer, _init_currentDialogBounds, _init_videoWindowBounds, _init_currentShareId, _init_currentShareType, _init_currentShareBounds, _init_recordShareBounds, _setVideoWindowBoundsDecs, _updateCurrentShareContentDecs, _recordCurrentSharingScreenBoundsDecs, _handleDialogEventDecs, _hanleAllUserCountUpdatedDecs, _ref;
|
|
86
87
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
87
88
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2["default"])(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
88
89
|
function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
|
|
@@ -107,7 +108,7 @@ var _G = /*#__PURE__*/new WeakMap();
|
|
|
107
108
|
var _H = /*#__PURE__*/new WeakMap();
|
|
108
109
|
var _I = /*#__PURE__*/new WeakMap();
|
|
109
110
|
var _J = /*#__PURE__*/new WeakMap();
|
|
110
|
-
_ref = (_setVideoWindowBoundsDecs = [_mobx.action, _mobx.action.bound], _updateCurrentShareContentDecs = [_mobx.action, _mobx.action.bound],
|
|
111
|
+
_ref = (_setVideoWindowBoundsDecs = [_mobx.action, _mobx.action.bound], _updateCurrentShareContentDecs = [_mobx.action, _mobx.action.bound], _recordCurrentSharingScreenBoundsDecs = [_mobx.action, _mobx.action.bound], _handleDialogEventDecs = [_mobx.action, _mobx.action.bound], _hanleAllUserCountUpdatedDecs = [_mobx.action, _mobx.action.bound], "logger");
|
|
111
112
|
var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
112
113
|
function DialogStore(_ref2) {
|
|
113
114
|
var _this = this;
|
|
@@ -123,16 +124,17 @@ var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
123
124
|
phoneAudioConnectorProvider = _ref2.phoneAudioConnectorProvider,
|
|
124
125
|
dialogsByKey = _ref2.dialogsByKey,
|
|
125
126
|
widgetProvider = _ref2.widgetProvider,
|
|
127
|
+
screenShareProvider = _ref2.screenShareProvider,
|
|
126
128
|
chatProvider = _ref2.chatProvider;
|
|
127
129
|
(0, _classCallCheck2["default"])(this, DialogStore);
|
|
128
130
|
(0, _defineProperty2["default"])(this, _ref, (_initProto(this), (0, _logger.createLogger)({
|
|
129
131
|
prefix: 'DialogStore'
|
|
130
132
|
})));
|
|
131
133
|
(0, _defineProperty2["default"])(this, "_handleDialogEventObserver", {
|
|
132
|
-
onEvent: this._handleDialogEvent
|
|
134
|
+
onEvent: this._handleDialogEvent
|
|
133
135
|
});
|
|
134
136
|
(0, _defineProperty2["default"])(this, "_userObserver", {
|
|
135
|
-
onAllUserCountUpdated: this._hanleAllUserCountUpdated
|
|
137
|
+
onAllUserCountUpdated: this._hanleAllUserCountUpdated
|
|
136
138
|
});
|
|
137
139
|
_classPrivateFieldInitSpec(this, _A, _init_openedDialogs(this, []));
|
|
138
140
|
_classPrivateFieldInitSpec(this, _B, _init_confirmDialogs(this, new Map()));
|
|
@@ -162,6 +164,7 @@ var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
162
164
|
this._dialogComponentMapByKey = dialogsByKey;
|
|
163
165
|
this._widgetProvider = widgetProvider;
|
|
164
166
|
this._chatProvider = chatProvider;
|
|
167
|
+
this._screenShareProvider = screenShareProvider;
|
|
165
168
|
this._userControl.addObserver(this._userObserver);
|
|
166
169
|
this._uiEventStore.addObserver(this._handleDialogEventObserver);
|
|
167
170
|
this._dialogProvider.addObserver(this._handleDialogEventObserver);
|
|
@@ -320,6 +323,11 @@ var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
320
323
|
get: function get() {
|
|
321
324
|
return this._chatProvider.chatConnectionState;
|
|
322
325
|
}
|
|
326
|
+
}, {
|
|
327
|
+
key: "isSharingScreen",
|
|
328
|
+
get: function get() {
|
|
329
|
+
return this._screenShareProvider.isSharingScreen;
|
|
330
|
+
}
|
|
323
331
|
}, {
|
|
324
332
|
key: "setParticipantElectronDialogContainer",
|
|
325
333
|
value: function setParticipantElectronDialogContainer(dom) {
|
|
@@ -419,8 +427,8 @@ var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
419
427
|
this.currentShareBounds = bounds;
|
|
420
428
|
}
|
|
421
429
|
}, {
|
|
422
|
-
key: "
|
|
423
|
-
value: function
|
|
430
|
+
key: "recordCurrentSharingScreenBounds",
|
|
431
|
+
value: function recordCurrentSharingScreenBounds() {
|
|
424
432
|
var recordShareBounds = this.recordShareBounds;
|
|
425
433
|
var currentShareBounds = this.currentShareBounds;
|
|
426
434
|
var screenBounds = undefined;
|
|
@@ -442,15 +450,14 @@ var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
442
450
|
x: x,
|
|
443
451
|
y: y
|
|
444
452
|
}, bounds);
|
|
453
|
+
this.logger.info('recordCurrentSharingScreenBounds is called and the recordShareBounds has currentShareBounds value, the value is', screenBounds);
|
|
445
454
|
} else {
|
|
446
455
|
recordShareBounds.clear();
|
|
447
456
|
screenBounds = (0, _tools.getCurrentSharingWorkArea)({
|
|
448
|
-
currentShareId: this.currentShareId,
|
|
449
|
-
currentShareType: this.currentShareType,
|
|
450
|
-
allApplicationWindows: [],
|
|
451
457
|
currentShareBounds: this.currentShareBounds
|
|
452
458
|
});
|
|
453
459
|
recordShareBounds.set(currentShareBounds, screenBounds);
|
|
460
|
+
this.logger.info('recordCurrentSharingScreenBounds is called and the recordShareBounds is initialled, the value is', screenBounds);
|
|
454
461
|
}
|
|
455
462
|
return screenBounds;
|
|
456
463
|
}
|
|
@@ -464,22 +471,13 @@ var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
464
471
|
params = _ref6$params === void 0 ? {} : _ref6$params;
|
|
465
472
|
switch (action) {
|
|
466
473
|
case _constant.FcrUIAction.OPEN_DIALOG:
|
|
474
|
+
this.logger.info('open_dialog: ', dialogKey, '====', dialogId);
|
|
467
475
|
// 因为窗口可能会移动,因此需要矫正 global toast 和 confirm 的 Bounds
|
|
468
476
|
var isToastOrConfirm = [_constant.FcrUIDialogKey.SHOW_TOAST, _constant.FcrUIDialogKey.CONFIRM].includes(dialogKey);
|
|
477
|
+
this._focusDialog(dialogKey, dialogId);
|
|
469
478
|
if (isToastOrConfirm && (0, _env.isElectron)()) {
|
|
470
479
|
var _dialogWindows$get, _dialogWindows$get2;
|
|
471
|
-
|
|
472
|
-
var confirmWindow = _dialogs.dialogWindows.get(_constant.FcrUIDialogKey.CONFIRM);
|
|
473
|
-
var controlbar = _dialogs.dialogWindows.get(_constant.FcrUIDialogKey.CONTROL_BAR);
|
|
474
|
-
var nearDispaly = window.runtime.screen.getDisplayNearestPoint(controlbar && controlbar.isVisible() ? controlbar === null || controlbar === void 0 ? void 0 : controlbar.getBounds() : window.runtime.browserWindow.getBounds()).bounds;
|
|
475
|
-
var bounds = {
|
|
476
|
-
x: Math.floor(nearDispaly.x),
|
|
477
|
-
y: Math.floor(nearDispaly.y),
|
|
478
|
-
width: Math.floor(nearDispaly.width),
|
|
479
|
-
height: Math.floor(nearDispaly.height)
|
|
480
|
-
};
|
|
481
|
-
toastWindow === null || toastWindow === void 0 || toastWindow.setBounds(bounds);
|
|
482
|
-
confirmWindow === null || confirmWindow === void 0 || confirmWindow.setBounds(bounds);
|
|
480
|
+
// followCorrectDisplay([FcrUIDialogKey.CONFIRM, FcrUIDialogKey.SHOW_TOAST]); 已经内置到各自的 store
|
|
483
481
|
if (!(0, _platform.isWindows)()) {
|
|
484
482
|
_dialogs.dialogWindows.forEach(function (window, key) {
|
|
485
483
|
if (key === dialogKey || HIGH_LEVEL_DIALOG_LAYER.includes(key) || TOP_LEVEL_DIALOG_LAYER.includes(key)) return;
|
|
@@ -487,7 +485,7 @@ var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
487
485
|
});
|
|
488
486
|
}
|
|
489
487
|
(_dialogWindows$get = _dialogs.dialogWindows.get(dialogKey)) === null || _dialogWindows$get === void 0 || _dialogWindows$get.focus();
|
|
490
|
-
(_dialogWindows$get2 = _dialogs.dialogWindows.get(dialogKey)) === null || _dialogWindows$get2 === void 0 || _dialogWindows$get2.setAlwaysOnTop(true,
|
|
488
|
+
(_dialogWindows$get2 = _dialogs.dialogWindows.get(dialogKey)) === null || _dialogWindows$get2 === void 0 || _dialogWindows$get2.setAlwaysOnTop(true, _useElectron.diffPlatformTopLevelLayer);
|
|
491
489
|
// toast 有独立逻辑 src/event-dialog
|
|
492
490
|
// confirm 有独立逻辑 src/evnet-confirm
|
|
493
491
|
return;
|
|
@@ -496,8 +494,7 @@ var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
496
494
|
return dialog.dialogId === dialogId;
|
|
497
495
|
});
|
|
498
496
|
if (currentDialog) {
|
|
499
|
-
|
|
500
|
-
(_dialogWindows$get3 = _dialogs.dialogWindows.get(dialogKey)) === null || _dialogWindows$get3 === void 0 || _dialogWindows$get3.focus();
|
|
497
|
+
this._focusDialog(dialogKey, dialogId);
|
|
501
498
|
} else {
|
|
502
499
|
this.openedDialogs.push({
|
|
503
500
|
dialogKey: dialogKey,
|
|
@@ -510,6 +507,7 @@ var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
510
507
|
this.openedDialogs = this.openedDialogs.filter(function (dialog) {
|
|
511
508
|
return dialog.dialogId !== dialogId;
|
|
512
509
|
});
|
|
510
|
+
this.closeDialogByKey(dialogKey);
|
|
513
511
|
break;
|
|
514
512
|
case _constant.FcrUIAction.VIDEO_WINDOW_BOUNDS:
|
|
515
513
|
this.setVideoWindowBounds(payload);
|
|
@@ -526,10 +524,24 @@ var DialogStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
526
524
|
value: function _hanleAllUserCountUpdated(_roomId, count) {
|
|
527
525
|
this.userCount = count;
|
|
528
526
|
}
|
|
527
|
+
}, {
|
|
528
|
+
key: "_focusDialog",
|
|
529
|
+
value: function _focusDialog(dialogKey, dialogId) {
|
|
530
|
+
if ((0, _env.isElectron)()) {
|
|
531
|
+
var canFindById = _dialogs.dialogIdWindows.has(dialogId);
|
|
532
|
+
if (canFindById) {
|
|
533
|
+
var _dialogIdWindows$get;
|
|
534
|
+
(_dialogIdWindows$get = _dialogs.dialogIdWindows.get(dialogId)) === null || _dialogIdWindows$get === void 0 || _dialogIdWindows$get.focus();
|
|
535
|
+
} else {
|
|
536
|
+
var _dialogWindows$get3;
|
|
537
|
+
(_dialogWindows$get3 = _dialogs.dialogWindows.get(dialogKey)) === null || _dialogWindows$get3 === void 0 || _dialogWindows$get3.focus();
|
|
538
|
+
}
|
|
539
|
+
}
|
|
540
|
+
}
|
|
529
541
|
}]);
|
|
530
542
|
}();
|
|
531
543
|
_DialogStore = DialogStore;
|
|
532
|
-
var _applyDecs$e = (0, _slicedToArray2["default"])(_applyDecs(_DialogStore, [[_mobx.observable, 1, "openedDialogs"], [_mobx.observable, 1, "confirmDialogs"], [_mobx.observable, 1, "userCount"], [_mobx.observable, 1, "participantElectronDialogContainer"], [_mobx.observable, 1, "currentDialogBounds"], [_mobx.observable, 1, "videoWindowBounds"], [_mobx.observable, 1, "currentShareId"], [_mobx.observable, 1, "currentShareType"], [_mobx.observable, 1, "currentShareBounds"], [_mobx.observable, 1, "recordShareBounds"], [_mobx.computed, 3, "connectType"], [_mobx.computed, 3, "hasOwnPstnStream"], [_mobx.computed, 3, "chatRoomState"], [_mobx.action, 2, "setParticipantElectronDialogContainer"], [_setVideoWindowBoundsDecs, 18, "setVideoWindowBounds"], [_decorator.bound, 2, "closeDialogByKey"], [_decorator.bound, 2, "closeDilaogByDialogId"], [_decorator.bound, 2, "closeSystemPreferenceDialog"], [_decorator.bound, 2, "closeChatFromDialog"], [_decorator.bound, 2, "moveChatFromDialogToAside"], [_decorator.bound, 2, "closeConnectionDialog"], [_decorator.bound, 2, "closeParticipantDialog"], [_decorator.bound, 2, "moveParticipantFromDialogToAside"], [_decorator.bound, 2, "resizeVideoWindow"], [_updateCurrentShareContentDecs, 18, "updateCurrentShareContent"], [
|
|
544
|
+
var _applyDecs$e = (0, _slicedToArray2["default"])(_applyDecs(_DialogStore, [[_mobx.observable, 1, "openedDialogs"], [_mobx.observable, 1, "confirmDialogs"], [_mobx.observable, 1, "userCount"], [_mobx.observable, 1, "participantElectronDialogContainer"], [_mobx.observable, 1, "currentDialogBounds"], [_mobx.observable, 1, "videoWindowBounds"], [_mobx.observable, 1, "currentShareId"], [_mobx.observable, 1, "currentShareType"], [_mobx.observable, 1, "currentShareBounds"], [_mobx.observable, 1, "recordShareBounds"], [_mobx.computed, 3, "connectType"], [_mobx.computed, 3, "hasOwnPstnStream"], [_mobx.computed, 3, "chatRoomState"], [_mobx.action, 2, "setParticipantElectronDialogContainer"], [_setVideoWindowBoundsDecs, 18, "setVideoWindowBounds"], [_decorator.bound, 2, "closeDialogByKey"], [_decorator.bound, 2, "closeDilaogByDialogId"], [_decorator.bound, 2, "closeSystemPreferenceDialog"], [_decorator.bound, 2, "closeChatFromDialog"], [_decorator.bound, 2, "moveChatFromDialogToAside"], [_decorator.bound, 2, "closeConnectionDialog"], [_decorator.bound, 2, "closeParticipantDialog"], [_decorator.bound, 2, "moveParticipantFromDialogToAside"], [_decorator.bound, 2, "resizeVideoWindow"], [_updateCurrentShareContentDecs, 18, "updateCurrentShareContent"], [_recordCurrentSharingScreenBoundsDecs, 18, "recordCurrentSharingScreenBounds"], [_handleDialogEventDecs, 18, "_handleDialogEvent"], [_hanleAllUserCountUpdatedDecs, 18, "_hanleAllUserCountUpdated"], [_decorator.bound, 2, "_focusDialog"]], []).e, 11);
|
|
533
545
|
_init_openedDialogs = _applyDecs$e[0];
|
|
534
546
|
_init_confirmDialogs = _applyDecs$e[1];
|
|
535
547
|
_init_userCount = _applyDecs$e[2];
|
|
@@ -26,7 +26,8 @@ var View = exports.View = (0, _mobxReact.observer)(function () {
|
|
|
26
26
|
var DialogComponent = dialogComponentMapByKey.get(dialogKey);
|
|
27
27
|
if (DialogComponent) {
|
|
28
28
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(DialogComponent, {
|
|
29
|
-
params: params
|
|
29
|
+
params: params,
|
|
30
|
+
dialogId: dialogId
|
|
30
31
|
}, dialogId);
|
|
31
32
|
}
|
|
32
33
|
return null;
|
|
@@ -6,6 +6,7 @@ import { FcrUICurrentRoomControlProvider, FcrUIRoomProvider } from '../../provid
|
|
|
6
6
|
import { FcrUIMemberSharedDataSource } from '../../shared-data-source/member-data';
|
|
7
7
|
import { FcrUIAbilityProviderImpl } from '../../providers/ability-provider';
|
|
8
8
|
import { FcrUIScreenShareProvider } from '../../providers/screen-share-provider';
|
|
9
|
+
import { FcrUIScreenShareDataSource } from '../../shared-data-source/screen-share-data-source';
|
|
9
10
|
export declare class EventConfirmUIModule extends UIModule {
|
|
10
11
|
private _store?;
|
|
11
12
|
private _leaveMeetingStore?;
|
|
@@ -17,6 +18,7 @@ export declare class EventConfirmUIModule extends UIModule {
|
|
|
17
18
|
roomProvider?: FcrUIRoomProvider;
|
|
18
19
|
sharedMemberDataSource?: FcrUIMemberSharedDataSource;
|
|
19
20
|
abilityProvider?: FcrUIAbilityProviderImpl;
|
|
21
|
+
screenShareDataSource?: FcrUIScreenShareDataSource;
|
|
20
22
|
onNodeWillActive(): void;
|
|
21
23
|
onNodeWillInactive(): void;
|
|
22
24
|
getComponent(): import("react/jsx-runtime").JSX.Element;
|
|
@@ -44,7 +44,8 @@ var EventConfirmUIModule = exports.EventConfirmUIModule = /*#__PURE__*/function
|
|
|
44
44
|
this._store = new _store2["default"]({
|
|
45
45
|
uiEventStore: this.eventProvider,
|
|
46
46
|
dialogProvider: this.dialogProvider,
|
|
47
|
-
screenShareProvider: this.screenShareProvider
|
|
47
|
+
screenShareProvider: this.screenShareProvider,
|
|
48
|
+
screenShareDataSource: this.screenShareDataSource
|
|
48
49
|
});
|
|
49
50
|
this._leaveMeetingStore = new _store.LeaveMeetingStore(this.privilegeProvider, this.roomProvider, (_this$currentRoomCont = this.currentRoomControlProvider) === null || _this$currentRoomCont === void 0 ? void 0 : _this$currentRoomCont.currentRoomControl, this.sharedMemberDataSource, this.abilityProvider, this.dialogProvider);
|
|
50
51
|
}
|
|
@@ -3,28 +3,36 @@ import { FcrUIEventProvider } from '../../providers/event-provider';
|
|
|
3
3
|
import { FcrUIDialogParams } from '../../type';
|
|
4
4
|
import { FcrUIDialogProvider } from '../../providers/dialog-provider';
|
|
5
5
|
import { FcrUIScreenShareProvider } from '../../providers/screen-share-provider';
|
|
6
|
+
import { CurrentShareBounds } from '../control-bar/types';
|
|
7
|
+
import { FcrUIScreenShareDataSource } from '../../shared-data-source/screen-share-data-source';
|
|
6
8
|
export default class ConfirmStore {
|
|
7
9
|
protected logger: import("agora-foundation/lib/logger").Logger;
|
|
8
10
|
private _disposers;
|
|
9
11
|
private _uiEventProvider;
|
|
10
12
|
private _dialogProvider;
|
|
11
13
|
private _screenShareProvider;
|
|
14
|
+
private _screenShareDataSource;
|
|
12
15
|
private _handleConfirmEventObserver;
|
|
13
16
|
accessor isReplaceShare: boolean;
|
|
17
|
+
accessor calculateMethods: Map<ConfirmContentProps, (bounds?: CurrentShareBounds | null) => void>;
|
|
18
|
+
accessor reposition: number;
|
|
14
19
|
accessor confirms: Map<string, {
|
|
15
20
|
params: ConfirmContentProps;
|
|
16
21
|
timer?: () => void;
|
|
17
22
|
}>;
|
|
23
|
+
accessor screenBounds: CurrentShareBounds | Electron.Rectangle | null;
|
|
18
24
|
get confirmList(): ConfirmContentProps[];
|
|
19
25
|
get isSeizeScreen(): boolean;
|
|
20
|
-
constructor({ uiEventStore, dialogProvider, screenShareProvider, }: {
|
|
26
|
+
constructor({ uiEventStore, dialogProvider, screenShareProvider, screenShareDataSource, }: {
|
|
21
27
|
uiEventStore: FcrUIEventProvider;
|
|
22
28
|
dialogProvider: FcrUIDialogProvider;
|
|
23
29
|
screenShareProvider: FcrUIScreenShareProvider;
|
|
30
|
+
screenShareDataSource: FcrUIScreenShareDataSource;
|
|
24
31
|
});
|
|
25
32
|
addConfirm(payload: FcrUIDialogParams<ConfirmContentProps>): void;
|
|
26
33
|
resetIsReplace(): void;
|
|
27
34
|
release(): void;
|
|
35
|
+
log(log: string): void;
|
|
28
36
|
private _handleConfirmEvent;
|
|
29
37
|
}
|
|
30
38
|
export declare const StoreContext: import("react").Context<ConfirmStore>;
|
|
@@ -32,7 +32,9 @@ require("core-js/modules/es.array.from.js");
|
|
|
32
32
|
require("core-js/modules/es.array.iterator.js");
|
|
33
33
|
require("core-js/modules/es.array.map.js");
|
|
34
34
|
require("core-js/modules/es.array.push.js");
|
|
35
|
+
require("core-js/modules/es.date.to-json.js");
|
|
35
36
|
require("core-js/modules/es.function.bind.js");
|
|
37
|
+
require("core-js/modules/es.json.stringify.js");
|
|
36
38
|
require("core-js/modules/es.map.js");
|
|
37
39
|
require("core-js/modules/es.object.to-string.js");
|
|
38
40
|
require("core-js/modules/es.string.iterator.js");
|
|
@@ -70,8 +72,12 @@ var _mobx = require("mobx");
|
|
|
70
72
|
var _constant = require("../../utilities/constant");
|
|
71
73
|
var _react = require("react");
|
|
72
74
|
var _logger = require("../../utilities/logger");
|
|
75
|
+
var _decorator = require("agora-foundation/lib/decorator");
|
|
76
|
+
var _tools = require("../../utilities/tools");
|
|
77
|
+
var _dialogs = require("../dialog/dialogs");
|
|
78
|
+
var _env = require("agora-foundation/lib/utilities/env");
|
|
73
79
|
var _ConfirmStore;
|
|
74
|
-
var _initProto, _init_isReplaceShare, _init_confirms, _addConfirmDecs, _resetIsReplaceDecs, _handleConfirmEventDecs, _ref;
|
|
80
|
+
var _initProto, _init_isReplaceShare, _init_calculateMethods, _init_reposition, _init_confirms, _init_screenBounds, _addConfirmDecs, _resetIsReplaceDecs, _handleConfirmEventDecs, _ref;
|
|
75
81
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
76
82
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2["default"])(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
77
83
|
function _classPrivateFieldInitSpec(e, t, a) { _checkPrivateRedeclaration(e, t), t.set(e, a); }
|
|
@@ -86,13 +92,17 @@ function _setFunctionName(e, t, n) { "symbol" == _typeof(t) && (t = (t = t.descr
|
|
|
86
92
|
function _checkInRHS(e) { if (Object(e) !== e) throw TypeError("right-hand side of 'in' should be an object, got " + (null !== e ? _typeof(e) : "null")); return e; }
|
|
87
93
|
var _A = /*#__PURE__*/new WeakMap();
|
|
88
94
|
var _B = /*#__PURE__*/new WeakMap();
|
|
95
|
+
var _C = /*#__PURE__*/new WeakMap();
|
|
96
|
+
var _D = /*#__PURE__*/new WeakMap();
|
|
97
|
+
var _E = /*#__PURE__*/new WeakMap();
|
|
89
98
|
_ref = (_addConfirmDecs = [_mobx.action, _mobx.action.bound], _resetIsReplaceDecs = [_mobx.action, _mobx.action.bound], _handleConfirmEventDecs = [_mobx.action, _mobx.action.bound], "logger");
|
|
90
99
|
var ConfirmStore = exports["default"] = /*#__PURE__*/function () {
|
|
91
100
|
function ConfirmStore(_ref2) {
|
|
92
101
|
var _this = this;
|
|
93
102
|
var uiEventStore = _ref2.uiEventStore,
|
|
94
103
|
dialogProvider = _ref2.dialogProvider,
|
|
95
|
-
screenShareProvider = _ref2.screenShareProvider
|
|
104
|
+
screenShareProvider = _ref2.screenShareProvider,
|
|
105
|
+
screenShareDataSource = _ref2.screenShareDataSource;
|
|
96
106
|
(0, _classCallCheck2["default"])(this, ConfirmStore);
|
|
97
107
|
(0, _defineProperty2["default"])(this, _ref, (_initProto(this), (0, _logger.createLogger)({
|
|
98
108
|
prefix: 'ConfirmStore'
|
|
@@ -102,10 +112,14 @@ var ConfirmStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
102
112
|
onEvent: this._handleConfirmEvent.bind(this)
|
|
103
113
|
});
|
|
104
114
|
_classPrivateFieldInitSpec(this, _A, _init_isReplaceShare(this, false));
|
|
105
|
-
_classPrivateFieldInitSpec(this, _B,
|
|
115
|
+
_classPrivateFieldInitSpec(this, _B, _init_calculateMethods(this, new Map()));
|
|
116
|
+
_classPrivateFieldInitSpec(this, _C, _init_reposition(this, 0));
|
|
117
|
+
_classPrivateFieldInitSpec(this, _D, _init_confirms(this, new Map()));
|
|
118
|
+
_classPrivateFieldInitSpec(this, _E, _init_screenBounds(this, (0, _env.isElectron)() ? window.runtime.browserWindow.getBounds() : null));
|
|
106
119
|
this._uiEventProvider = uiEventStore;
|
|
107
120
|
this._dialogProvider = dialogProvider;
|
|
108
121
|
this._screenShareProvider = screenShareProvider;
|
|
122
|
+
this._screenShareDataSource = screenShareDataSource;
|
|
109
123
|
this._uiEventProvider.addObserver(this._handleConfirmEventObserver);
|
|
110
124
|
this._dialogProvider.addObserver(this._handleConfirmEventObserver);
|
|
111
125
|
this._disposers.push((0, _mobx.reaction)(function () {
|
|
@@ -115,6 +129,34 @@ var ConfirmStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
115
129
|
var _value$timer;
|
|
116
130
|
value === null || value === void 0 || (_value$timer = value.timer) === null || _value$timer === void 0 || _value$timer.call(value);
|
|
117
131
|
});
|
|
132
|
+
}), (0, _mobx.reaction)(function () {
|
|
133
|
+
var _this$_screenShareDat;
|
|
134
|
+
return (_this$_screenShareDat = _this._screenShareDataSource) === null || _this$_screenShareDat === void 0 ? void 0 : _this$_screenShareDat.currentShareBounds;
|
|
135
|
+
}, function (bounds) {
|
|
136
|
+
if (bounds) {
|
|
137
|
+
var _dialogWindows$get;
|
|
138
|
+
(_dialogWindows$get = _dialogs.dialogWindows.get(_constant.FcrUIDialogKey.CONFIRM)) === null || _dialogWindows$get === void 0 || _dialogWindows$get.setBounds(bounds);
|
|
139
|
+
_this.calculateMethods.forEach(function (method) {
|
|
140
|
+
return method(bounds);
|
|
141
|
+
});
|
|
142
|
+
_this.logger.info("new sharing bounds is ".concat(JSON.stringify(bounds)));
|
|
143
|
+
_this.screenBounds = bounds;
|
|
144
|
+
} else {
|
|
145
|
+
_this.logger.error("there is have no bounds ".concat(JSON.stringify(bounds)));
|
|
146
|
+
}
|
|
147
|
+
}), (0, _mobx.reaction)(function () {
|
|
148
|
+
return _this.isSeizeScreen;
|
|
149
|
+
}, function (isSeize) {
|
|
150
|
+
if (isSeize && (0, _env.isElectron)()) {
|
|
151
|
+
var _ref3 = (0, _tools.followCorrectDisplay)(_constant.FcrUIDialogKey.CONFIRM, isSeize),
|
|
152
|
+
_bounds = _ref3.bounds;
|
|
153
|
+
_this.screenBounds = _bounds;
|
|
154
|
+
_this.logger.info("new sharing bounds is ".concat(JSON.stringify(_bounds), ", when seize screen emit"));
|
|
155
|
+
}
|
|
156
|
+
}), (0, _mobx.reaction)(function () {
|
|
157
|
+
return _this.screenBounds;
|
|
158
|
+
}, function (bounds) {
|
|
159
|
+
_this.logger.debug("the bounds is changed=>", bounds);
|
|
118
160
|
}));
|
|
119
161
|
}
|
|
120
162
|
return (0, _createClass2["default"])(ConfirmStore, [{
|
|
@@ -126,13 +168,37 @@ var ConfirmStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
126
168
|
_classPrivateFieldSet(_A, this, v);
|
|
127
169
|
}
|
|
128
170
|
}, {
|
|
129
|
-
key: "
|
|
171
|
+
key: "calculateMethods",
|
|
130
172
|
get: function get() {
|
|
131
173
|
return _classPrivateFieldGet(_B, this);
|
|
132
174
|
},
|
|
133
175
|
set: function set(v) {
|
|
134
176
|
_classPrivateFieldSet(_B, this, v);
|
|
135
177
|
}
|
|
178
|
+
}, {
|
|
179
|
+
key: "reposition",
|
|
180
|
+
get: function get() {
|
|
181
|
+
return _classPrivateFieldGet(_C, this);
|
|
182
|
+
},
|
|
183
|
+
set: function set(v) {
|
|
184
|
+
_classPrivateFieldSet(_C, this, v);
|
|
185
|
+
}
|
|
186
|
+
}, {
|
|
187
|
+
key: "confirms",
|
|
188
|
+
get: function get() {
|
|
189
|
+
return _classPrivateFieldGet(_D, this);
|
|
190
|
+
},
|
|
191
|
+
set: function set(v) {
|
|
192
|
+
_classPrivateFieldSet(_D, this, v);
|
|
193
|
+
}
|
|
194
|
+
}, {
|
|
195
|
+
key: "screenBounds",
|
|
196
|
+
get: function get() {
|
|
197
|
+
return _classPrivateFieldGet(_E, this);
|
|
198
|
+
},
|
|
199
|
+
set: function set(v) {
|
|
200
|
+
_classPrivateFieldSet(_E, this, v);
|
|
201
|
+
}
|
|
136
202
|
}, {
|
|
137
203
|
key: "confirmList",
|
|
138
204
|
get: function get() {
|
|
@@ -169,7 +235,11 @@ var ConfirmStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
169
235
|
}),
|
|
170
236
|
timer: timer
|
|
171
237
|
};
|
|
172
|
-
if (
|
|
238
|
+
if (this.confirms.has(dialogId)) {
|
|
239
|
+
this.calculateMethods.forEach(function (method) {
|
|
240
|
+
return method(_this2.screenBounds);
|
|
241
|
+
});
|
|
242
|
+
} else {
|
|
173
243
|
this.confirms.set(dialogId, confirmParams);
|
|
174
244
|
}
|
|
175
245
|
var confirmInstance = this.confirms.get(dialogId);
|
|
@@ -210,18 +280,31 @@ var ConfirmStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
210
280
|
key: "release",
|
|
211
281
|
value: function release() {
|
|
212
282
|
this.confirms.clear();
|
|
283
|
+
this.calculateMethods.clear();
|
|
213
284
|
this._disposers.forEach(function (disposer) {
|
|
214
285
|
return disposer();
|
|
215
286
|
});
|
|
216
287
|
this._dialogProvider.removeObserver(this._handleConfirmEventObserver);
|
|
217
288
|
this._uiEventProvider.removeObserver(this._handleConfirmEventObserver);
|
|
218
289
|
}
|
|
290
|
+
}, {
|
|
291
|
+
key: "log",
|
|
292
|
+
value: function log(_log) {
|
|
293
|
+
this.logger.info(_log);
|
|
294
|
+
}
|
|
219
295
|
}, {
|
|
220
296
|
key: "_handleConfirmEvent",
|
|
221
297
|
value: function _handleConfirmEvent(action, payload) {
|
|
222
298
|
if ((payload === null || payload === void 0 ? void 0 : payload.dialogKey) === _constant.FcrUIDialogKey.CONFIRM) {
|
|
223
299
|
switch (action) {
|
|
224
300
|
case _constant.FcrUIAction.OPEN_DIALOG:
|
|
301
|
+
if (this.screenBounds) {
|
|
302
|
+
var _dialogWindows$get2;
|
|
303
|
+
(_dialogWindows$get2 = _dialogs.dialogWindows.get(_constant.FcrUIDialogKey.CONFIRM)) === null || _dialogWindows$get2 === void 0 || _dialogWindows$get2.setBounds(this.screenBounds);
|
|
304
|
+
this.logger.info("open confirm dialog with bounds ".concat(JSON.stringify(this.screenBounds)));
|
|
305
|
+
} else {
|
|
306
|
+
this.logger.error("the screen bounds is ".concat(JSON.stringify(this.screenBounds)));
|
|
307
|
+
}
|
|
225
308
|
this.addConfirm(payload);
|
|
226
309
|
break;
|
|
227
310
|
case _constant.FcrUIAction.CLOSE_DIALOG:
|
|
@@ -233,8 +316,11 @@ var ConfirmStore = exports["default"] = /*#__PURE__*/function () {
|
|
|
233
316
|
}]);
|
|
234
317
|
}();
|
|
235
318
|
_ConfirmStore = ConfirmStore;
|
|
236
|
-
var _applyDecs$e = (0, _slicedToArray2["default"])(_applyDecs(_ConfirmStore, [[_mobx.observable, 1, "isReplaceShare"], [_mobx.observable, 1, "confirms"], [_mobx.computed, 3, "confirmList"], [_addConfirmDecs, 18, "addConfirm"], [_resetIsReplaceDecs, 18, "resetIsReplace"], [_handleConfirmEventDecs, 18, "_handleConfirmEvent"]], []).e,
|
|
319
|
+
var _applyDecs$e = (0, _slicedToArray2["default"])(_applyDecs(_ConfirmStore, [[_mobx.observable, 1, "isReplaceShare"], [_mobx.observable, 1, "calculateMethods"], [_mobx.observable, 1, "reposition"], [_mobx.observable, 1, "confirms"], [_mobx.observable, 1, "screenBounds"], [_mobx.computed, 3, "confirmList"], [_addConfirmDecs, 18, "addConfirm"], [_resetIsReplaceDecs, 18, "resetIsReplace"], [_decorator.bound, 2, "log"], [_handleConfirmEventDecs, 18, "_handleConfirmEvent"]], []).e, 6);
|
|
237
320
|
_init_isReplaceShare = _applyDecs$e[0];
|
|
238
|
-
|
|
239
|
-
|
|
321
|
+
_init_calculateMethods = _applyDecs$e[1];
|
|
322
|
+
_init_reposition = _applyDecs$e[2];
|
|
323
|
+
_init_confirms = _applyDecs$e[3];
|
|
324
|
+
_init_screenBounds = _applyDecs$e[4];
|
|
325
|
+
_initProto = _applyDecs$e[5];
|
|
240
326
|
var StoreContext = exports.StoreContext = /*#__PURE__*/(0, _react.createContext)(null);
|
|
@@ -21,7 +21,10 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
21
21
|
value: true
|
|
22
22
|
});
|
|
23
23
|
exports.View = void 0;
|
|
24
|
+
require("core-js/modules/es.array.concat.js");
|
|
24
25
|
require("core-js/modules/es.array.map.js");
|
|
26
|
+
require("core-js/modules/es.date.to-json.js");
|
|
27
|
+
require("core-js/modules/es.json.stringify.js");
|
|
25
28
|
require("core-js/modules/esnext.async-iterator.map.js");
|
|
26
29
|
require("core-js/modules/esnext.iterator.map.js");
|
|
27
30
|
require("core-js/modules/web.timers.js");
|
|
@@ -38,8 +41,6 @@ var _react2 = require("@use-gesture/react");
|
|
|
38
41
|
var _env = require("agora-foundation/lib/utilities/env");
|
|
39
42
|
var _tools = require("../../utilities/tools");
|
|
40
43
|
var _platform = require("../../utilities/platform");
|
|
41
|
-
var _dialogs = require("../dialog/dialogs");
|
|
42
|
-
var _constant = require("../../utilities/constant");
|
|
43
44
|
var _jsxRuntime = require("react/jsx-runtime");
|
|
44
45
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
45
46
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2["default"])(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
@@ -72,7 +73,9 @@ var ConfirmWindow = (0, _mobxReact.observer)(function (_ref2) {
|
|
|
72
73
|
var _rndRef$current;
|
|
73
74
|
var confirm = _ref2.confirm;
|
|
74
75
|
var _useContext2 = (0, _react.useContext)(_store.StoreContext),
|
|
75
|
-
|
|
76
|
+
screenBounds = _useContext2.screenBounds,
|
|
77
|
+
calculateMethods = _useContext2.calculateMethods,
|
|
78
|
+
log = _useContext2.log;
|
|
76
79
|
var _ref3 = (0, _env.isElectron)() ? (0, _react.useContext)(_useElectron.DialogInstanceContext) : {},
|
|
77
80
|
browserWindow = _ref3.browserWindow;
|
|
78
81
|
var rndRef = (0, _react.useRef)(null);
|
|
@@ -81,48 +84,35 @@ var ConfirmWindow = (0, _mobxReact.observer)(function (_ref2) {
|
|
|
81
84
|
width: confirm.width || 320,
|
|
82
85
|
height: confirm.height ? confirm.height : ((_rndRef$current = rndRef.current) === null || _rndRef$current === void 0 ? void 0 : _rndRef$current.getBoundingClientRect().height) || (confirm.icon ? 160 : 150)
|
|
83
86
|
};
|
|
84
|
-
var baseBounds = {
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
return {
|
|
99
|
-
nearDisplay: nearDisplay,
|
|
100
|
-
controlbar: controlbar,
|
|
101
|
-
mainWindowBounds: mainWindowBounds,
|
|
102
|
-
needControlbar: needControlbar
|
|
103
|
-
};
|
|
104
|
-
}, []),
|
|
105
|
-
nearDisplay = _useMemo.nearDisplay,
|
|
106
|
-
controlbar = _useMemo.controlbar,
|
|
107
|
-
mainWindowBounds = _useMemo.mainWindowBounds,
|
|
108
|
-
needControlbar = _useMemo.needControlbar;
|
|
109
|
-
var x = nearDisplay.width / 2 - defaultSize.width / 2;
|
|
110
|
-
var y = nearDisplay.height / 2 - defaultSize.height / 2;
|
|
87
|
+
var baseBounds = (0, _react.useMemo)(function () {
|
|
88
|
+
var _ref4 = screenBounds || {
|
|
89
|
+
width: window.innerWidth,
|
|
90
|
+
height: window.innerHeight
|
|
91
|
+
},
|
|
92
|
+
width = _ref4.width,
|
|
93
|
+
height = _ref4.height;
|
|
94
|
+
return {
|
|
95
|
+
x: width / 2 - defaultSize.width / 2,
|
|
96
|
+
y: height / 2 - defaultSize.height / 2,
|
|
97
|
+
width: width,
|
|
98
|
+
height: height
|
|
99
|
+
};
|
|
100
|
+
}, [screenBounds]);
|
|
111
101
|
var _useState = (0, _react.useState)({
|
|
112
|
-
x: x,
|
|
113
|
-
y: y
|
|
102
|
+
x: baseBounds.x,
|
|
103
|
+
y: baseBounds.y
|
|
114
104
|
}),
|
|
115
105
|
_useState2 = (0, _slicedToArray2["default"])(_useState, 2),
|
|
116
106
|
bounds = _useState2[0],
|
|
117
107
|
setBounds = _useState2[1];
|
|
118
|
-
var bind = (0, _react2.useDrag)(function (
|
|
119
|
-
var
|
|
120
|
-
dx =
|
|
121
|
-
dy =
|
|
108
|
+
var bind = (0, _react2.useDrag)(function (_ref5) {
|
|
109
|
+
var _ref5$delta = (0, _slicedToArray2["default"])(_ref5.delta, 2),
|
|
110
|
+
dx = _ref5$delta[0],
|
|
111
|
+
dy = _ref5$delta[1];
|
|
122
112
|
var x = bounds.x + dx;
|
|
123
113
|
var y = bounds.y + dy;
|
|
124
|
-
var maxX =
|
|
125
|
-
var maxY =
|
|
114
|
+
var maxX = baseBounds.width - defaultSize.width;
|
|
115
|
+
var maxY = baseBounds.height - defaultSize.height;
|
|
126
116
|
var coord = {
|
|
127
117
|
x: Math.max(0, Math.min(maxX, x)),
|
|
128
118
|
y: Math.max(0, Math.min(maxY, y))
|
|
@@ -130,29 +120,48 @@ var ConfirmWindow = (0, _mobxReact.observer)(function (_ref2) {
|
|
|
130
120
|
setBounds(coord);
|
|
131
121
|
});
|
|
132
122
|
var ignoreMouseTimer = (0, _react.useRef)();
|
|
133
|
-
function
|
|
134
|
-
if (
|
|
135
|
-
|
|
123
|
+
function recalculate(bounds) {
|
|
124
|
+
if (windowFocusTimerRef.current) {
|
|
125
|
+
clearTimeout(windowFocusTimerRef.current);
|
|
126
|
+
windowFocusTimerRef.current = undefined;
|
|
127
|
+
}
|
|
128
|
+
log("call handle checkMouseOver condition: ".concat((0, _env.isElectron)(), " && ").concat((0, _platform.isWindows)(), " && ").concat(browserWindow, " && ").concat(rndRef.current, " && ").concat(JSON.stringify(screenBounds)));
|
|
129
|
+
if ((0, _env.isElectron)() && (0, _platform.isWindows)() && browserWindow && rndRef.current && screenBounds) {
|
|
130
|
+
log("handleCheckMouseOver called , the bounds is ".concat(JSON.stringify(bounds || screenBounds)));
|
|
136
131
|
(0, _tools.handleCheckMouseOver)({
|
|
137
132
|
elem: rndRef.current,
|
|
138
133
|
browserWindow: browserWindow,
|
|
139
|
-
screenBounds: screenBounds,
|
|
134
|
+
screenBounds: bounds || screenBounds,
|
|
140
135
|
callback: function callback(timerId) {
|
|
141
136
|
windowFocusTimerRef.current = timerId;
|
|
142
137
|
}
|
|
143
138
|
});
|
|
144
139
|
}
|
|
145
140
|
}
|
|
141
|
+
var handleRecalculate = function handleRecalculate() {
|
|
142
|
+
return recalculate();
|
|
143
|
+
};
|
|
146
144
|
(0, _react.useEffect)(function () {
|
|
147
|
-
browserWindow === null || browserWindow === void 0 || browserWindow.setIgnoreMouseEvents(
|
|
148
|
-
|
|
149
|
-
|
|
145
|
+
browserWindow === null || browserWindow === void 0 || browserWindow.setIgnoreMouseEvents(true, {
|
|
146
|
+
forward: true
|
|
147
|
+
});
|
|
148
|
+
recalculate();
|
|
149
|
+
!calculateMethods.has(confirm) && calculateMethods.set(confirm, recalculate);
|
|
150
|
+
(0, _env.isElectron)() && (0, _platform.isWindows)() && window.runtime.screen.addListener('display-removed', handleRecalculate);
|
|
150
151
|
return function () {
|
|
151
152
|
clearTimeout(windowFocusTimerRef.current);
|
|
153
|
+
calculateMethods["delete"](confirm);
|
|
152
154
|
ignoreMouseTimer.current && clearInterval(ignoreMouseTimer.current);
|
|
153
|
-
(0, _env.isElectron)() && (0, _platform.isWindows)() && window.runtime.screen.removeListener('display-removed',
|
|
155
|
+
(0, _env.isElectron)() && (0, _platform.isWindows)() && window.runtime.screen.removeListener('display-removed', handleRecalculate);
|
|
154
156
|
};
|
|
155
157
|
}, [rndRef.current /** hack 处理 windows 下,弹出窗口层级不对的问题 */]);
|
|
158
|
+
(0, _react.useEffect)(function () {
|
|
159
|
+
log("when screen bounds changed ".concat(JSON.stringify(screenBounds)));
|
|
160
|
+
(0, _platform.isWindows)() && setBounds({
|
|
161
|
+
x: baseBounds.x,
|
|
162
|
+
y: baseBounds.y
|
|
163
|
+
});
|
|
164
|
+
}, [screenBounds]);
|
|
156
165
|
var handleMouseEnter = function handleMouseEnter() {
|
|
157
166
|
ignoreMouseTimer.current && clearInterval(ignoreMouseTimer.current);
|
|
158
167
|
if ((0, _env.isElectron)()) {
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { UIModule } from '../../base';
|
|
2
2
|
import { FcrUIDeviceProvider } from '../../providers/device-provider';
|
|
3
3
|
import { FcrUIConnectionProvider } from '../../providers/room-provider';
|
|
4
|
-
|
|
4
|
+
import { FcrUISharedSettingDataSource } from '../../shared-data-source/setting';
|
|
5
|
+
export declare enum SoundEffectType {
|
|
5
6
|
INCOMMING_MESSAGE = "incomming_message",
|
|
6
7
|
INCOMMING_PRIVATE_MESSAGE = "incomming_private_message",
|
|
7
8
|
REMOTE_USER_JOINED = "remote_user_joined",
|
|
@@ -20,6 +21,7 @@ export declare class SoundEffectUIModule extends UIModule {
|
|
|
20
21
|
private _userControl;
|
|
21
22
|
private _deviceStore;
|
|
22
23
|
private _connectionControl;
|
|
24
|
+
sharedSettingDataSource: FcrUISharedSettingDataSource | undefined;
|
|
23
25
|
deviceProvider: FcrUIDeviceProvider | undefined;
|
|
24
26
|
connectionProvider: FcrUIConnectionProvider | undefined;
|
|
25
27
|
private _duration;
|
|
@@ -45,4 +47,3 @@ export declare class SoundEffectUIModule extends UIModule {
|
|
|
45
47
|
private _handleUserJoined;
|
|
46
48
|
handlePlaySoundEffect(name: SoundEffectType): void;
|
|
47
49
|
}
|
|
48
|
-
export {};
|