VirtualBox

Ignore:
Timestamp:
May 21, 2008 8:30:39 AM (17 years ago)
Author:
vboxsync
Message:

FE/Qt: NLS: Prepare to synchronize 1.6.2.

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

Legend:

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

    r8917 r8997  
    15611561
    15621562    if (dbgStatisticsAction)
    1563         dbgStatisticsAction->setMenuText (tr ("&Statistics..."));
     1563        dbgStatisticsAction->setMenuText (tr ("&Statistics...", "debug action"));
    15641564    if (dbgCommandLineAction)
    1565         dbgCommandLineAction->setMenuText (tr ("&Command line..."));
     1565        dbgCommandLineAction->setMenuText (tr ("&Command Line...", "debug action"));
    15661566    if (dbgLoggingAction)
    1567         dbgLoggingAction->setMenuText (tr ("&Logging..."));
     1567        dbgLoggingAction->setMenuText (tr ("&Logging...", "debug action"));
    15681568#endif
    15691569
  • trunk/src/VBox/Frontends/VirtualBox/ui/VBoxVMInformationDlg.ui.h

    r8918 r8997  
    706706}
    707707
    708 
    709 /* Old code for two columns support */
    710 #if 0
    711 void VBoxVMInformationDlg::refreshStatistics()
    712 {
    713     QString table = "<p><table border=0 cellspacing=0 cellpadding=0 width=100%>%1</table></p>";
    714     QString hdrRow = "<tr><td align=left><img src='%1'></td><td colspan=4><b>%2</b></td></tr>";
    715     QString subRow = "<tr><td></td><td colspan=2><nobr><u>%1</u></nobr></td>"
    716                                   "<td colspan=2><nobr><u>%2</u></nobr></td></tr>";
    717     QString bdyRow = "<tr><td></td><td><nobr>%1</nobr></td><td width=50%><nobr>%2</nobr></td>"
    718                                   "<td><nobr>%3</nobr></td><td width=50%><nobr>%4</nobr></td></tr>";
    719     QString paragraph = "<tr><td colspan=5></td></tr>";
    720     QString interline = "<tr><td colspan=5><font size=1>&nbsp;</font></td></tr>";
    721     QString result;
    722 
    723     /* Screen & VT-X Runtime Parameters */
    724     if (!mSession.isNull())
    725     {
    726         CConsole console = mSession.GetConsole();
    727         ULONG bpp = console.GetDisplay().GetBitsPerPixel();
    728         QString resolution = QString ("%1x%2")
    729             .arg (console.GetDisplay().GetWidth())
    730             .arg (console.GetDisplay().GetHeight());
    731         if (bpp)
    732             resolution += QString ("x%1").arg (bpp);
    733         QString virt = console.GetDebugger().GetHWVirtExEnabled() ?
    734             tr ("Enabled") : tr ("Disabled");
    735 
    736         result += hdrRow.arg ("state_running_16px.png").arg (tr ("Runtime Attributes"));
    737         result += bdyRow.arg (tr ("Screen Resolution")) .arg (resolution)
    738                         .arg (tr ("Hardware Virtualization")).arg (virt);
    739         result += paragraph;
    740     }
    741 
    742     /* Hard Disk Statistics. */
    743     result += hdrRow.arg ("hd_16px.png").arg (tr ("Hard Disks Statistics"));
    744 
    745     result += subRow.arg (tr ("Primary Master")).arg (tr ("Primary Slave"));
    746     result += composeArticle (QString::null, 0, 1, 4, 5);
    747     result += composeArticle ("B", 2, 3, 6, 7);
    748     result += interline;
    749 
    750     result += subRow.arg (tr ("Secondary Master")).arg (tr ("Secondary Slave"));
    751     result += composeArticle (QString::null, 8, 9, 12, 13);
    752     result += composeArticle ("B", 10, 11, 14, 15);
    753     result += paragraph;
    754 
    755     /* Network Adapters Statistics. Counters are currently missed. */
    756     result += hdrRow.arg ("nw_16px.png").arg (tr ("Network Adapter Statistics"));
    757     result += subRow.arg (tr ("Adapter 1")).arg (tr ("Adapter 2"));
    758     result += composeArticle ("B", 16, 17, 18, 19);
    759 
    760     /* Show full composed page. */
    761     mStatisticText->setText (table.arg (result));
    762 }
    763 
    764 
    765 QString VBoxVMInformationDlg::composeArticle (const QString &aUnits,
    766                                               int aStart1, int aFinish1,
    767                                               int aStart2, int aFinish2)
    768 {
    769     QString bdyRow = "<tr><td></td><td><nobr>%1</nobr></td><td width=50%><nobr>%2</nobr></td>"
    770                                   "<td><nobr>%3</nobr></td><td width=50%><nobr>%4</nobr></td></tr>";
    771 
    772     QString result;
    773 
    774     int id1 = aStart1, id2 = aStart2;
    775     while (id1 <= aFinish1 || id2 <= aFinish2)
    776     {
    777         QString line = bdyRow;
    778         /* Processing first column */
    779         if (id1 > aFinish1)
    780         {
    781             line = line.arg (QString::null).arg (QString::null)
    782                        .arg (QString::null).arg (QString::null);
    783         }
    784         else if (mValuesMap.contains (mNamesMap.keys() [id1]))
    785         {
    786             line = line.arg (mNamesMap.values() [id1]);
    787             ULONG64 value = mValuesMap.values() [id1].toULongLong();
    788             line = aUnits.isNull() ?
    789                 line.arg (QString ("%L1").arg (value)) :
    790                 line.arg (QString ("%L1 %2").arg (value).arg (aUnits));
    791         }
    792         /* Processing second column */
    793         if (id2 > aFinish2)
    794         {
    795             line = line.arg (QString::null).arg (QString::null)
    796                        .arg (QString::null).arg (QString::null);
    797         }
    798         else if (mValuesMap.contains (mNamesMap.keys() [id2]))
    799         {
    800             line = line.arg (mNamesMap.values() [id2]);
    801             ULONG64 value = mValuesMap.values() [id2].toULongLong();
    802             line = aUnits.isNull() ?
    803                 line.arg (QString ("%L1").arg (value)) :
    804                 line.arg (QString ("%L1 %2").arg (value).arg (aUnits));
    805         }
    806         result += line;
    807         ++ id1; ++ id2;
    808     }
    809 
    810     return result;
    811 }
    812 #endif
    813 
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