VirtualBox

Changeset 64628 in vbox for trunk


Ignore:
Timestamp:
Nov 10, 2016 11:30:13 AM (8 years ago)
Author:
vboxsync
Message:

FE/Qt: bugref:8636: UIDesktopWidgetWatchdog: Fallback mechanism for invisible windows, to make sure they always do what we expect.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/globals/UIDesktopWidgetWatchdog.cpp

    r64627 r64628  
    2323# include <QApplication>
    2424# include <QDesktopWidget>
     25# ifdef VBOX_WS_X11
     26#  include <QTimer>
     27# endif
    2528# if QT_VERSION >= 0x050000
    2629#  include <QScreen>
     
    6063    /** Constructs invisible window for the host-screen with @a iHostScreenIndex. */
    6164    UIInvisibleWindow(int iHostScreenIndex);
     65
     66private slots:
     67
     68    /** Performs fallback drop. */
     69    void sltFallback();
    6270
    6371private:
     
    95103    if (vboxGlobal().isCompositingManagerRunning())
    96104        setAttribute(Qt::WA_TranslucentBackground);
     105    /* Install fallback handler: */
     106    QTimer::singleShot(5000, this, SLOT(sltFallback()));
     107}
     108
     109void UIInvisibleWindow::sltFallback()
     110{
     111    LogRel(("GUI: UIInvisibleWindow::sltFallback: %s event haven't came. "
     112            "Screen: %d, work area: %dx%d x %dx%d\n",
     113            !m_fMoveCame ? "Move" : !m_fResizeCame ? "Resize" : "Some",
     114            m_iHostScreenIndex, x(), y(), width(), height()));
     115    emit sigHostScreenAvailableGeometryCalculated(m_iHostScreenIndex, QRect(x(), y(), width(), height()));
    97116}
    98117
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