VirtualBox

Changeset 88684 in vbox


Ignore:
Timestamp:
Apr 23, 2021 4:05:59 PM (4 years ago)
Author:
vboxsync
Message:

FE/Qt: bugref:8161: Snapshot pane: It's now important to clear stale COM data when NULL VM passed.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/src/snapshots/UISnapshotPane.cpp

    r88409 r88684  
    915915        /* Update details-widget: */
    916916        if (pSnapshotItem->isCurrentStateItem())
    917             m_pDetailsWidget->setData(m_comMachine);
     917        {
     918            if (m_comMachine.isNull())
     919                m_pDetailsWidget->clearData();
     920            else
     921                m_pDetailsWidget->setData(m_comMachine);
     922        }
    918923        else
    919924            m_pDetailsWidget->setData(*pSnapshotItem, pSnapshotItem->snapshot());
    920925    }
     926    /* Cleanup invisible details-widget: */
     927    else
     928        m_pDetailsWidget->clearData();
    921929}
    922930
     
    10591067    {
    10601068        if (pSnapshotItem->isCurrentStateItem())
    1061             m_pDetailsWidget->setData(m_comMachine);
     1069        {
     1070            if (m_comMachine.isNull())
     1071                m_pDetailsWidget->clearData();
     1072            else
     1073                m_pDetailsWidget->setData(m_comMachine);
     1074        }
    10621075        else
    10631076            m_pDetailsWidget->setData(*pSnapshotItem, pSnapshotItem->snapshot());
    10641077    }
     1078    /* Cleanup invisible details-widget: */
     1079    else
     1080        m_pDetailsWidget->clearData();
    10651081
    10661082    /* Notify listeners: */
     
    13551371    if (m_comMachine.isNull())
    13561372    {
    1357         sltHandleCurrentItemChange();
     1373        /* Clear the tree: */
     1374        m_pSnapshotTree->clear();
    13581375        return;
    13591376    }
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