VirtualBox

Changeset 102502 in vbox for trunk/src


Ignore:
Timestamp:
Dec 6, 2023 1:25:13 PM (18 months ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
160646
Message:

FE/Qt: A bit of reordering for UICommon to place everything propely.

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

Legend:

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

    r102482 r102502  
    953953    QSettings settings(m_strBrandingConfigFilePath, QSettings::IniFormat);
    954954    return settings.value(QString("%1").arg(strKey)).toString();
     955}
     956
     957#ifdef VBOX_WS_NIX
     958bool UICommon::X11ServerAvailable() const
     959{
     960    return VBGHDisplayServerTypeIsXAvailable(m_enmDisplayServerType);
     961}
     962
     963VBGHDISPLAYSERVERTYPE UICommon::displayServerType() const
     964{
     965    return m_enmDisplayServerType;
     966}
     967#endif
     968
     969QString UICommon::hostOperatingSystem() const
     970{
     971    if (!m_comHost.isOk())
     972        return QString();
     973    return m_comHost.GetOperatingSystem();
    955974}
    956975
     
    30143033    m_fWrappersValid = true;
    30153034}
    3016 
    3017 #ifdef VBOX_WS_NIX
    3018 bool UICommon::X11ServerAvailable() const
    3019 {
    3020     return VBGHDisplayServerTypeIsXAvailable(m_enmDisplayServerType);
    3021 }
    3022 
    3023 VBGHDISPLAYSERVERTYPE UICommon::displayServerType() const
    3024 {
    3025     return m_enmDisplayServerType;
    3026 }
    3027 #endif
    3028 
    3029 QString UICommon::hostOperatingSystem() const
    3030 {
    3031     if (!m_comHost.isOk())
    3032         return QString();
    3033     return m_comHost.GetOperatingSystem();
    3034 }
  • trunk/src/VBox/Frontends/VirtualBox/src/globals/UICommon.h

    r102482 r102502  
    176176        /** Returns whether UICommon instance cleanup is in progress. */
    177177        bool isCleaningUp() const { return m_fCleaningUp; }
    178 
    179 #ifdef VBOX_WS_MAC
    180         /** Returns whether macOS is in Dark mode. */
    181         bool isInDarkMode() const { return m_fDarkMode; }
    182 #endif
    183178    /** @} */
    184179
     
    218213    /** @name Host OS stuff.
    219214     * @{ */
    220         /** Loads the color theme. */
    221         void loadColorTheme();
     215#ifdef VBOX_WS_MAC
     216        /** macOS: Returns whether macOS is in Dark mode. */
     217        bool isInDarkMode() const { return m_fDarkMode; }
     218#endif
    222219
    223220#ifdef VBOX_WS_NIX
     
    233230        /** Returns the name of the host OS by using IHost::getOperatingSystem. */
    234231        QString hostOperatingSystem() const;
     232
     233        /** Loads the color theme. */
     234        void loadColorTheme();
    235235    /** @} */
    236236
     
    643643        bool  m_fDataCommitted;
    644644#endif
    645 
    646 #ifdef VBOX_WS_MAC
    647         /** Holds whether macOS is in Dark mode. */
    648         bool  m_fDarkMode;
    649 #endif
    650645    /** @} */
    651646
     
    658653    /** @name Host OS stuff.
    659654     * @{ */
     655#ifdef VBOX_WS_MAC
     656        /** macOS: Holds whether macOS is in Dark mode. */
     657        bool  m_fDarkMode;
     658#endif
     659
    660660#ifdef VBOX_WS_NIX
    661661        /** X11: Holds the #X11WMType of the Window Manager we are running under. */
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