VirtualBox

Ignore:
Timestamp:
Mar 13, 2008 2:33:18 PM (17 years ago)
Author:
vboxsync
svn:sync-xref-src-repo-rev:
28880
Message:

Main: Applied SATA changes from #2406. Increased XML settings version format from 1.2 to 1.3.pre.

Location:
trunk/src/VBox/Frontends/VirtualBox4/ui
Files:
5 edited

Legend:

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

    r7250 r7442  
    22052205                if (hda.GetHardDisk().GetId() == aItemId)
    22062206                {
    2207                     machine.DetachHardDisk (hda.GetController(),
    2208                                             hda.GetDeviceNumber());
     2207                    machine.DetachHardDisk (hda.GetBus(),
     2208                                            hda.GetChannel(),
     2209                                            hda.GetDevice());
    22092210                    if (!machine.isOk())
    22102211                        vboxProblem().cannotDetachHardDisk (this,
    2211                             machine, hda.GetController(), hda.GetDeviceNumber());
     2212                            machine, hda.GetBus(), hda.GetChannel(), hda.GetDevice());
    22122213                    break;
    22132214                }
  • trunk/src/VBox/Frontends/VirtualBox4/ui/VBoxNewVMWzd.ui.h

    r7282 r7442  
    369369        {
    370370            CMachine m = session.GetMachine();
    371             m.AttachHardDisk (uuidHD, KDiskControllerType_IDE0, 0);
     371            m.AttachHardDisk (uuidHD, KStorageBus_IDE, 0, 0);
    372372            if (m.isOk())
    373373            {
     
    380380            else
    381381                vboxProblem().cannotAttachHardDisk (this, m, uuidHD,
    382                                                     KDiskControllerType_IDE0, 0);
     382                                                    KStorageBus_IDE, 0, 0);
    383383            session.Close();
    384384        }
  • trunk/src/VBox/Frontends/VirtualBox4/ui/VBoxVMInformationDlg.ui

    r7207 r7442  
    160160    <function returnType="QString" access="pritave">parseStatistics( const QString &amp; )</function>
    161161    <function access="private">refreshStatistics()</function>
    162     <function returnType="QString" access="pritave">formatHardDisk( const QString &amp;, KDiskControllerType, LONG, int, int )</function>
     162    <function returnType="QString" access="pritave">formatHardDisk( const QString &amp;, KStorageBus, LONG, LONG, int, int )</function>
    163163    <function returnType="QString" access="pritave">formatAdapter( const QString &amp;, ULONG, int, int )</function>
    164164    <function returnType="QString" access="pritave">composeArticle( const QString &amp;, int, int )</function>
  • trunk/src/VBox/Frontends/VirtualBox4/ui/VBoxVMInformationDlg.ui.h

    r7250 r7442  
    485485
    486486    /* Hard Disk Statistics. */
     487    QString primaryMaster = QString ("%1 %2")
     488        .arg (vboxGlobal().toString (KStorageBus_IDE, 0))
     489        .arg (vboxGlobal().toString (KStorageBus_IDE, 0, 0));
     490    QString primarySlave = QString ("%1 %2")
     491        .arg (vboxGlobal().toString (KStorageBus_IDE, 0))
     492        .arg (vboxGlobal().toString (KStorageBus_IDE, 0, 1));
     493    QString secondarySlave = QString ("%1 %2")
     494        .arg (vboxGlobal().toString (KStorageBus_IDE, 1))
     495        .arg (vboxGlobal().toString (KStorageBus_IDE, 1, 1));
     496
    487497    result += hdrRow.arg (":/hd_16px.png").arg (tr ("IDE Hard Disk Statistics"));
    488     result += formatHardDisk (tr ("Primary Master"), KDiskControllerType_IDE0, 0, 0, 1);
     498    result += formatHardDisk (primaryMaster, KStorageBus_IDE, 0, 0, 0, 1);
    489499    result += interline;
    490     result += formatHardDisk (tr ("Primary Slave"), KDiskControllerType_IDE0, 1, 4, 5);
     500    result += formatHardDisk (primarySlave, KStorageBus_IDE, 0, 1, 4, 5);
    491501    result += interline;
    492     result += formatHardDisk (tr ("Secondary Slave"), KDiskControllerType_IDE1, 1, 12, 13);
     502    result += formatHardDisk (secondarySlave, KStorageBus_IDE, 1, 1, 12, 13);
    493503    result += paragraph;
    494504
    495505    /* CD/DVD-ROM Statistics. */
    496506    result += hdrRow.arg (":/cd_16px.png").arg (tr ("CD/DVD-ROM Statistics"));
    497     result += formatHardDisk (QString::null /* tr ("Secondary Master") */,
    498                               KDiskControllerType_IDE1, 0, 8, 9);
     507    result += formatHardDisk (QString::null,
     508                              KStorageBus_IDE, 1, 0, 8, 9);
    499509    result += paragraph;
    500510
     
    515525
    516526QString VBoxVMInformationDlg::formatHardDisk (const QString &aName,
    517                                               KDiskControllerType aType,
    518                                               LONG aSlot, int aStart, int aFinish)
     527                                              KStorageBus aBus, LONG aChannel,
     528                                              LONG aDevice, int aStart, int aFinish)
    519529{
    520530    if (mSession.isNull())
     
    525535
    526536    QString result = aName.isNull() ? QString::null : header.arg (aName);
    527     CHardDisk hd = machine.GetHardDisk (aType, aSlot);
    528     if (!hd.isNull() || (aType == KDiskControllerType_IDE1 && aSlot == 0))
     537    CHardDisk hd = machine.GetHardDisk (aBus, aChannel, aDevice);
     538    if (!hd.isNull() || (aBus == KStorageBus_IDE && aChannel == 1 && aDevice == 0))
    529539    {
    530540        result += composeArticle (QString::null, aStart, aFinish);
  • trunk/src/VBox/Frontends/VirtualBox4/ui/VBoxVMSettingsDlg.ui.h

    r7250 r7442  
    17181718        struct
    17191719        {
    1720             KDiskControllerType ctl;
     1720            KStorageBus bus;
     1721            LONG channel;
    17211722            LONG dev;
    17221723            struct {
     
    17291730        diskSet[] =
    17301731        {
    1731             { KDiskControllerType_IDE0, 0, {grbHDA, cbHDA, txHDA, &uuidHDA} },
    1732             { KDiskControllerType_IDE0, 1, {grbHDB, cbHDB, txHDB, &uuidHDB} },
    1733             { KDiskControllerType_IDE1, 1, {grbHDD, cbHDD, txHDD, &uuidHDD} },
     1732            { KStorageBus_IDE, 0, 0, {grbHDA, cbHDA, txHDA, &uuidHDA} },
     1733            { KStorageBus_IDE, 0, 1, {grbHDB, cbHDB, txHDB, &uuidHDB} },
     1734            { KStorageBus_IDE, 1, 1, {grbHDD, cbHDD, txHDD, &uuidHDD} },
    17341735        };
    17351736
     
    17451746            for (uint i = 0; i < SIZEOF_ARRAY (diskSet); i++)
    17461747            {
    1747                 if (diskSet [i].ctl == hda.GetController() &&
    1748                     diskSet [i].dev == hda.GetDeviceNumber())
     1748                if (diskSet [i].bus == hda.GetBus() &&
     1749                    diskSet [i].channel == hda.GetChannel() &&
     1750                    diskSet [i].dev == hda.GetDevice())
    17491751                {
    17501752                    CHardDisk hd = hda.GetHardDisk();
     
    21012103        struct
    21022104        {
    2103             KDiskControllerType ctl;
     2105            KStorageBus bus;
     2106            LONG channel;
    21042107            LONG dev;
    21052108            struct {
     
    21102113        diskSet[] =
    21112114        {
    2112             { KDiskControllerType_IDE0, 0, {grbHDA, &uuidHDA} },
    2113             { KDiskControllerType_IDE0, 1, {grbHDB, &uuidHDB} },
    2114             { KDiskControllerType_IDE1, 1, {grbHDD, &uuidHDD} }
     2115            { KStorageBus_IDE, 0, 0, {grbHDA, &uuidHDA} },
     2116            { KStorageBus_IDE, 0, 1, {grbHDB, &uuidHDB} },
     2117            { KStorageBus_IDE, 1, 1, {grbHDD, &uuidHDD} }
    21152118        };
    21162119
     
    21262129            for (uint i = 0; i < SIZEOF_ARRAY (diskSet); i++)
    21272130            {
    2128                 if (diskSet [i].ctl == hda.GetController() &&
    2129                     diskSet [i].dev == hda.GetDeviceNumber())
     2131                if (diskSet [i].bus == hda.GetBus() &&
     2132                    diskSet [i].channel == hda.GetChannel() &&
     2133                    diskSet [i].dev == hda.GetDevice())
    21302134                {
    2131                     cmachine.DetachHardDisk (diskSet [i].ctl, diskSet [i].dev);
     2135                    cmachine.DetachHardDisk (diskSet [i].bus, diskSet [i].channel, diskSet [i].dev);
    21322136                    if (!cmachine.isOk())
    21332137                        vboxProblem().cannotDetachHardDisk (
    2134                             this, cmachine, diskSet [i].ctl, diskSet [i].dev);
     2138                            this, cmachine, diskSet [i].bus, diskSet [i].channel, diskSet [i].dev);
    21352139                }
    21362140            }
     
    21432147            if (diskSet [i].data.grb->isChecked() && !(*newId).isNull())
    21442148            {
    2145                 cmachine.AttachHardDisk (*newId, diskSet [i].ctl, diskSet [i].dev);
     2149                cmachine.AttachHardDisk (*newId, diskSet [i].bus, diskSet [i].channel, diskSet [i].dev);
    21462150                if (!cmachine.isOk())
    21472151                    vboxProblem().cannotAttachHardDisk (
    2148                         this, cmachine, *newId, diskSet [i].ctl, diskSet [i].dev);
     2152                        this, cmachine, *newId, diskSet [i].bus, diskSet [i].channel, diskSet [i].dev);
    21492153            }
    21502154        }
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette