VirtualBox

Ignore:
Timestamp:
Feb 13, 2007 7:40:16 AM (18 years ago)
Author:
vboxsync
Message:

Fixed problem that you cannot do Select until you refresh the dialog after adding a VDI if this VDI was the first added to VDM.

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

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Frontends/VirtualBox/ui/VBoxDiskImageManagerDlg.ui

    r568 r852  
    629629    <function specifier="static" returnType="QString">composeCdToolTip( CDVDImage &amp;, VBoxMedia::Status = VBoxMedia::Ok )</function>
    630630    <function specifier="static" returnType="QString">composeFdToolTip( CFloppyImage &amp;, VBoxMedia::Status = VBoxMedia::Ok )</function>
     631    <function access="protected">clearInfoPanes()</function>
    631632    <function access="protected">prepareToRefresh( int aTotal = 0 )</function>
    632633</functions>
  • trunk/src/VBox/Frontends/VirtualBox/ui/VBoxDiskImageManagerDlg.ui.h

    r777 r852  
    12551255    }
    12561256    else
    1257     {   
     1257    {
    12581258        /* insert already enumerated media */
    12591259        const VBoxMediaList &list = vboxGlobal().currentMediaList();
     
    12881288    for (it = list.begin(); it != list.end(); ++ it)
    12891289        mediaAdded (*it);
    1290    
     1290
    12911291    /* select the first item if the previous saved item is not found
    12921292     * or no current item at all */
     
    13271327    cdsView->adjustColumn (2);
    13281328    cdsView->adjustColumn (1);
    1329    
     1329
    13301330    fdsView->adjustColumn (1);
    13311331    fdsView->adjustColumn (2);
     
    13781378    if (!vboxGlobal().isMediaEnumerationStarted())
    13791379        setCurrentItem (getListView (aMedia.type), item);
     1380    if (item == getCurrentListView()->currentItem())
     1381        processCurrentChanged (item);
    13801382}
    13811383
     
    14601462
    14611463
    1462 void VBoxDiskImageManagerDlg::prepareToRefresh (int aTotal)
    1463 {
    1464     /* info panel clearing */
     1464void VBoxDiskImageManagerDlg::clearInfoPanes()
     1465{
    14651466    hdsPane1->clear();
    14661467    hdsPane2->clear(), hdsPane3->clear();
     
    14681469    cdsPane1->clear(), cdsPane2->clear();
    14691470    fdsPane1->clear(), fdsPane2->clear();
     1471}
     1472
     1473
     1474void VBoxDiskImageManagerDlg::prepareToRefresh (int aTotal)
     1475{
     1476    /* info panel clearing */
     1477    clearInfoPanes();
    14701478
    14711479    /* prepare progressbar */
     
    14811489
    14821490    /* store the current list selections */
    1483    
     1491
    14841492    QListViewItem *item;
    14851493    DiskImageItem *di;
     
    14881496    di = (item && item->rtti() == 1001) ? static_cast <DiskImageItem *> (item) : 0;
    14891497    hdSelectedId = di ? di->getUuid() : QString::null;
    1490  
     1498
    14911499    item = cdsView->currentItem();
    14921500    di = (item && item->rtti() == 1001) ? static_cast <DiskImageItem *> (item) : 0;
    1493     cdSelectedId = di ? di->getUuid() : QString::null; 
     1501    cdSelectedId = di ? di->getUuid() : QString::null;
    14941502
    14951503    item = fdsView->currentItem();
     
    16671675        }
    16681676    }
     1677    else
     1678        clearInfoPanes();
    16691679}
    16701680
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