Changeset 49025 in vbox
- Timestamp:
- Oct 10, 2013 12:00:25 PM (11 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/runtime
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMachineLogic.cpp
r49013 r49025 537 537 } 538 538 539 void UIMachineLogic::sltHostScreenCountChanged( int /*cHostScreenCount*/)539 void UIMachineLogic::sltHostScreenCountChanged() 540 540 { 541 541 /* Deliver event to all machine-windows: */ … … 721 721 722 722 /* Host-screen-change updaters: */ 723 connect(uisession(), SIGNAL(sigHostScreenCountChanged( int)),724 this, SLOT(sltHostScreenCountChanged( int)));723 connect(uisession(), SIGNAL(sigHostScreenCountChanged()), 724 this, SLOT(sltHostScreenCountChanged())); 725 725 connect(uisession(), SIGNAL(sigHostScreenGeometryChanged()), 726 726 this, SLOT(sltHostScreenGeometryChanged())); -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMachineLogic.h
r49013 r49025 112 112 113 113 /* Qt callback handler: */ 114 virtual void sltHostScreenCountChanged( int cHostScreenCount);114 virtual void sltHostScreenCountChanged(); 115 115 virtual void sltHostScreenGeometryChanged(); 116 116 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UISession.cpp
r49015 r49025 85 85 * Notifies about @a display configuration change. 86 86 * Corresponding change described by CoreGraphics @a flags. 87 * UISession::sltHandleHostScreenGeometryChange() is calledthrough @a pHandlerObject to handle this callback.87 * Calls for corresponding UISession slots through @a pHandlerObject to handle this callback. 88 88 * 89 89 * @note Last argument (@a pHandlerObject) must always be valid pointer to UISession object. 90 * @note Calls for UISession::sltHandleHostScreenCountChange() if display count was changed. 91 * @note Calls for UISession::sltHandleHostScreenGeometryChange() if display mode was changed. 90 92 */ 91 93 void cgDisplayReconfigurationCallback(CGDirectDisplayID display, CGDisplayChangeSummaryFlags flags, void *pHandlerObject) 92 94 { 95 /* Handle 'display-add' case: */ 96 if (flags & kCGDisplayAddFlag) 97 { 98 LogRelFlow(("UISession::cgDisplayReconfigurationCallback: Display added.\n")); 99 100 /* Ask receiver to handle our callback, can't believe I'm using r_c here... */ 101 UISession *pReceiver = reinterpret_cast<UISession*>(pHandlerObject); 102 QTimer::singleShot(0, pReceiver, SLOT(sltHandleHostScreenCountChange())); 103 } 104 /* Handle 'display-remove' case: */ 105 else if (flags & kCGDisplayRemoveFlag) 106 { 107 LogRelFlow(("UISession::cgDisplayReconfigurationCallback: Display removed.\n")); 108 109 /* Ask receiver to handle our callback, can't believe I'm using r_c here... */ 110 UISession *pReceiver = reinterpret_cast<UISession*>(pHandlerObject); 111 QTimer::singleShot(0, pReceiver, SLOT(sltHandleHostScreenCountChange())); 112 } 93 113 /* Handle 'mode-set' case: */ 94 if (flags & kCGDisplaySetModeFlag)114 else if (flags & kCGDisplaySetModeFlag) 95 115 { 96 116 LogRelFlow(("UISession::cgDisplayReconfigurationCallback: Display mode changed.\n")); … … 100 120 QTimer::singleShot(0, pReceiver, SLOT(sltHandleHostScreenGeometryChange())); 101 121 } 122 Q_UNUSED(display); 102 123 } 103 124 #endif /* Q_WS_MAC */ … … 817 838 } 818 839 840 void UISession::sltHandleHostScreenCountChange() 841 { 842 LogRelFlow(("UISession: Host-screen count changed.\n")); 843 844 /* Notify current machine-logic: */ 845 emit sigHostScreenCountChanged(); 846 } 847 819 848 void UISession::sltHandleHostScreenGeometryChange() 820 849 { … … 913 942 connect(this, SIGNAL(sigCloseRuntimeUI()), this, SLOT(sltCloseRuntimeUI())); 914 943 944 /* Install Qt display reconfiguration callbacks: */ 915 945 connect(QApplication::desktop(), SIGNAL(screenCountChanged(int)), 916 this, SIGNAL(sigHostScreenCountChanged(int))); 917 918 /* Install Qt reconfiguration callbacks: */ 946 this, SLOT(sltHandleHostScreenCountChange())); 919 947 connect(QApplication::desktop(), SIGNAL(resized(int)), 920 948 this, SLOT(sltHandleHostScreenGeometryChange())); -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UISession.h
r49013 r49025 209 209 210 210 /* Notifiers: Qt callback stuff: */ 211 void sigHostScreenCountChanged( int cHostScreenCount);211 void sigHostScreenCountChanged(); 212 212 void sigHostScreenGeometryChanged(); 213 213 … … 234 234 void sltGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo); 235 235 236 /* Handler: Host callback stuff: */ 236 /* Handlers: Host callback stuff: */ 237 void sltHandleHostScreenCountChange(); 237 238 void sltHandleHostScreenGeometryChange(); 238 239 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/fullscreen/UIMachineLogicFullscreen.cpp
r49013 r49025 136 136 } 137 137 138 void UIMachineLogicFullscreen::sltHostScreenCountChanged( int cScreenCount)138 void UIMachineLogicFullscreen::sltHostScreenCountChanged() 139 139 { 140 140 LogRelFlow(("UIMachineLogicFullscreen: Host-screen count changed.\n")); … … 144 144 145 145 /* Call to base-class: */ 146 UIMachineLogic::sltHostScreenCountChanged( cScreenCount);146 UIMachineLogic::sltHostScreenCountChanged(); 147 147 } 148 148 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/fullscreen/UIMachineLogicFullscreen.h
r48920 r49025 54 54 #endif /* Q_WS_MAC */ 55 55 void sltGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo); 56 void sltHostScreenCountChanged( int cScreenCount);56 void sltHostScreenCountChanged(); 57 57 58 58 private: -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/seamless/UIMachineLogicSeamless.cpp
r49013 r49025 136 136 } 137 137 138 void UIMachineLogicSeamless::sltHostScreenCountChanged( int cScreenCount)138 void UIMachineLogicSeamless::sltHostScreenCountChanged() 139 139 { 140 140 LogRelFlow(("UIMachineLogicSeamless: Host-screen count changed.\n")); … … 144 144 145 145 /* Call to base-class: */ 146 UIMachineLogic::sltHostScreenCountChanged( cScreenCount);146 UIMachineLogic::sltHostScreenCountChanged(); 147 147 } 148 148 -
trunk/src/VBox/Frontends/VirtualBox/src/runtime/seamless/UIMachineLogicSeamless.h
r48920 r49025 53 53 54 54 void sltGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo); 55 void sltHostScreenCountChanged( int cScreenCount);55 void sltHostScreenCountChanged(); 56 56 57 57 private:
Note:
See TracChangeset
for help on using the changeset viewer.