Changeset 75615 in vbox for trunk/src/VBox/Frontends
- Timestamp:
- Nov 20, 2018 11:51:33 AM (6 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/converter/UIConverterBackendGlobal.cpp
r75427 r75615 1183 1183 switch (enmDetailsElementOptionTypeSharedFolders) 1184 1184 { 1185 case UIExtraDataMetaDefs::DetailsElementOptionTypeSharedFolders_Summary: strResult = "Summary"; break;1186 1185 default: 1187 1186 { … … 1199 1198 * to search through the keys using 'case-insensitive' rule: */ 1200 1199 QStringList keys; QList<UIExtraDataMetaDefs::DetailsElementOptionTypeSharedFolders> values; 1201 keys << "Summary"; values << UIExtraDataMetaDefs::DetailsElementOptionTypeSharedFolders_Summary;1202 1200 /* Invalid type for unknown words: */ 1203 1201 if (!keys.contains(strDetailsElementOptionTypeSharedFolders, Qt::CaseInsensitive)) … … 1247 1245 switch (enmDetailsElementOptionTypeDescription) 1248 1246 { 1249 case UIExtraDataMetaDefs::DetailsElementOptionTypeDescription_Summary: strResult = "Summary"; break;1250 1247 default: 1251 1248 { … … 1263 1260 * to search through the keys using 'case-insensitive' rule: */ 1264 1261 QStringList keys; QList<UIExtraDataMetaDefs::DetailsElementOptionTypeDescription> values; 1265 keys << "Summary"; values << UIExtraDataMetaDefs::DetailsElementOptionTypeDescription_Summary;1266 1262 /* Invalid type for unknown words: */ 1267 1263 if (!keys.contains(strDetailsElementOptionTypeDescription, Qt::CaseInsensitive)) -
trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataDefs.h
r75521 r75615 710 710 { 711 711 DetailsElementOptionTypeSharedFolders_Invalid = 0, 712 DetailsElementOptionTypeSharedFolders_Summary = RT_BIT(0),713 712 DetailsElementOptionTypeSharedFolders_Default = 0xFFFF 714 713 }; … … 730 729 { 731 730 DetailsElementOptionTypeDescription_Invalid = 0, 732 DetailsElementOptionTypeDescription_Summary = RT_BIT(0),733 731 DetailsElementOptionTypeDescription_Default = 0xFFFF 734 732 }; -
trunk/src/VBox/Frontends/VirtualBox/src/manager/details/UIDetailsElements.cpp
r75530 r75615 957 957 { 958 958 /* Summary: */ 959 if (m_fOptions & UIExtraDataMetaDefs::DetailsElementOptionTypeSharedFolders_Summary) 960 { 961 const ulong uCount = comMachine.GetSharedFolders().size(); 962 if (uCount > 0) 963 table << UITextTableLine(QApplication::translate("UIDetails", "Shared Folders", "details (shared folders)"), QString::number(uCount)); 964 else 965 table << UITextTableLine(QApplication::translate("UIDetails", "None", "details (shared folders)"), QString()); 966 } 959 const ulong uCount = comMachine.GetSharedFolders().size(); 960 if (uCount > 0) 961 table << UITextTableLine(QApplication::translate("UIDetails", "Shared Folders", "details (shared folders)"), QString::number(uCount)); 962 else 963 table << UITextTableLine(QApplication::translate("UIDetails", "None", "details (shared folders)"), QString()); 967 964 } 968 965 else … … 1079 1076 { 1080 1077 /* Acquire corresponding machine: */ 1081 CMachine machine = property("machine").value<CMachine>();1082 if ( machine.isNull())1078 CMachine comMachine = property("machine").value<CMachine>(); 1079 if (comMachine.isNull()) 1083 1080 return; 1084 1081 … … 1087 1084 1088 1085 /* Gather information: */ 1089 if ( machine.GetAccessible())1086 if (comMachine.GetAccessible()) 1090 1087 { 1091 1088 /* Summary: */ 1092 if (m_fOptions & UIExtraDataMetaDefs::DetailsElementOptionTypeDescription_Summary) 1093 { 1094 const QString strDescription = machine.GetDescription(); 1095 if (!strDescription.isEmpty()) 1096 table << UITextTableLine(strDescription, QString()); 1097 else 1098 table << UITextTableLine(QApplication::translate("UIDetails", "None", "details (description)"), QString()); 1099 } 1089 const QString strDescription = comMachine.GetDescription(); 1090 if (!strDescription.isEmpty()) 1091 table << UITextTableLine(strDescription, QString()); 1092 else 1093 table << UITextTableLine(QApplication::translate("UIDetails", "None", "details (description)"), QString()); 1100 1094 } 1101 1095 else
Note:
See TracChangeset
for help on using the changeset viewer.