Index: /trunk/src/VBox/Frontends/VirtualBox/src/manager/details/UIDetailsElements.cpp
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/manager/details/UIDetailsElements.cpp	(revision 75425)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/manager/details/UIDetailsElements.cpp	(revision 75426)
@@ -231,31 +231,27 @@
 {
     /* Acquire corresponding machine: */
-    CMachine machine = property("machine").value<CMachine>();
-    if (machine.isNull())
-        return;
-
-    /* Prepare table: */
-    UITextTable table;
-
-    /* Gather information: */
-    if (machine.GetAccessible())
-    {
-        /* Machine name: */
-        table << UITextTableLine(QApplication::translate("UIDetails", "Name", "details (general)"), machine.GetName());
-
-        /* Operating system type: */
+    CMachine comMachine = property("machine").value<CMachine>();
+    if (comMachine.isNull())
+        return;
+
+    /* Prepare table: */
+    UITextTable table;
+
+    /* Gather information: */
+    if (comMachine.GetAccessible())
+    {
+        /* Name: */
+        table << UITextTableLine(QApplication::translate("UIDetails", "Name", "details (general)"), comMachine.GetName());
+
+        /* Operating System: */
         table << UITextTableLine(QApplication::translate("UIDetails", "Operating System", "details (general)"),
-                                 vboxGlobal().vmGuestOSTypeDescription(machine.GetOSTypeId()));
-
-        /* Location of the settings file: */
-        const QString strSettingsFilePath = machine.GetSettingsFilePath();
-        if (!strSettingsFilePath.isEmpty())
-        {
-            table << UITextTableLine(QApplication::translate("UIDetails", "Settings File Location", "details (general)"),
-                                     QDir::toNativeSeparators(QFileInfo(strSettingsFilePath).absolutePath()));
-        }
-
-        /* Get groups: */
-        QStringList groups = machine.GetGroups().toList();
+                                 vboxGlobal().vmGuestOSTypeDescription(comMachine.GetOSTypeId()));
+
+        /* Settings File Location: */
+        table << UITextTableLine(QApplication::translate("UIDetails", "Settings File Location", "details (general)"),
+                                 QDir::toNativeSeparators(QFileInfo(comMachine.GetSettingsFilePath()).absolutePath()));
+
+        /* Groups: */
+        QStringList groups = comMachine.GetGroups().toList();
         /* Do not show groups for machine which is in root group only: */
         if (groups.size() == 1)
@@ -286,20 +282,20 @@
 {
     /* Acquire corresponding machine: */
-    CMachine machine = property("machine").value<CMachine>();
-    if (machine.isNull())
-        return;
-
-    /* Prepare table: */
-    UITextTable table;
-
-    /* Gather information: */
-    if (machine.GetAccessible())
+    CMachine comMachine = property("machine").value<CMachine>();
+    if (comMachine.isNull())
+        return;
+
+    /* Prepare table: */
+    UITextTable table;
+
+    /* Gather information: */
+    if (comMachine.GetAccessible())
     {
         /* Base memory: */
         table << UITextTableLine(QApplication::translate("UIDetails", "Base Memory", "details (system)"),
-                                 QApplication::translate("UIDetails", "%1 MB", "details").arg(machine.GetMemorySize()));
+                                 QApplication::translate("UIDetails", "%1 MB", "details").arg(comMachine.GetMemorySize()));
 
         /* CPU count: */
-        int cCPU = machine.GetCPUCount();
+        const int cCPU = comMachine.GetCPUCount();
         if (cCPU > 1)
             table << UITextTableLine(QApplication::translate("UIDetails", "Processors", "details (system)"),
@@ -307,8 +303,8 @@
 
         /* CPU execution cap: */
-        int iCPUExecCap = machine.GetCPUExecutionCap();
-        if (iCPUExecCap < 100)
+        const int iCPUExecutionCap = comMachine.GetCPUExecutionCap();
+        if (iCPUExecutionCap < 100)
             table << UITextTableLine(QApplication::translate("UIDetails", "Execution Cap", "details (system)"),
-                                     QApplication::translate("UIDetails", "%1%", "details").arg(iCPUExecCap));
+                                     QApplication::translate("UIDetails", "%1%", "details").arg(iCPUExecutionCap));
 
         /* Boot-order: */
@@ -316,8 +312,8 @@
         for (ulong i = 1; i <= vboxGlobal().virtualBox().GetSystemProperties().GetMaxBootPosition(); ++i)
         {
-            KDeviceType device = machine.GetBootOrder(i);
-            if (device == KDeviceType_Null)
+            const KDeviceType enmDeviceType = comMachine.GetBootOrder(i);
+            if (enmDeviceType == KDeviceType_Null)
                 continue;
-            bootOrder << gpConverter->toString(device);
+            bootOrder << gpConverter->toString(enmDeviceType);
         }
         if (bootOrder.isEmpty())
@@ -326,5 +322,5 @@
 
         /* Chipset type: */
-        const KChipsetType enmChipsetType = machine.GetChipsetType();
+        const KChipsetType enmChipsetType = comMachine.GetChipsetType();
         if (enmChipsetType == KChipsetType_ICH9)
             table << UITextTableLine(QApplication::translate("UIDetails", "Chipset Type", "details (system)"),
@@ -332,5 +328,5 @@
 
         /* Firware type: */
-        switch (machine.GetFirmwareType())
+        switch (comMachine.GetFirmwareType())
         {
             case KFirmwareType_EFI:
@@ -356,15 +352,17 @@
         {
             /* VT-x/AMD-V: */
-            if (machine.GetHWVirtExProperty(KHWVirtExPropertyType_Enabled))
+            if (comMachine.GetHWVirtExProperty(KHWVirtExPropertyType_Enabled))
             {
                 acceleration << QApplication::translate("UIDetails", "VT-x/AMD-V", "details (system)");
                 /* Nested Paging (only when hw virt is enabled): */
-                if (machine.GetHWVirtExProperty(KHWVirtExPropertyType_NestedPaging))
+                if (comMachine.GetHWVirtExProperty(KHWVirtExPropertyType_NestedPaging))
                     acceleration << QApplication::translate("UIDetails", "Nested Paging", "details (system)");
             }
         }
-        if (machine.GetCPUProperty(KCPUPropertyType_PAE))
+        /* PAE/NX: */
+        if (comMachine.GetCPUProperty(KCPUPropertyType_PAE))
             acceleration << QApplication::translate("UIDetails", "PAE/NX", "details (system)");
-        switch (machine.GetEffectiveParavirtProvider())
+        /* Paravirtualization provider: */
+        switch (comMachine.GetEffectiveParavirtProvider())
         {
             case KParavirtProvider_Minimal: acceleration << QApplication::translate("UIDetails", "Minimal Paravirtualization", "details (system)"); break;
@@ -389,26 +387,26 @@
 {
     /* Acquire corresponding machine: */
-    CMachine machine = property("machine").value<CMachine>();
-    if (machine.isNull())
-        return;
-
-    /* Prepare table: */
-    UITextTable table;
-
-    /* Gather information: */
-    if (machine.GetAccessible())
+    CMachine comMachine = property("machine").value<CMachine>();
+    if (comMachine.isNull())
+        return;
+
+    /* Prepare table: */
+    UITextTable table;
+
+    /* Gather information: */
+    if (comMachine.GetAccessible())
     {
         /* Video memory: */
         table << UITextTableLine(QApplication::translate("UIDetails", "Video Memory", "details (display)"),
-                                 QApplication::translate("UIDetails", "%1 MB", "details").arg(machine.GetVRAMSize()));
+                                 QApplication::translate("UIDetails", "%1 MB", "details").arg(comMachine.GetVRAMSize()));
 
         /* Screen count: */
-        int cGuestScreens = machine.GetMonitorCount();
+        const int cGuestScreens = comMachine.GetMonitorCount();
         if (cGuestScreens > 1)
             table << UITextTableLine(QApplication::translate("UIDetails", "Screens", "details (display)"),
                                      QString::number(cGuestScreens));
 
-        /* Get scale-factor value: */
-        const QString strScaleFactor = machine.GetExtraData(UIExtraDataDefs::GUI_ScaleFactor);
+        /* Scale-factor: */
+        const QString strScaleFactor = comMachine.GetExtraData(UIExtraDataDefs::GUI_ScaleFactor);
         {
             /* Try to convert loaded data to double: */
@@ -424,12 +422,13 @@
         }
 
+        /* Acceleration: */
         QStringList acceleration;
 #ifdef VBOX_WITH_VIDEOHWACCEL
         /* 2D acceleration: */
-        if (machine.GetAccelerate2DVideoEnabled())
+        if (comMachine.GetAccelerate2DVideoEnabled())
             acceleration << QApplication::translate("UIDetails", "2D Video", "details (display)");
-#endif /* VBOX_WITH_VIDEOHWACCEL */
+#endif
         /* 3D acceleration: */
-        if (machine.GetAccelerate3DEnabled())
+        if (comMachine.GetAccelerate3DEnabled())
             acceleration << QApplication::translate("UIDetails", "3D", "details (display)");
         if (!acceleration.isEmpty())
@@ -437,11 +436,11 @@
                                      acceleration.join(", "));
 
-        /* VRDE info: */
-        CVRDEServer srv = machine.GetVRDEServer();
-        if (!srv.isNull())
-        {
-            if (srv.GetEnabled())
+        /* VRDE: */
+        const CVRDEServer comServer = comMachine.GetVRDEServer();
+        if (!comServer.isNull())
+        {
+            if (comServer.GetEnabled())
                 table << UITextTableLine(QApplication::translate("UIDetails", "Remote Desktop Server Port", "details (display/vrde)"),
-                                         srv.GetVRDEProperty("TCP/Ports"));
+                                         comServer.GetVRDEProperty("TCP/Ports"));
             else
                 table << UITextTableLine(QApplication::translate("UIDetails", "Remote Desktop Server", "details (display/vrde)"),
@@ -450,9 +449,9 @@
 
         /* Recording info: */
-        CRecordingSettings comRecordingSettings = machine.GetRecordingSettings();
+        CRecordingSettings comRecordingSettings = comMachine.GetRecordingSettings();
         if (comRecordingSettings.GetEnabled())
         {
             /* For now all screens have the same config: */
-            CRecordingScreenSettings comRecordingScreen0Settings = comRecordingSettings.GetScreenSettings(0);
+            const CRecordingScreenSettings comRecordingScreen0Settings = comRecordingSettings.GetScreenSettings(0);
 
             /** @todo r=andy Refine these texts (wrt audio and/or video). */
@@ -466,5 +465,4 @@
         else
         {
-            /** @todo r=andy Refine these texts (wrt audio and/or video). */
             table << UITextTableLine(QApplication::translate("UIDetails", "Recording", "details (display/recording)"),
                                      QApplication::translate("UIDetails", "Disabled", "details (display/recording)"));
@@ -482,53 +480,57 @@
 {
     /* Acquire corresponding machine: */
-    CMachine machine = property("machine").value<CMachine>();
-    if (machine.isNull())
-        return;
-
-    /* Prepare table: */
-    UITextTable table;
-
-    /* Gather information: */
-    if (machine.GetAccessible())
+    CMachine comMachine = property("machine").value<CMachine>();
+    if (comMachine.isNull())
+        return;
+
+    /* Prepare table: */
+    UITextTable table;
+
+    /* Gather information: */
+    if (comMachine.GetAccessible())
     {
         /* Iterate over all the machine controllers: */
-        bool fSomeInfo = false;
-        foreach (const CStorageController &controller, machine.GetStorageControllers())
+        foreach (const CStorageController &comController, comMachine.GetStorageControllers())
         {
             /* Add controller information: */
-            QString strControllerName = QApplication::translate("UIMachineSettingsStorage", "Controller: %1");
-            table << UITextTableLine(strControllerName.arg(controller.GetName()), QString());
-            fSomeInfo = true;
+            const QString strControllerName = QApplication::translate("UIMachineSettingsStorage", "Controller: %1");
+            table << UITextTableLine(strControllerName.arg(comController.GetName()), QString());
             /* Populate map (its sorted!): */
             QMap<StorageSlot, QString> attachmentsMap;
-            foreach (const CMediumAttachment &attachment, machine.GetMediumAttachmentsOfController(controller.GetName()))
+            foreach (const CMediumAttachment &attachment, comMachine.GetMediumAttachmentsOfController(comController.GetName()))
             {
+                /* Acquire device type first of all: */
+                const KDeviceType enmDeviceType = attachment.GetType();
+
                 /* Prepare current storage slot: */
-                StorageSlot attachmentSlot(controller.GetBus(), attachment.GetPort(), attachment.GetDevice());
-                AssertMsg(controller.isOk(),
+                const StorageSlot attachmentSlot(comController.GetBus(), attachment.GetPort(), attachment.GetDevice());
+                AssertMsg(comController.isOk(),
                           ("Unable to acquire controller data: %s\n",
-                           UIErrorString::formatRC(controller.lastRC()).toUtf8().constData()));
-                if (!controller.isOk())
+                           UIErrorString::formatRC(comController.lastRC()).toUtf8().constData()));
+                if (!comController.isOk())
                     continue;
+
                 /* Prepare attachment information: */
                 QString strAttachmentInfo = vboxGlobal().details(attachment.GetMedium(), false, false);
-                /* That temporary hack makes sure 'Inaccessible' word is always bold: */
+                /* That hack makes sure 'Inaccessible' word is always bold: */
                 { // hack
-                    QString strInaccessibleString(VBoxGlobal::tr("Inaccessible", "medium"));
-                    QString strBoldInaccessibleString(QString("<b>%1</b>").arg(strInaccessibleString));
+                    const QString strInaccessibleString(VBoxGlobal::tr("Inaccessible", "medium"));
+                    const QString strBoldInaccessibleString(QString("<b>%1</b>").arg(strInaccessibleString));
                     strAttachmentInfo.replace(strInaccessibleString, strBoldInaccessibleString);
                 } // hack
+
                 /* Append 'device slot name' with 'device type name' for optical devices only: */
-                KDeviceType deviceType = attachment.GetType();
-                QString strDeviceType = deviceType == KDeviceType_DVD ?
-                            QApplication::translate("UIDetails", "[Optical Drive]", "details (storage)") : QString();
+                QString strDeviceType = enmDeviceType == KDeviceType_DVD
+                                      ? QApplication::translate("UIDetails", "[Optical Drive]", "details (storage)")
+                                      : QString();
                 if (!strDeviceType.isNull())
                     strDeviceType.append(' ');
+
                 /* Insert that attachment information into the map: */
                 if (!strAttachmentInfo.isNull())
                 {
                     /* Configure hovering anchors: */
-                    const QString strAnchorType = deviceType == KDeviceType_DVD || deviceType == KDeviceType_Floppy ? QString("mount") :
-                                                  deviceType == KDeviceType_HardDisk ? QString("attach") : QString();
+                    const QString strAnchorType = enmDeviceType == KDeviceType_DVD || enmDeviceType == KDeviceType_Floppy ? QString("mount") :
+                                                  enmDeviceType == KDeviceType_HardDisk ? QString("attach") : QString();
                     const CMedium medium = attachment.GetMedium();
                     const QString strMediumLocation = medium.isNull() ? QString() : medium.GetLocation();
@@ -536,5 +538,5 @@
                                           QString("<a href=#%1,%2,%3,%4>%5</a>")
                                                   .arg(strAnchorType,
-                                                       controller.GetName(),
+                                                       comController.GetName(),
                                                        gpConverter->toString(attachmentSlot),
                                                        strMediumLocation,
@@ -542,11 +544,12 @@
                 }
             }
+
             /* Iterate over the sorted map: */
-            QList<StorageSlot> storageSlots = attachmentsMap.keys();
-            QList<QString> storageInfo = attachmentsMap.values();
+            const QList<StorageSlot> storageSlots = attachmentsMap.keys();
+            const QList<QString> storageInfo = attachmentsMap.values();
             for (int i = 0; i < storageSlots.size(); ++i)
                 table << UITextTableLine(QString("  ") + gpConverter->toString(storageSlots[i]), storageInfo[i]);
         }
-        if (!fSomeInfo)
+        if (table.isEmpty())
             table << UITextTableLine(QApplication::translate("UIDetails", "Not Attached", "details (storage)"), QString());
     }
@@ -562,35 +565,33 @@
 {
     /* Acquire corresponding machine: */
-    CMachine machine = property("machine").value<CMachine>();
-    if (machine.isNull())
-        return;
-
-    /* Prepare table: */
-    UITextTable table;
-
-    /* Gather information: */
-    if (machine.GetAccessible())
-    {
-        const CAudioAdapter &audio = machine.GetAudioAdapter();
-        if (audio.GetEnabled())
+    CMachine comMachine = property("machine").value<CMachine>();
+    if (comMachine.isNull())
+        return;
+
+    /* Prepare table: */
+    UITextTable table;
+
+    /* Gather information: */
+    if (comMachine.GetAccessible())
+    {
+        const CAudioAdapter comAudio = comMachine.GetAudioAdapter();
+        if (comAudio.GetEnabled())
         {
             /* Driver: */
             table << UITextTableLine(QApplication::translate("UIDetails", "Host Driver", "details (audio)"),
-                                     gpConverter->toString(audio.GetAudioDriver()));
+                                     gpConverter->toString(comAudio.GetAudioDriver()));
 
             /* Controller: */
             table << UITextTableLine(QApplication::translate("UIDetails", "Controller", "details (audio)"),
-                                     gpConverter->toString(audio.GetAudioController()));
+                                     gpConverter->toString(comAudio.GetAudioController()));
 
 #ifdef VBOX_WITH_AUDIO_INOUT_INFO
-            /* Output: */
+            /* I/O: */
             table << UITextTableLine(QApplication::translate("UIDetails", "Audio Output", "details (audio)"),
-                                     audio.GetEnabledOut() ?
+                                     comAudio.GetEnabledOut() ?
                                      QApplication::translate("UIDetails", "Enabled", "details (audio/output)") :
                                      QApplication::translate("UIDetails", "Disabled", "details (audio/output)"));
-
-            /* Input: */
             table << UITextTableLine(QApplication::translate("UIDetails", "Audio Input", "details (audio)"),
-                                     audio.GetEnabledIn() ?
+                                     comAudio.GetEnabledIn() ?
                                      QApplication::translate("UIDetails", "Enabled", "details (audio/input)") :
                                      QApplication::translate("UIDetails", "Disabled", "details (audio/input)"));
@@ -613,71 +614,74 @@
 {
     /* Acquire corresponding machine: */
-    CMachine machine = property("machine").value<CMachine>();
-    if (machine.isNull())
-        return;
-
-    /* Prepare table: */
-    UITextTable table;
-
-    /* Gather information: */
-    if (machine.GetAccessible())
+    CMachine comMachine = property("machine").value<CMachine>();
+    if (comMachine.isNull())
+        return;
+
+    /* Prepare table: */
+    UITextTable table;
+
+    /* Gather information: */
+    if (comMachine.GetAccessible())
     {
         /* Iterate over all the adapters: */
-        bool fSomeInfo = false;
-        ulong uCount = vboxGlobal().virtualBox().GetSystemProperties().GetMaxNetworkAdapters(machine.GetChipsetType());
+        const ulong uCount = vboxGlobal().virtualBox().GetSystemProperties().GetMaxNetworkAdapters(comMachine.GetChipsetType());
         for (ulong uSlot = 0; uSlot < uCount; ++uSlot)
         {
-            const CNetworkAdapter &adapter = machine.GetNetworkAdapter(uSlot);
-            if (adapter.GetEnabled())
+            const CNetworkAdapter comAdapter = comMachine.GetNetworkAdapter(uSlot);
+
+            /* Skip disabled adapters: */
+            if (!comAdapter.GetEnabled())
+                continue;
+
+            /* Gather adapter information: */
+            const KNetworkAttachmentType enmType = comAdapter.GetAttachmentType();
+            const QString strAttachmentTemplate = gpConverter->toString(comAdapter.GetAdapterType()).replace(QRegExp("\\s\\(.+\\)"), " (%1)");
+            QString strAttachmentType;
+            switch (enmType)
             {
-                KNetworkAttachmentType type = adapter.GetAttachmentType();
-                QString strAttachmentType = gpConverter->toString(adapter.GetAdapterType())
-                                            .replace(QRegExp("\\s\\(.+\\)"), " (%1)");
-                switch (type)
-                {
-                    case KNetworkAttachmentType_Bridged:
-                    {
-                        strAttachmentType = strAttachmentType.arg(QApplication::translate("UIDetails", "Bridged Adapter, %1", "details (network)")
-                                                                  .arg(adapter.GetBridgedInterface()));
-                        break;
-                    }
-                    case KNetworkAttachmentType_Internal:
-                    {
-                        strAttachmentType = strAttachmentType.arg(QApplication::translate("UIDetails", "Internal Network, '%1'", "details (network)")
-                                                                  .arg(adapter.GetInternalNetwork()));
-                        break;
-                    }
-                    case KNetworkAttachmentType_HostOnly:
-                    {
-                        strAttachmentType = strAttachmentType.arg(QApplication::translate("UIDetails", "Host-only Adapter, '%1'", "details (network)")
-                                                                  .arg(adapter.GetHostOnlyInterface()));
-                        break;
-                    }
-                    case KNetworkAttachmentType_Generic:
-                    {
-                        QString strGenericDriverProperties(summarizeGenericProperties(adapter));
-                        strAttachmentType = strGenericDriverProperties.isNull() ?
-                                  strAttachmentType.arg(QApplication::translate("UIDetails", "Generic Driver, '%1'", "details (network)").arg(adapter.GetGenericDriver())) :
-                                  strAttachmentType.arg(QApplication::translate("UIDetails", "Generic Driver, '%1' { %2 }", "details (network)")
-                                                        .arg(adapter.GetGenericDriver(), strGenericDriverProperties));
-                        break;
-                    }
-                    case KNetworkAttachmentType_NATNetwork:
-                    {
-                        strAttachmentType = strAttachmentType.arg(QApplication::translate("UIDetails", "NAT Network, '%1'", "details (network)")
-                                                                  .arg(adapter.GetNATNetwork()));
-                        break;
-                    }
-                    default:
-                    {
-                        strAttachmentType = strAttachmentType.arg(gpConverter->toString(type));
-                        break;
-                    }
-                }
-                table << UITextTableLine(QApplication::translate("UIDetails", "Adapter %1", "details (network)").arg(adapter.GetSlot() + 1), strAttachmentType);
-                fSomeInfo = true;
+                case KNetworkAttachmentType_Bridged:
+                {
+                    strAttachmentType = strAttachmentTemplate.arg(QApplication::translate("UIDetails", "Bridged Adapter, %1", "details (network)")
+                                                                  .arg(comAdapter.GetBridgedInterface()));
+                    break;
+                }
+                case KNetworkAttachmentType_Internal:
+                {
+                    strAttachmentType = strAttachmentTemplate.arg(QApplication::translate("UIDetails", "Internal Network, '%1'", "details (network)")
+                                                                  .arg(comAdapter.GetInternalNetwork()));
+                    break;
+                }
+                case KNetworkAttachmentType_HostOnly:
+                {
+                    strAttachmentType = strAttachmentTemplate.arg(QApplication::translate("UIDetails", "Host-only Adapter, '%1'", "details (network)")
+                                                                  .arg(comAdapter.GetHostOnlyInterface()));
+                    break;
+                }
+                case KNetworkAttachmentType_Generic:
+                {
+                    const QString strGenericDriverProperties(summarizeGenericProperties(comAdapter));
+                    strAttachmentType = strGenericDriverProperties.isNull() ?
+                        strAttachmentTemplate.arg(QApplication::translate("UIDetails", "Generic Driver, '%1'", "details (network)")
+                                                  .arg(comAdapter.GetGenericDriver())) :
+                        strAttachmentTemplate.arg(QApplication::translate("UIDetails", "Generic Driver, '%1' { %2 }", "details (network)")
+                                                  .arg(comAdapter.GetGenericDriver(), strGenericDriverProperties));
+                    break;
+                }
+                case KNetworkAttachmentType_NATNetwork:
+                {
+                    strAttachmentType = strAttachmentTemplate.arg(QApplication::translate("UIDetails", "NAT Network, '%1'", "details (network)")
+                                                                  .arg(comAdapter.GetNATNetwork()));
+                    break;
+                }
+                default:
+                {
+                    strAttachmentType = strAttachmentTemplate.arg(gpConverter->toString(enmType));
+                    break;
+                }
             }
-        }
-        if (!fSomeInfo)
+            if (!strAttachmentType.isNull())
+                table << UITextTableLine(QApplication::translate("UIDetails", "Adapter %1", "details (network)").arg(comAdapter.GetSlot() + 1), strAttachmentType);
+        }
+        if (table.isEmpty())
             table << UITextTableLine(QApplication::translate("UIDetails", "Disabled", "details (network/adapter)"), QString());
     }
@@ -709,34 +713,60 @@
 {
     /* Acquire corresponding machine: */
-    CMachine machine = property("machine").value<CMachine>();
-    if (machine.isNull())
-        return;
-
-    /* Prepare table: */
-    UITextTable table;
-
-    /* Gather information: */
-    if (machine.GetAccessible())
+    CMachine comMachine = property("machine").value<CMachine>();
+    if (comMachine.isNull())
+        return;
+
+    /* Prepare table: */
+    UITextTable table;
+
+    /* Gather information: */
+    if (comMachine.GetAccessible())
     {
         /* Iterate over all the ports: */
-        bool fSomeInfo = false;
-        ulong uCount = vboxGlobal().virtualBox().GetSystemProperties().GetSerialPortCount();
+        const ulong uCount = vboxGlobal().virtualBox().GetSystemProperties().GetSerialPortCount();
         for (ulong uSlot = 0; uSlot < uCount; ++uSlot)
         {
-            const CSerialPort &port = machine.GetSerialPort(uSlot);
-            if (port.GetEnabled())
+            const CSerialPort comPort = comMachine.GetSerialPort(uSlot);
+
+            /* Skip disabled adapters: */
+            if (!comPort.GetEnabled())
+                continue;
+
+            /* Gather port information: */
+            const KPortMode enmMode = comPort.GetHostMode();
+            const QString strModeTemplate = vboxGlobal().toCOMPortName(comPort.GetIRQ(), comPort.GetIOBase()) + ", ";
+            QString strModeType;
+            switch (enmMode)
             {
-                KPortMode mode = port.GetHostMode();
-                QString data = vboxGlobal().toCOMPortName(port.GetIRQ(), port.GetIOBase()) + ", ";
-                if (mode == KPortMode_HostPipe || mode == KPortMode_HostDevice ||
-                    mode == KPortMode_RawFile || mode == KPortMode_TCP)
-                    data += QString("%1 (%2)").arg(gpConverter->toString(mode)).arg(QDir::toNativeSeparators(port.GetPath()));
-                else
-                    data += gpConverter->toString(mode);
-                table << UITextTableLine(QApplication::translate("UIDetails", "Port %1", "details (serial)").arg(port.GetSlot() + 1), data);
-                fSomeInfo = true;
+                case KPortMode_HostPipe:
+                {
+                    strModeType = strModeTemplate + QString("%1 (%2)").arg(gpConverter->toString(enmMode)).arg(QDir::toNativeSeparators(comPort.GetPath()));
+                    break;
+                }
+                case KPortMode_HostDevice:
+                {
+                    strModeType = strModeTemplate + QString("%1 (%2)").arg(gpConverter->toString(enmMode)).arg(QDir::toNativeSeparators(comPort.GetPath()));
+                    break;
+                }
+                case KPortMode_RawFile:
+                {
+                    strModeType = strModeTemplate + QString("%1 (%2)").arg(gpConverter->toString(enmMode)).arg(QDir::toNativeSeparators(comPort.GetPath()));
+                    break;
+                }
+                case KPortMode_TCP:
+                {
+                    strModeType = strModeTemplate + QString("%1 (%2)").arg(gpConverter->toString(enmMode)).arg(QDir::toNativeSeparators(comPort.GetPath()));
+                    break;
+                }
+                default:
+                {
+                    strModeType = strModeTemplate + gpConverter->toString(enmMode);
+                    break;
+                }
             }
-        }
-        if (!fSomeInfo)
+            if (!strModeType.isNull())
+                table << UITextTableLine(QApplication::translate("UIDetails", "Port %1", "details (serial)").arg(comPort.GetSlot() + 1), strModeType);
+        }
+        if (table.isEmpty())
             table << UITextTableLine(QApplication::translate("UIDetails", "Disabled", "details (serial)"), QString());
     }
@@ -752,36 +782,36 @@
 {
     /* Acquire corresponding machine: */
-    CMachine machine = property("machine").value<CMachine>();
-    if (machine.isNull())
-        return;
-
-    /* Prepare table: */
-    UITextTable table;
-
-    /* Gather information: */
-    if (machine.GetAccessible())
+    CMachine comMachine = property("machine").value<CMachine>();
+    if (comMachine.isNull())
+        return;
+
+    /* Prepare table: */
+    UITextTable table;
+
+    /* Gather information: */
+    if (comMachine.GetAccessible())
     {
         /* Iterate over all the USB filters: */
-        const CUSBDeviceFilters &filters = machine.GetUSBDeviceFilters();
-        if (!filters.isNull() && machine.GetUSBProxyAvailable())
-        {
-            const CUSBDeviceFilters flts = machine.GetUSBDeviceFilters();
-            const CUSBControllerVector controllers = machine.GetUSBControllers();
-            if (!flts.isNull() && !controllers.isEmpty())
+        const CUSBDeviceFilters comFilterObject = comMachine.GetUSBDeviceFilters();
+        if (!comFilterObject.isNull() && comMachine.GetUSBProxyAvailable())
+        {
+            const CUSBControllerVector controllers = comMachine.GetUSBControllers();
+            if (!controllers.isEmpty())
             {
-                /* USB Controllers info: */
-                QStringList controllerList;
-                foreach (const CUSBController &controller, controllers)
-                    controllerList << gpConverter->toString(controller.GetType());
+                /* Controllers: */
+                QStringList controllersReadable;
+                foreach (const CUSBController &comController, controllers)
+                    controllersReadable << gpConverter->toString(comController.GetType());
                 table << UITextTableLine(QApplication::translate("UIDetails", "USB Controller", "details (usb)"),
-                                          controllerList.join(", "));
-                /* USB Device Filters info: */
-                const CUSBDeviceFilterVector &coll = flts.GetDeviceFilters();
+                                         controllersReadable.join(", "));
+
+                /* Device Filters: */
+                const CUSBDeviceFilterVector filters = comFilterObject.GetDeviceFilters();
                 uint uActive = 0;
-                for (int i = 0; i < coll.size(); ++i)
-                    if (coll[i].GetActive())
+                for (int i = 0; i < filters.size(); ++i)
+                    if (filters.at(i).GetActive())
                         ++uActive;
                 table << UITextTableLine(QApplication::translate("UIDetails", "Device Filters", "details (usb)"),
-                                         QApplication::translate("UIDetails", "%1 (%2 active)", "details (usb)").arg(coll.size()).arg(uActive));
+                                         QApplication::translate("UIDetails", "%1 (%2 active)", "details (usb)").arg(filters.size()).arg(uActive));
             }
             else
@@ -802,16 +832,16 @@
 {
     /* Acquire corresponding machine: */
-    CMachine machine = property("machine").value<CMachine>();
-    if (machine.isNull())
-        return;
-
-    /* Prepare table: */
-    UITextTable table;
-
-    /* Gather information: */
-    if (machine.GetAccessible())
-    {
-        /* Iterate over all the shared folders: */
-        ulong uCount = machine.GetSharedFolders().size();
+    CMachine comMachine = property("machine").value<CMachine>();
+    if (comMachine.isNull())
+        return;
+
+    /* Prepare table: */
+    UITextTable table;
+
+    /* Gather information: */
+    if (comMachine.GetAccessible())
+    {
+        /* Summary: */
+        const ulong uCount = comMachine.GetSharedFolders().size();
         if (uCount > 0)
             table << UITextTableLine(QApplication::translate("UIDetails", "Shared Folders", "details (shared folders)"), QString::number(uCount));
@@ -830,58 +860,58 @@
 {
     /* Acquire corresponding machine: */
-    CMachine machine = property("machine").value<CMachine>();
-    if (machine.isNull())
-        return;
-
-    /* Prepare table: */
-    UITextTable table;
-
-    /* Gather information: */
-    if (machine.GetAccessible())
+    CMachine comMachine = property("machine").value<CMachine>();
+    if (comMachine.isNull())
+        return;
+
+    /* Prepare table: */
+    UITextTable table;
+
+    /* Gather information: */
+    if (comMachine.GetAccessible())
     {
 #ifndef VBOX_WS_MAC
-        /* Get menu-bar availability status: */
-        const QString strMenubarEnabled = machine.GetExtraData(UIExtraDataDefs::GUI_MenuBar_Enabled);
+        /* Menu-bar: */
+        const QString strMenubarEnabled = comMachine.GetExtraData(UIExtraDataDefs::GUI_MenuBar_Enabled);
         {
             /* Try to convert loaded data to bool: */
-            const bool fEnabled = !(strMenubarEnabled.compare("false", Qt::CaseInsensitive) == 0 ||
-                                    strMenubarEnabled.compare("no", Qt::CaseInsensitive) == 0 ||
-                                    strMenubarEnabled.compare("off", Qt::CaseInsensitive) == 0 ||
-                                    strMenubarEnabled == "0");
+            const bool fEnabled = !(   strMenubarEnabled.compare("false", Qt::CaseInsensitive) == 0
+                                    || strMenubarEnabled.compare("no", Qt::CaseInsensitive) == 0
+                                    || strMenubarEnabled.compare("off", Qt::CaseInsensitive) == 0
+                                    || strMenubarEnabled == "0");
             /* Append information: */
             table << UITextTableLine(QApplication::translate("UIDetails", "Menu-bar", "details (user interface)"),
-                                     fEnabled ? QApplication::translate("UIDetails", "Enabled", "details (user interface/menu-bar)") :
-                                                QApplication::translate("UIDetails", "Disabled", "details (user interface/menu-bar)"));
+                                     fEnabled ? QApplication::translate("UIDetails", "Enabled", "details (user interface/menu-bar)")
+                                              : QApplication::translate("UIDetails", "Disabled", "details (user interface/menu-bar)"));
         }
 #endif /* !VBOX_WS_MAC */
 
-        /* Get status-bar availability status: */
-        const QString strStatusbarEnabled = machine.GetExtraData(UIExtraDataDefs::GUI_StatusBar_Enabled);
+        /* Status-bar: */
+        const QString strStatusbarEnabled = comMachine.GetExtraData(UIExtraDataDefs::GUI_StatusBar_Enabled);
         {
             /* Try to convert loaded data to bool: */
-            const bool fEnabled = !(strStatusbarEnabled.compare("false", Qt::CaseInsensitive) == 0 ||
-                                    strStatusbarEnabled.compare("no", Qt::CaseInsensitive) == 0 ||
-                                    strStatusbarEnabled.compare("off", Qt::CaseInsensitive) == 0 ||
-                                    strStatusbarEnabled == "0");
+            const bool fEnabled = !(   strStatusbarEnabled.compare("false", Qt::CaseInsensitive) == 0
+                                    || strStatusbarEnabled.compare("no", Qt::CaseInsensitive) == 0
+                                    || strStatusbarEnabled.compare("off", Qt::CaseInsensitive) == 0
+                                    || strStatusbarEnabled == "0");
             /* Append information: */
             table << UITextTableLine(QApplication::translate("UIDetails", "Status-bar", "details (user interface)"),
-                                     fEnabled ? QApplication::translate("UIDetails", "Enabled", "details (user interface/status-bar)") :
-                                                QApplication::translate("UIDetails", "Disabled", "details (user interface/status-bar)"));
+                                     fEnabled ? QApplication::translate("UIDetails", "Enabled", "details (user interface/status-bar)")
+                                              : QApplication::translate("UIDetails", "Disabled", "details (user interface/status-bar)"));
         }
 
 #ifndef VBOX_WS_MAC
-        /* Get mini-toolbar availability status: */
-        const QString strMiniToolbarEnabled = machine.GetExtraData(UIExtraDataDefs::GUI_ShowMiniToolBar);
+        /* Mini-toolbar: */
+        const QString strMiniToolbarEnabled = comMachine.GetExtraData(UIExtraDataDefs::GUI_ShowMiniToolBar);
         {
             /* Try to convert loaded data to bool: */
-            const bool fEnabled = !(strMiniToolbarEnabled.compare("false", Qt::CaseInsensitive) == 0 ||
-                                    strMiniToolbarEnabled.compare("no", Qt::CaseInsensitive) == 0 ||
-                                    strMiniToolbarEnabled.compare("off", Qt::CaseInsensitive) == 0 ||
-                                    strMiniToolbarEnabled == "0");
+            const bool fEnabled = !(   strMiniToolbarEnabled.compare("false", Qt::CaseInsensitive) == 0
+                                    || strMiniToolbarEnabled.compare("no", Qt::CaseInsensitive) == 0
+                                    || strMiniToolbarEnabled.compare("off", Qt::CaseInsensitive) == 0
+                                    || strMiniToolbarEnabled == "0");
             /* Append information: */
             if (fEnabled)
             {
                 /* Get mini-toolbar position: */
-                const QString &strMiniToolbarPosition = machine.GetExtraData(UIExtraDataDefs::GUI_MiniToolBarAlignment);
+                const QString strMiniToolbarPosition = comMachine.GetExtraData(UIExtraDataDefs::GUI_MiniToolBarAlignment);
                 {
                     /* Try to convert loaded data to alignment: */
@@ -929,8 +959,8 @@
     if (machine.GetAccessible())
     {
-        /* Get description: */
-        const QString &strDesc = machine.GetDescription();
-        if (!strDesc.isEmpty())
-            table << UITextTableLine(strDesc, QString());
+        /* Summary: */
+        const QString strDescription = machine.GetDescription();
+        if (!strDescription.isEmpty())
+            table << UITextTableLine(strDescription, QString());
         else
             table << UITextTableLine(QApplication::translate("UIDetails", "None", "details (description)"), QString());
Index: /trunk/src/VBox/Frontends/VirtualBox/src/manager/details/UIDetailsElements.h
===================================================================
--- /trunk/src/VBox/Frontends/VirtualBox/src/manager/details/UIDetailsElements.h	(revision 75425)
+++ /trunk/src/VBox/Frontends/VirtualBox/src/manager/details/UIDetailsElements.h	(revision 75426)
@@ -5,5 +5,5 @@
 
 /*
- * Copyright (C) 2012-2017 Oracle Corporation
+ * Copyright (C) 2012-2018 Oracle Corporation
  *
  * This file is part of VirtualBox Open Source Edition (OSE), as
@@ -35,6 +35,6 @@
 public:
 
-    /** Constructs update task taking @a machine as data. */
-    UIDetailsUpdateTask(const CMachine &machine);
+    /** Constructs update task taking @a comMachine as data. */
+    UIDetailsUpdateTask(const CMachine &comMachine);
 };
 
@@ -61,5 +61,5 @@
 
     /** Creates update task. */
-    virtual UITask* createUpdateTask() = 0;
+    virtual UITask *createUpdateTask() = 0;
 
 private slots:
@@ -120,7 +120,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskGeneral(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskGeneral(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -145,5 +145,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskGeneral(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskGeneral(machine()); }
 };
 
@@ -156,7 +156,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskSystem(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskSystem(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -181,5 +181,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskSystem(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskSystem(machine()); }
 };
 
@@ -192,7 +192,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskDisplay(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskDisplay(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -217,5 +217,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskDisplay(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskDisplay(machine()); }
 };
 
@@ -228,7 +228,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskStorage(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskStorage(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -253,5 +253,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskStorage(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskStorage(machine()); }
 };
 
@@ -264,7 +264,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskAudio(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskAudio(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -289,5 +289,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskAudio(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskAudio(machine()); }
 };
 
@@ -300,7 +300,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskNetwork(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskNetwork(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -328,5 +328,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskNetwork(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskNetwork(machine()); }
 };
 
@@ -339,7 +339,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskSerial(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskSerial(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -364,5 +364,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskSerial(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskSerial(machine()); }
 };
 
@@ -375,7 +375,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskUSB(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskUSB(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -400,5 +400,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskUSB(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskUSB(machine()); }
 };
 
@@ -411,7 +411,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskSF(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskSF(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -436,5 +436,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskSF(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskSF(machine()); }
 };
 
@@ -447,7 +447,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskUI(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskUI(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -472,5 +472,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskUI(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskUI(machine()); }
 };
 
@@ -483,7 +483,7 @@
 public:
 
-    /** Constructs update task passing @a machine to the base-class. */
-    UIDetailsUpdateTaskDescription(const CMachine &machine)
-        : UIDetailsUpdateTask(machine) {}
+    /** Constructs update task passing @a comMachine to the base-class. */
+    UIDetailsUpdateTaskDescription(const CMachine &comMachine)
+        : UIDetailsUpdateTask(comMachine) {}
 
 private:
@@ -508,5 +508,5 @@
 
     /** Creates update task for this element. */
-    UITask* createUpdateTask() { return new UIDetailsUpdateTaskDescription(machine()); }
+    UITask *createUpdateTask() { return new UIDetailsUpdateTaskDescription(machine()); }
 };
 
