VirtualBox

Changeset 69702 in vbox


Ignore:
Timestamp:
Nov 15, 2017 12:19:52 PM (7 years ago)
Author:
vboxsync
Message:

FE/Qt: bugref:8694: HiDPI support fix for menu-bar & status-bar editors: Set strict scaleable margin instead of default one (s.a. r119037).

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

Legend:

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

    r69669 r69702  
    877877        const int iStandardMetric = QApplication::style()->pixelMetric(QStyle::PM_SmallIconSize) / 2;
    878878        const int iMinimumMetric = QApplication::style()->pixelMetric(QStyle::PM_SmallIconSize) / 4;
    879         /* Standard margins should not be too small: */
    880         iLeft   = qMax(iLeft,   iStandardMetric);
    881         iTop    = qMax(iTop,    iStandardMetric);
    882         iRight  = qMax(iRight,  iStandardMetric);
    883         iBottom = qMax(iBottom, iStandardMetric);
     879        /* Standard margins should not be too small/large: */
     880        iLeft   = iStandardMetric;
     881        iTop    = iStandardMetric;
     882        iRight  = iStandardMetric;
     883        iBottom = iStandardMetric;
    884884        /* Top margin should be smaller for the common case: */
    885885        if (iTop >= iMinimumMetric)
  • trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIStatusBarEditorWindow.cpp

    r69669 r69702  
    496496        const int iStandardMetric = QApplication::style()->pixelMetric(QStyle::PM_SmallIconSize) / 2;
    497497        const int iMinimumMetric = QApplication::style()->pixelMetric(QStyle::PM_SmallIconSize) / 4;
    498         /* Standard margins should not be too small: */
    499         iLeft   = qMax(iLeft,   iStandardMetric);
    500         iTop    = qMax(iTop,    iStandardMetric);
    501         iRight  = qMax(iRight,  iStandardMetric);
    502         iBottom = qMax(iBottom, iStandardMetric);
     498        /* Standard margins should not be too small/large: */
     499        iLeft   = iStandardMetric;
     500        iTop    = iStandardMetric;
     501        iRight  = iStandardMetric;
     502        iBottom = iStandardMetric;
    503503        /* Bottom margin should be smaller for the common case: */
    504504        if (iBottom >= iMinimumMetric)
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