VirtualBox

Changeset 69069 in vbox for trunk


Ignore:
Timestamp:
Oct 13, 2017 12:39:49 PM (7 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
118354
Message:

FE/Qt: bugref:9019: Selector UI: W/a for macOS allowing to automatically update native toolbar after any of its actions changed.

File:
1 edited

Legend:

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

    r69057 r69069  
    18171817        m_pToolBar->addAction(actionPool()->action(UIActionIndexST_M_Machine_S_Discard));
    18181818        m_pToolBar->addAction(actionPool()->action(UIActionIndexST_M_Machine_M_StartOrShow));
     1819#ifdef VBOX_WS_MAC
     1820        // WORKAROUND:
     1821        // Actually Qt should do that itself but by some unknown reason it sometimes
     1822        // forget to update toolbar after changing its actions on cocoa platform.
     1823        connect(actionPool()->action(UIActionIndexST_M_Machine_S_New), &UIAction::changed,
     1824                m_pToolBar, static_cast<void(UIToolBar::*)(void)>(&UIToolBar::update));
     1825        connect(actionPool()->action(UIActionIndexST_M_Machine_S_Settings), &UIAction::changed,
     1826                m_pToolBar, static_cast<void(UIToolBar::*)(void)>(&UIToolBar::update));
     1827        connect(actionPool()->action(UIActionIndexST_M_Machine_S_Discard), &UIAction::changed,
     1828                m_pToolBar, static_cast<void(UIToolBar::*)(void)>(&UIToolBar::update));
     1829        connect(actionPool()->action(UIActionIndexST_M_Machine_M_StartOrShow), &UIAction::changed,
     1830                m_pToolBar, static_cast<void(UIToolBar::*)(void)>(&UIToolBar::update));
     1831#endif /* VBOX_WS_MAC */
    18191832
    18201833        /* Create Machine tab-bar: */
Note: See TracChangeset for help on using the changeset viewer.

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