VirtualBox

Changeset 100160 in vbox


Ignore:
Timestamp:
Jun 12, 2023 5:40:05 PM (18 months ago)
Author:
vboxsync
Message:

FE/Qt: bugref:9080. Qt6 compliant version of pixmap resize.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/medium/viso/UIVisoCreator.cpp

    r100159 r100160  
    299299{
    300300    Q_UNUSED(pEvent);
     301    if (m_pOverlayWidget && m_fShowSettingsDialog)
     302    {
    301303#ifndef VBOX_IS_QT6_OR_LATER
    302     if (m_pOverlayWidget && m_fShowSettingsDialog)
    303     {
    304304        const QPixmap *pLabelPixmap = m_pOverlayWidget->pixmap();
    305305        if (pLabelPixmap)
     
    309309                m_pOverlayWidget->setPixmap(newPixmap);
    310310        }
    311     }
     311#else
     312        QPixmap labelPixmap = m_pOverlayWidget->pixmap();
     313        QPixmap newPixmap = labelPixmap.scaled(m_pOverlayWidget->size(), Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
     314        if (!newPixmap.isNull())
     315            m_pOverlayWidget->setPixmap(newPixmap);
    312316#endif
     317    }
    313318}
    314319
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