VirtualBox

Ignore:
Timestamp:
Aug 5, 2014 1:57:21 PM (10 years ago)
Author:
vboxsync
Message:

FE/Qt: 7476: Runtime UI: Full-screen mode should avoid handling available-area-change signal (this should prevent flickering on Cinnamon).

Location:
trunk/src/VBox/Frontends/VirtualBox/src/runtime
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMachineLogic.cpp

    r52236 r52275  
    611611}
    612612
    613 void UIMachineLogic::sltHostScreenCountChanged()
     613void UIMachineLogic::sltHostScreenCountChange()
    614614{
    615615    LogRel(("UIMachineLogic: Host-screen count changed.\n"));
     
    620620}
    621621
    622 void UIMachineLogic::sltHostScreenGeometryChanged()
     622void UIMachineLogic::sltHostScreenGeometryChange()
    623623{
    624624    LogRel(("UIMachineLogic: Host-screen geometry changed.\n"));
     625
     626    /* Make sure all machine-window(s) have proper geometry: */
     627    foreach (UIMachineWindow *pMachineWindow, machineWindows())
     628        pMachineWindow->showInNecessaryMode();
     629}
     630
     631void UIMachineLogic::sltHostScreenAvailableAreaChange()
     632{
     633    LogRel(("UIMachineLogic: Host-screen available-area changed.\n"));
    625634
    626635    /* Make sure all machine-window(s) have proper geometry: */
     
    805814
    806815    /* Host-screen-change updaters: */
    807     connect(uisession(), SIGNAL(sigHostScreenCountChanged()), this, SLOT(sltHostScreenCountChanged()));
    808     connect(uisession(), SIGNAL(sigHostScreenGeometryChanged()), this, SLOT(sltHostScreenGeometryChanged()));
     816    connect(uisession(), SIGNAL(sigHostScreenCountChange()), this, SLOT(sltHostScreenCountChange()));
     817    connect(uisession(), SIGNAL(sigHostScreenGeometryChange()), this, SLOT(sltHostScreenGeometryChange()));
     818    connect(uisession(), SIGNAL(sigHostScreenAvailableAreaChange()), this, SLOT(sltHostScreenAvailableAreaChange()));
    809819
    810820    /* Frame-buffer connections: */
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIMachineLogic.h

    r52236 r52275  
    135135    virtual void sltShowWindows();
    136136#endif /* RT_OS_DARWIN */
     137    /** Handles guest-screen count change. */
    137138    virtual void sltGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo);
    138139
    139     /* Qt callback handler: */
    140     virtual void sltHostScreenCountChanged();
    141     virtual void sltHostScreenGeometryChanged();
     140    /** Handles host-screen count change. */
     141    virtual void sltHostScreenCountChange();
     142    /** Handles host-screen geometry change. */
     143    virtual void sltHostScreenGeometryChange();
     144    /** Handles host-screen available-area change. */
     145    virtual void sltHostScreenAvailableAreaChange();
    142146
    143147protected:
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/UISession.cpp

    r52239 r52275  
    885885
    886886    /* Notify current machine-logic: */
    887     emit sigHostScreenCountChanged();
     887    emit sigHostScreenCountChange();
    888888}
    889889
     
    896896
    897897    /* Notify current machine-logic: */
    898     emit sigHostScreenGeometryChanged();
     898    emit sigHostScreenGeometryChange();
     899}
     900
     901void UISession::sltHandleHostScreenAvailableAreaChange()
     902{
     903    LogRelFlow(("UISession: Host-screen available-area changed.\n"));
     904
     905    /* Notify current machine-logic: */
     906    emit sigHostScreenAvailableAreaChange();
    899907}
    900908
     
    10841092            this, SLOT(sltHandleHostScreenGeometryChange()));
    10851093    connect(QApplication::desktop(), SIGNAL(workAreaResized(int)),
    1086             this, SLOT(sltHandleHostScreenGeometryChange()));
     1094            this, SLOT(sltHandleHostScreenAvailableAreaChange()));
    10871095#endif /* !Q_WS_MAC */
    10881096}
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/UISession.h

    r52239 r52275  
    251251    void sigGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo);
    252252
    253     /* Notifiers: Qt callback stuff: */
    254     void sigHostScreenCountChanged();
    255     void sigHostScreenGeometryChanged();
     253    /** Notifies about host-screen count change. */
     254    void sigHostScreenCountChange();
     255    /** Notifies about host-screen geometry change. */
     256    void sigHostScreenGeometryChange();
     257    /** Notifies about host-screen available-area change. */
     258    void sigHostScreenAvailableAreaChange();
    256259
    257260    /* Session signals: */
     
    291294    void sltCheckIfHostDisplayChanged();
    292295#endif /* RT_OS_DARWIN */
     296
     297    /** Handles host-screen count change. */
    293298    void sltHandleHostScreenCountChange();
     299    /** Handles host-screen geometry change. */
    294300    void sltHandleHostScreenGeometryChange();
     301    /** Handles host-screen available-area change. */
     302    void sltHandleHostScreenAvailableAreaChange();
    295303
    296304private:
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/fullscreen/UIMachineLogicFullscreen.cpp

    r52239 r52275  
    402402void UIMachineLogicFullscreen::sltGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo)
    403403{
    404     LogRel(("UIMachineLogicFullscreen::sltGuestMonitorChange: Guest-screen count changed.\n"));
     404    LogRel(("UIMachineLogicFullscreen: Guest-screen count changed.\n"));
    405405
    406406    /* Update multi-screen layout before any window update: */
     
    421421}
    422422
    423 void UIMachineLogicFullscreen::sltHostScreenCountChanged()
    424 {
    425     LogRel(("UIMachineLogicFullscreen::sltHostScreenCountChanged: Host-screen count changed.\n"));
     423void UIMachineLogicFullscreen::sltHostScreenCountChange()
     424{
     425    LogRel(("UIMachineLogicFullscreen: Host-screen count changed.\n"));
    426426
    427427    /* Update multi-screen layout before any window update: */
     
    431431    /* Call to base-class for Lion and previous: */
    432432    if (vboxGlobal().osRelease() <= MacOSXRelease_Lion)
    433         UIMachineLogic::sltHostScreenCountChanged();
     433        UIMachineLogic::sltHostScreenCountChange();
    434434    /* Revalidate 'fullscreen' windows for ML and next: */
    435435    else revalidateNativeFullScreen();
    436436#else /* !Q_WS_MAC */
    437437    /* Call to base-class: */
    438     UIMachineLogic::sltHostScreenCountChanged();
     438    UIMachineLogic::sltHostScreenCountChange();
    439439#endif /* !Q_WS_MAC */
     440}
     441
     442void UIMachineLogicFullscreen::sltHostScreenAvailableAreaChange()
     443{
     444    LogRel(("UIMachineLogicFullscreen: Host-screen available-area change ignored.\n"));
    440445}
    441446
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/fullscreen/UIMachineLogicFullscreen.h

    r52184 r52275  
    9494    void sltScreenLayoutChanged();
    9595
    96     void sltGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo);
    97     void sltHostScreenCountChanged();
     96    /** Handles guest-screen count change. */
     97    virtual void sltGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo);
     98    /** Handles host-screen count change. */
     99    virtual void sltHostScreenCountChange();
     100    /** Handles host-screen available-area change. */
     101    virtual void sltHostScreenAvailableAreaChange();
    98102
    99103private:
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/seamless/UIMachineLogicSeamless.cpp

    r52239 r52275  
    176176void UIMachineLogicSeamless::sltGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo)
    177177{
    178     LogRelFlow(("UIMachineLogicSeamless: Guest-screen count changed.\n"));
     178    LogRel(("UIMachineLogicSeamless: Guest-screen count changed.\n"));
    179179
    180180    /* Update multi-screen layout before any window update: */
     
    187187}
    188188
    189 void UIMachineLogicSeamless::sltHostScreenCountChanged()
    190 {
    191     LogRelFlow(("UIMachineLogicSeamless: Host-screen count changed.\n"));
     189void UIMachineLogicSeamless::sltHostScreenCountChange()
     190{
     191    LogRel(("UIMachineLogicSeamless: Host-screen count changed.\n"));
    192192
    193193    /* Update multi-screen layout before any window update: */
     
    195195
    196196    /* Call to base-class: */
    197     UIMachineLogic::sltHostScreenCountChanged();
     197    UIMachineLogic::sltHostScreenCountChange();
    198198}
    199199
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/seamless/UIMachineLogicSeamless.h

    r52184 r52275  
    5757    void sltScreenLayoutChanged();
    5858
    59     void sltGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo);
    60     void sltHostScreenCountChanged();
     59    /** Handles guest-screen count change. */
     60    virtual void sltGuestMonitorChange(KGuestMonitorChangedEventType changeType, ulong uScreenId, QRect screenGeo);
     61    /** Handles host-screen count change. */
     62    virtual void sltHostScreenCountChange();
    6163
    6264#ifndef RT_OS_DARWIN
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette