VirtualBox

Changeset 53238 in vbox


Ignore:
Timestamp:
Nov 5, 2014 2:01:08 PM (10 years ago)
Author:
vboxsync
Message:

FE/Qt: 7556: Selector UI: Details-pane: Machine Preview: Trying to fix the crash.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/selector/graphics/details/UIGMachinePreview.cpp

    r52978 r53238  
    217217                            .scaled(imageAspectRatioSize(m_vRect.size(), QSize(uGuestWidth, uGuestHeight)),
    218218                                    Qt::IgnoreAspectRatio, Qt::SmoothTransformation);
     219                    /* And detach that copy to make it deep: */
     220                    image.detach();
    219221                    /* Dim image to give it required look: */
    220222                    dimImage(image);
     
    260262                    image = QImage(screenData.data(), size.width(), size.height(), QImage::Format_RGB32);
    261263                    /* And detach that copy to make it deep: */
    262                     (uchar*)image.bits();
     264                    image.detach();
    263265                    /* Dim image to give it required look for PAUSED state: */
    264266                    if (machineState == KMachineState_Paused)
     
    276278            /* Shallow copy that image: */
    277279            m_pPreviewImg = new QImage(image);
    278             /* And detach that copy: */
    279             m_pPreviewImg->bits();
     280            /* And detach that copy to make it deep: */
     281            m_pPreviewImg->detach();
    280282        }
    281283
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