VirtualBox

Changeset 68277 in vbox for trunk


Ignore:
Timestamp:
Aug 3, 2017 10:18:39 AM (7 years ago)
Author:
vboxsync
Message:

FE/Qt: bugref:8900: Selector UI: Yet another workaround for X11 hosts which has troubles updating dynamic tool-bar contents on startup (replaces r117360).

Location:
trunk/src/VBox/Frontends/VirtualBox/src/selector
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/selector/UISelectorWindow.cpp

    r68260 r68277  
    145145}
    146146
     147void UISelectorWindow::sltHandlePolishEvent()
     148{
     149    // WORKAROUND:
     150    // By some reason some of X11 DEs unable to update()
     151    // tab-bars on startup.  Let's try to _create_ them instead.
     152    /* Make sure 'Details' and 'Snapshots' Machine tools ares opened at startup for now: */
     153    actionPool()->action(UIActionIndexST_M_Tools_M_Machine_Snapshots)->trigger();
     154    actionPool()->action(UIActionIndexST_M_Tools_M_Machine_Details)->trigger();
     155}
     156
    147157#if defined(VBOX_WS_X11) && QT_VERSION >= 0x050000
    148158void UISelectorWindow::sltHandleHostScreenAvailableAreaChange()
     
    12621272    QTimer::singleShot(0, this, SLOT(sltHandleMediumEnumerationFinish()));
    12631273
    1264     // WORKAROUND:
    1265     // By some reason some of X11 DEs unable to update
    1266     // tab-bars on startup.  Let's try to do it ourselves.
    1267     m_pTabBarMachine->update();
    1268     m_pTabBarGlobal->update();
     1274    /* Call for async polishing: */
     1275    QMetaObject::invokeMethod(this, "sltHandlePolishEvent", Qt::QueuedConnection);
    12691276}
    12701277
     
    13171324    prepareWidgets();
    13181325    prepareConnections();
    1319 
    1320     /* Make sure 'Details' and 'Snapshots' Machine tools ares opened at startup for now: */
    1321     actionPool()->action(UIActionIndexST_M_Tools_M_Machine_Snapshots)->trigger();
    1322     actionPool()->action(UIActionIndexST_M_Tools_M_Machine_Details)->trigger();
    13231326
    13241327    /* Load settings: */
  • trunk/src/VBox/Frontends/VirtualBox/src/selector/UISelectorWindow.h

    r68230 r68277  
    7575
    7676private slots:
     77
     78    /** Handles polishing in the async way. */
     79    void sltHandlePolishEvent();
    7780
    7881#if defined(VBOX_WS_X11) && QT_VERSION >= 0x050000
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