Changeset 105313 in vbox for trunk/src/VBox/Frontends/VirtualBox
- Timestamp:
- Jul 12, 2024 4:48:27 PM (9 months ago)
- svn:sync-xref-src-repo-rev:
- 163966
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/runtime/UIIndicatorsPool.cpp
r105312 r105313 31 31 #include <QHBoxLayout> 32 32 #include <QPainter> 33 #include <QRegularExpression> 33 34 #include <QStyle> 34 35 #include <QTimer> … … 1044 1045 virtual void updateAppearance() RT_OVERRIDE 1045 1046 { 1046 QString strFullData;1047 m_strFullData.clear(); 1047 1048 KVMExecutionEngine enmEngine = KVMExecutionEngine_NotSet; 1048 m_pMachine->acquireFeaturesStatusInfo( strFullData, enmEngine);1049 m_pMachine->acquireFeaturesStatusInfo(m_strFullData, enmEngine); 1049 1050 1050 1051 /* Update tool-tip: */ 1051 if (! strFullData.isEmpty())1052 setToolTip(s_strTable.arg( strFullData));1052 if (!m_strFullData.isEmpty()) 1053 setToolTip(s_strTable.arg(m_strFullData)); 1053 1054 /* Update indicator state: */ 1054 1055 setState(enmEngine); … … 1065 1066 } 1066 1067 1068 /** Handles translation event. */ 1069 virtual void sltRetranslateUI() RT_OVERRIDE 1070 { 1071 /* Call to base-class: */ 1072 UISessionStateStatusBarIndicator::sltRetranslateUI(); 1073 1074 /* Append description with more info: */ 1075 QString strFullData = m_strFullData; 1076 strFullData.remove(QRegularExpression("<tr>|<td>|<nobr>")); 1077 strFullData.replace("</nobr></td></tr>", ", "); 1078 strFullData.replace("</nobr></td>", " "); 1079 m_strDescription = QString("%1, %2").arg(m_strDescription, strFullData); 1080 } 1081 1067 1082 private slots: 1068 1083 … … 1081 1096 /** Holds the effective CPU load. Expected to be in range [0, 100] */ 1082 1097 ulong m_uEffectiveCPULoad; 1098 1099 /** Holds the serialized tool-tip data. */ 1100 QString m_strFullData; 1083 1101 }; 1084 1102
Note:
See TracChangeset
for help on using the changeset viewer.