Changeset 47137 in vbox for trunk/src/VBox
- Timestamp:
- Jul 14, 2013 5:27:50 PM (11 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/settings/global
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/settings/global/UIGlobalSettingsLanguage.cpp
r47136 r47137 170 170 /* Language page constructor: */ 171 171 UIGlobalSettingsLanguage::UIGlobalSettingsLanguage() 172 : m_fIsLanguageChanged(false) 172 : m_fPolished(false) 173 , m_fIsLanguageChanged(false) 173 174 { 174 175 /* Apply UI decorations: */ … … 180 181 m_pLanguageTree->hideColumn(2); 181 182 m_pLanguageTree->hideColumn(3); 183 m_pLanguageTree->setMinimumHeight(150); 182 184 m_pLanguageInfo->setWordWrapMode(QTextOption::WordWrap); 185 m_pLanguageInfo->setMinimumHeight(QFontMetrics(m_pLanguageInfo->font(), m_pLanguageInfo).height() * 5); 183 186 184 187 /* Setup connections: */ … … 212 215 /* Fetch from cache: */ 213 216 reload(m_cache.m_strLanguageId); 214 215 /* Remember current info-label width: */216 m_pLanguageInfo->setMinimumTextWidth(m_pLanguageInfo->width());217 217 } 218 218 … … 256 256 /* Reload language tree: */ 257 257 reload(VBoxGlobal::languageId()); 258 } 259 260 void UIGlobalSettingsLanguage::showEvent(QShowEvent *pEvent) 261 { 262 /* Call to base-class: */ 263 UISettingsPageGlobal::showEvent(pEvent); 264 265 /* Polishing border: */ 266 if (m_fPolished) 267 return; 268 m_fPolished = true; 269 270 /* Call for polish event: */ 271 polishEvent(pEvent); 272 } 273 274 void UIGlobalSettingsLanguage::polishEvent(QShowEvent*) 275 { 276 /* Remember current info-label width: */ 277 m_pLanguageInfo->setMinimumTextWidth(m_pLanguageInfo->width()); 258 278 } 259 279 -
trunk/src/VBox/Frontends/VirtualBox/src/settings/global/UIGlobalSettingsLanguage.h
r47136 r47137 62 62 void retranslateUi(); 63 63 64 /* Handlers: Event stuff: */ 65 void showEvent(QShowEvent *pEvent); 66 void polishEvent(QShowEvent *pEvent); 67 64 68 private slots: 65 69 … … 76 80 77 81 /* Variables: */ 82 bool m_fPolished; 78 83 bool m_fIsLanguageChanged; 79 84
Note:
See TracChangeset
for help on using the changeset viewer.