Changeset 75424 in vbox
- Timestamp:
- Nov 13, 2018 4:05:13 PM (6 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox
- Files:
-
- 14 edited
- 10 moved
-
Makefile.kmk (modified) (4 diffs)
-
VirtualBox1.qrc (modified) (1 diff)
-
VirtualBox1_x2.qrc (modified) (1 diff)
-
VirtualBox1_x3.qrc (modified) (1 diff)
-
VirtualBox1_x4.qrc (modified) (1 diff)
-
images/log_viewer_options_32px.png (moved) (moved from trunk/src/VBox/Frontends/VirtualBox/images/log_viewer_settings_32px.png )
-
images/log_viewer_options_disabled_32px.png (moved) (moved from trunk/src/VBox/Frontends/VirtualBox/images/log_viewer_settings_disabled_32px.png )
-
images/x2/log_viewer_options_32px_x2.png (moved) (moved from trunk/src/VBox/Frontends/VirtualBox/images/x2/log_viewer_settings_32px_x2.png )
-
images/x2/log_viewer_options_disabled_32px_x2.png (moved) (moved from trunk/src/VBox/Frontends/VirtualBox/images/x2/log_viewer_settings_disabled_32px_x2.png )
-
images/x3/log_viewer_options_32px_x3.png (moved) (moved from trunk/src/VBox/Frontends/VirtualBox/images/x3/log_viewer_settings_32px_x3.png )
-
images/x3/log_viewer_options_disabled_32px_x3.png (moved) (moved from trunk/src/VBox/Frontends/VirtualBox/images/x3/log_viewer_settings_disabled_32px_x3.png )
-
images/x4/log_viewer_options_32px_x4.png (moved) (moved from trunk/src/VBox/Frontends/VirtualBox/images/x4/log_viewer_settings_32px_x4.png )
-
images/x4/log_viewer_options_disabled_32px_x4.png (moved) (moved from trunk/src/VBox/Frontends/VirtualBox/images/x4/log_viewer_settings_disabled_32px_x4.png )
-
src/extradata/UIExtraDataDefs.cpp (modified) (1 diff)
-
src/extradata/UIExtraDataDefs.h (modified) (1 diff)
-
src/extradata/UIExtraDataManager.cpp (modified) (4 diffs)
-
src/extradata/UIExtraDataManager.h (modified) (1 diff)
-
src/globals/UIActionPool.cpp (modified) (4 diffs)
-
src/globals/UIActionPool.h (modified) (1 diff)
-
src/logviewer/UIVMLogViewerOptionsPanel.cpp (moved) (moved from trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerSettingsPanel.cpp ) (8 diffs)
-
src/logviewer/UIVMLogViewerOptionsPanel.h (moved) (moved from trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerSettingsPanel.h ) (4 diffs)
-
src/logviewer/UIVMLogViewerWidget.cpp (modified) (12 diffs)
-
src/logviewer/UIVMLogViewerWidget.h (modified) (6 diffs)
-
src/manager/UIVirtualBoxManagerWidget.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/Makefile.kmk
r75369 r75424 809 809 src/logviewer/UIVMLogViewerDialog.h \ 810 810 src/logviewer/UIVMLogViewerFilterPanel.h \ 811 src/logviewer/UIVMLogViewerOptionsPanel.h \ 811 812 src/logviewer/UIVMLogViewerPanel.h \ 812 813 src/logviewer/UIVMLogViewerSearchPanel.h \ 813 src/logviewer/UIVMLogViewerSettingsPanel.h \814 814 src/logviewer/UIVMLogViewerTextEdit.h \ 815 815 src/logviewer/UIVMLogViewerWidget.h \ … … 1100 1100 src/logviewer/UIVMLogViewerDialog.h \ 1101 1101 src/logviewer/UIVMLogViewerFilterPanel.h \ 1102 src/logviewer/UIVMLogViewerOptionsPanel.h \ 1102 1103 src/logviewer/UIVMLogViewerPanel.h \ 1103 1104 src/logviewer/UIVMLogViewerSearchPanel.h \ 1104 src/logviewer/UIVMLogViewerSettingsPanel.h \1105 1105 src/logviewer/UIVMLogViewerTextEdit.h \ 1106 1106 src/logviewer/UIVMLogViewerWidget.h \ … … 1521 1521 src/logviewer/UIVMLogViewerDialog.cpp \ 1522 1522 src/logviewer/UIVMLogViewerFilterPanel.cpp \ 1523 src/logviewer/UIVMLogViewerOptionsPanel.cpp \ 1523 1524 src/logviewer/UIVMLogViewerPanel.cpp \ 1524 1525 src/logviewer/UIVMLogViewerSearchPanel.cpp \ 1525 src/logviewer/UIVMLogViewerSettingsPanel.cpp \1526 1526 src/logviewer/UIVMLogViewerTextEdit.cpp \ 1527 1527 src/logviewer/UIVMLogViewerWidget.cpp \ … … 1864 1864 src/logviewer/UIVMLogViewerDialog.cpp \ 1865 1865 src/logviewer/UIVMLogViewerFilterPanel.cpp \ 1866 src/logviewer/UIVMLogViewerOptionsPanel.cpp \ 1866 1867 src/logviewer/UIVMLogViewerPanel.cpp \ 1867 1868 src/logviewer/UIVMLogViewerSearchPanel.cpp \ 1868 src/logviewer/UIVMLogViewerSettingsPanel.cpp \1869 1869 src/logviewer/UIVMLogViewerTextEdit.cpp \ 1870 1870 src/logviewer/UIVMLogViewerWidget.cpp \ -
trunk/src/VBox/Frontends/VirtualBox/VirtualBox1.qrc
r75311 r75424 372 372 <file alias="log_viewer_search_backward_16px.png">images/log_viewer_search_backward_16px.png</file> 373 373 <file alias="log_viewer_search_forward_16px.png">images/log_viewer_search_forward_16px.png</file> 374 <file alias="log_viewer_ settings_32px.png">images/log_viewer_settings_32px.png</file>375 <file alias="log_viewer_ settings_disabled_32px.png">images/log_viewer_settings_disabled_32px.png</file>374 <file alias="log_viewer_options_32px.png">images/log_viewer_options_32px.png</file> 375 <file alias="log_viewer_options_disabled_32px.png">images/log_viewer_options_disabled_32px.png</file> 376 376 <file alias="machine_16px.png">images/machine_16px.png</file> 377 377 <file alias="machine_24px.png">images/machine_24px.png</file> -
trunk/src/VBox/Frontends/VirtualBox/VirtualBox1_x2.qrc
r75310 r75424 368 368 <file alias="log_viewer_search_backward_16px_x2.png">images/x2/log_viewer_search_backward_16px_x2.png</file> 369 369 <file alias="log_viewer_search_forward_16px_x2.png">images/x2/log_viewer_search_forward_16px_x2.png</file> 370 <file alias="log_viewer_ settings_32px_x2.png">images/x2/log_viewer_settings_32px_x2.png</file>371 <file alias="log_viewer_ settings_disabled_32px_x2.png">images/x2/log_viewer_settings_disabled_32px_x2.png</file>370 <file alias="log_viewer_options_32px_x2.png">images/x2/log_viewer_options_32px_x2.png</file> 371 <file alias="log_viewer_options_disabled_32px_x2.png">images/x2/log_viewer_options_disabled_32px_x2.png</file> 372 372 <file alias="machine_16px_x2.png">images/x2/machine_16px_x2.png</file> 373 373 <file alias="machine_24px_x2.png">images/x2/machine_24px_x2.png</file> -
trunk/src/VBox/Frontends/VirtualBox/VirtualBox1_x3.qrc
r74807 r75424 251 251 <file alias="log_viewer_search_backward_16px_x3.png">images/x3/log_viewer_search_backward_16px_x3.png</file> 252 252 <file alias="log_viewer_search_forward_16px_x3.png">images/x3/log_viewer_search_forward_16px_x3.png</file> 253 <file alias="log_viewer_ settings_32px_x3.png">images/x3/log_viewer_settings_32px_x3.png</file>254 <file alias="log_viewer_ settings_disabled_32px_x3.png">images/x3/log_viewer_settings_disabled_32px_x3.png</file>253 <file alias="log_viewer_options_32px_x3.png">images/x3/log_viewer_options_32px_x3.png</file> 254 <file alias="log_viewer_options_disabled_32px_x3.png">images/x3/log_viewer_options_disabled_32px_x3.png</file> 255 255 <file alias="machine_16px_x3.png">images/x3/machine_16px_x3.png</file> 256 256 <file alias="machine_24px_x3.png">images/x3/machine_24px_x3.png</file> -
trunk/src/VBox/Frontends/VirtualBox/VirtualBox1_x4.qrc
r74807 r75424 251 251 <file alias="log_viewer_search_backward_16px_x4.png">images/x4/log_viewer_search_backward_16px_x4.png</file> 252 252 <file alias="log_viewer_search_forward_16px_x4.png">images/x4/log_viewer_search_forward_16px_x4.png</file> 253 <file alias="log_viewer_ settings_32px_x4.png">images/x4/log_viewer_settings_32px_x4.png</file>254 <file alias="log_viewer_ settings_disabled_32px_x4.png">images/x4/log_viewer_settings_disabled_32px_x4.png</file>253 <file alias="log_viewer_options_32px_x4.png">images/x4/log_viewer_options_32px_x4.png</file> 254 <file alias="log_viewer_options_disabled_32px_x4.png">images/x4/log_viewer_options_disabled_32px_x4.png</file> 255 255 <file alias="machine_16px_x4.png">images/x4/machine_16px_x4.png</file> 256 256 <file alias="machine_24px_x4.png">images/x4/machine_24px_x4.png</file> -
trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataDefs.cpp
r75306 r75424 218 218 /* Virtual Machine: Log-viewer: */ 219 219 const char *UIExtraDataDefs::GUI_LogWindowGeometry = "GUI/LogWindowGeometry"; 220 const char *UIExtraDataDefs::GUI_LogViewer Settings = "GUI/LogViewerSettings";220 const char *UIExtraDataDefs::GUI_LogViewerOptions = "GUI/LogViewerOptions"; 221 221 const char *UIExtraDataDefs::GUI_LogViewerWrapLinesEnabled = "WrapLines"; 222 222 const char *UIExtraDataDefs::GUI_LogViewerShowLineNumbersDisabled = "showLineNumbersDisabled"; -
trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataDefs.h
r75360 r75424 392 392 SHARED_LIBRARY_STUFF extern const char *GUI_LogWindowGeometry; 393 393 /** @} */ 394 /** @name Virtual Machine: Log-viewer widget settings395 * @{ */ 396 SHARED_LIBRARY_STUFF extern const char *GUI_LogViewer Settings;394 /** @name Virtual Machine: Log-viewer widget options 395 * @{ */ 396 SHARED_LIBRARY_STUFF extern const char *GUI_LogViewerOptions; 397 397 /** Holds log-viewer wrap line flag. */ 398 398 SHARED_LIBRARY_STUFF extern const char *GUI_LogViewerWrapLinesEnabled; -
trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.cpp
r75306 r75424 4494 4494 } 4495 4495 4496 void UIExtraDataManager::setLogViwever Settings(const QFont &font, bool wrapLines, bool showLineNumbers)4496 void UIExtraDataManager::setLogViweverOptions(const QFont &font, bool wrapLines, bool showLineNumbers) 4497 4497 { 4498 4498 /* Serialize passed values: */ … … 4513 4513 4514 4514 /* Re-cache corresponding extra-data: */ 4515 setExtraDataStringList(GUI_LogViewer Settings, data);4515 setExtraDataStringList(GUI_LogViewerOptions, data); 4516 4516 } 4517 4517 4518 4518 bool UIExtraDataManager::logViewerWrapLines() 4519 4519 { 4520 const QStringList data = extraDataStringList(GUI_LogViewer Settings);4520 const QStringList data = extraDataStringList(GUI_LogViewerOptions); 4521 4521 for (int i = 0; i < data.size(); ++i) 4522 4522 { … … 4529 4529 bool UIExtraDataManager::logViewerShowLineNumbers() 4530 4530 { 4531 const QStringList data = extraDataStringList(GUI_LogViewer Settings);4531 const QStringList data = extraDataStringList(GUI_LogViewerOptions); 4532 4532 for (int i = 0; i < data.size(); ++i) 4533 4533 { … … 4540 4540 QFont UIExtraDataManager::logViewerFont() 4541 4541 { 4542 const QStringList data = extraDataStringList(GUI_LogViewer Settings);4542 const QStringList data = extraDataStringList(GUI_LogViewerOptions); 4543 4543 if (data.size() < 3) 4544 4544 return QFont(); -
trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.h
r75224 r75424 689 689 /** @} */ 690 690 691 /** @name Virtual Machine: Log Viewer widget settings692 * @{ */ 693 void setLogViwever Settings(const QFont &font, bool wrapLines, bool showLineNumbers);691 /** @name Virtual Machine: Log Viewer widget options 692 * @{ */ 693 void setLogViweverOptions(const QFont &font, bool wrapLines, bool showLineNumbers); 694 694 /** Returns log-viewer line wrapping flag. */ 695 695 bool logViewerWrapLines(); -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIActionPool.cpp
r75311 r75424 1332 1332 }; 1333 1333 1334 /** Simple action extension, used as 'Toggle Pane Settings' action class. */1335 class UIActionMenuSelectorLogTogglePane Settings : public UIActionToggle1336 { 1337 Q_OBJECT; 1338 1339 public: 1340 1341 /** Constructs action passing @a pParent to the base-class. */ 1342 UIActionMenuSelectorLogTogglePane Settings(UIActionPool *pParent)1334 /** Simple action extension, used as 'Toggle Pane Options' action class. */ 1335 class UIActionMenuSelectorLogTogglePaneOptions : public UIActionToggle 1336 { 1337 Q_OBJECT; 1338 1339 public: 1340 1341 /** Constructs action passing @a pParent to the base-class. */ 1342 UIActionMenuSelectorLogTogglePaneOptions(UIActionPool *pParent) 1343 1343 : UIActionToggle(pParent) 1344 1344 { 1345 1345 setShortcutContext(Qt::WidgetWithChildrenShortcut); 1346 setIcon(UIIconPool::iconSetFull(":/log_viewer_ settings_32px.png", ":/log_viewer_settings_16px.png",1347 ":/log_viewer_ settings_disabled_32px.png", ":/log_viewer_settings_disabled_16px.png"));1348 } 1349 1350 protected: 1351 1352 /** Returns shortcut extra-data ID. */ 1353 virtual QString shortcutExtraDataID() const /* override */ 1354 { 1355 return QString("ToggleLog Settings");1346 setIcon(UIIconPool::iconSetFull(":/log_viewer_options_32px.png", ":/log_viewer_options_16px.png", 1347 ":/log_viewer_options_disabled_32px.png", ":/log_viewer_options_disabled_16px.png")); 1348 } 1349 1350 protected: 1351 1352 /** Returns shortcut extra-data ID. */ 1353 virtual QString shortcutExtraDataID() const /* override */ 1354 { 1355 return QString("ToggleLogOptions"); 1356 1356 } 1357 1357 … … 1365 1365 virtual void retranslateUi() /* override */ 1366 1366 { 1367 setName(QApplication::translate("UIActionPool", "& Settings"));1367 setName(QApplication::translate("UIActionPool", "&Options")); 1368 1368 setShortcutScope(QApplication::translate("UIActionPool", "Log Viewer")); 1369 setStatusTip(QApplication::translate("UIActionPool", "Open pane with log viewer settings"));1370 setToolTip(QApplication::translate("UIActionPool", "Open Settings Pane (%1)").arg(shortcut().toString()));1369 setStatusTip(QApplication::translate("UIActionPool", "Open pane with log viewer options")); 1370 setToolTip(QApplication::translate("UIActionPool", "Open Options Pane (%1)").arg(shortcut().toString())); 1371 1371 } 1372 1372 }; … … 2500 2500 m_pool[UIActionIndex_M_Log_T_Filter] = new UIActionMenuSelectorLogTogglePaneFilter(this); 2501 2501 m_pool[UIActionIndex_M_Log_T_Bookmark] = new UIActionMenuSelectorLogTogglePaneBookmark(this); 2502 m_pool[UIActionIndex_M_Log_T_ Settings] = new UIActionMenuSelectorLogTogglePaneSettings(this);2502 m_pool[UIActionIndex_M_Log_T_Options] = new UIActionMenuSelectorLogTogglePaneOptions(this); 2503 2503 m_pool[UIActionIndex_M_Log_S_Refresh] = new UIActionMenuSelectorLogPerformRefresh(this); 2504 2504 m_pool[UIActionIndex_M_Log_S_Save] = new UIActionMenuSelectorLogPerformSave(this); … … 2837 2837 /* 'Bookmarks' action: */ 2838 2838 fSeparator = addAction(pMenu, action(UIActionIndex_M_Log_T_Bookmark)) || fSeparator; 2839 /* ' Settings' action: */2840 fSeparator = addAction(pMenu, action(UIActionIndex_M_Log_T_ Settings)) || fSeparator;2839 /* 'Options' action: */ 2840 fSeparator = addAction(pMenu, action(UIActionIndex_M_Log_T_Options)) || fSeparator; 2841 2841 2842 2842 /* Separator? */ -
trunk/src/VBox/Frontends/VirtualBox/src/globals/UIActionPool.h
r75309 r75424 94 94 UIActionIndex_M_Log_T_Filter, 95 95 UIActionIndex_M_Log_T_Bookmark, 96 UIActionIndex_M_Log_T_ Settings,96 UIActionIndex_M_Log_T_Options, 97 97 UIActionIndex_M_Log_S_Refresh, 98 98 UIActionIndex_M_Log_S_Save, -
trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerOptionsPanel.cpp
r75423 r75424 32 32 # include "QIToolButton.h" 33 33 # include "UIIconPool.h" 34 # include "UIVMLogViewer SettingsPanel.h"34 # include "UIVMLogViewerOptionsPanel.h" 35 35 # include "UIVMLogViewerWidget.h" 36 36 … … 38 38 39 39 40 UIVMLogViewer SettingsPanel::UIVMLogViewerSettingsPanel(QWidget *pParent, UIVMLogViewerWidget *pViewer)40 UIVMLogViewerOptionsPanel::UIVMLogViewerOptionsPanel(QWidget *pParent, UIVMLogViewerWidget *pViewer) 41 41 : UIVMLogViewerPanel(pParent, pViewer) 42 42 , m_pLineNumberCheckBox(0) … … 51 51 } 52 52 53 void UIVMLogViewer SettingsPanel::setShowLineNumbers(bool bShowLineNumbers)53 void UIVMLogViewerOptionsPanel::setShowLineNumbers(bool bShowLineNumbers) 54 54 { 55 55 if (!m_pLineNumberCheckBox) … … 60 60 } 61 61 62 void UIVMLogViewer SettingsPanel::setWrapLines(bool bWrapLines)62 void UIVMLogViewerOptionsPanel::setWrapLines(bool bWrapLines) 63 63 { 64 64 if (!m_pWrapLinesCheckBox) … … 69 69 } 70 70 71 void UIVMLogViewer SettingsPanel::setFontSizeInPoints(int fontSizeInPoints)71 void UIVMLogViewerOptionsPanel::setFontSizeInPoints(int fontSizeInPoints) 72 72 { 73 73 if (!m_pFontSizeSpinBox) … … 78 78 } 79 79 80 void UIVMLogViewer SettingsPanel::prepareWidgets()80 void UIVMLogViewerOptionsPanel::prepareWidgets() 81 81 { 82 82 if (!mainLayout()) … … 145 145 } 146 146 147 void UIVMLogViewer SettingsPanel::prepareConnections()147 void UIVMLogViewerOptionsPanel::prepareConnections() 148 148 { 149 149 if (m_pLineNumberCheckBox) 150 connect(m_pLineNumberCheckBox, &QCheckBox::toggled, this, &UIVMLogViewer SettingsPanel::sigShowLineNumbers);150 connect(m_pLineNumberCheckBox, &QCheckBox::toggled, this, &UIVMLogViewerOptionsPanel::sigShowLineNumbers); 151 151 if (m_pWrapLinesCheckBox) 152 connect(m_pWrapLinesCheckBox, &QCheckBox::toggled, this, &UIVMLogViewer SettingsPanel::sigWrapLines);152 connect(m_pWrapLinesCheckBox, &QCheckBox::toggled, this, &UIVMLogViewerOptionsPanel::sigWrapLines); 153 153 if (m_pFontSizeSpinBox) 154 154 connect(m_pFontSizeSpinBox, static_cast<void(QSpinBox::*)(int)>(&QSpinBox::valueChanged), 155 this, &UIVMLogViewer SettingsPanel::sigChangeFontSizeInPoints);155 this, &UIVMLogViewerOptionsPanel::sigChangeFontSizeInPoints); 156 156 if (m_pOpenFontDialogButton) 157 connect(m_pOpenFontDialogButton, &QIToolButton::clicked, this, &UIVMLogViewer SettingsPanel::sltOpenFontDialog);157 connect(m_pOpenFontDialogButton, &QIToolButton::clicked, this, &UIVMLogViewerOptionsPanel::sltOpenFontDialog); 158 158 if (m_pResetToDefaultsButton) 159 connect(m_pResetToDefaultsButton, &QIToolButton::clicked, this, &UIVMLogViewer SettingsPanel::sigResetToDefaults);159 connect(m_pResetToDefaultsButton, &QIToolButton::clicked, this, &UIVMLogViewerOptionsPanel::sigResetToDefaults); 160 160 } 161 161 162 void UIVMLogViewer SettingsPanel::retranslateUi()162 void UIVMLogViewerOptionsPanel::retranslateUi() 163 163 { 164 164 UIVMLogViewerPanel::retranslateUi(); … … 174 174 175 175 m_pOpenFontDialogButton->setToolTip(UIVMLogViewerWidget::tr("Open a font dialog to select font face for the logviewer")); 176 m_pResetToDefaultsButton->setToolTip(UIVMLogViewerWidget::tr("Reset settings to application defaults"));176 m_pResetToDefaultsButton->setToolTip(UIVMLogViewerWidget::tr("Reset options to application defaults")); 177 177 } 178 178 179 void UIVMLogViewer SettingsPanel::sltOpenFontDialog()179 void UIVMLogViewerOptionsPanel::sltOpenFontDialog() 180 180 { 181 181 QFont currentFont; -
trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerOptionsPanel.h
r75423 r75424 16 16 */ 17 17 18 #ifndef ___UIVMLogViewer SettingssPanel_h___19 #define ___UIVMLogViewer SettingssPanel_h___18 #ifndef ___UIVMLogViewerOptionsPanel_h___ 19 #define ___UIVMLogViewerOptionsPanel_h___ 20 20 21 21 /* GUI includes: */ … … 29 29 class UIVMLogViewerWidget; 30 30 31 /** UIVMLogViewerPanel extension providing GUI to manage logviewer settings. */32 class UIVMLogViewer SettingsPanel : public UIVMLogViewerPanel31 /** UIVMLogViewerPanel extension providing GUI to manage logviewer options. */ 32 class UIVMLogViewerOptionsPanel : public UIVMLogViewerPanel 33 33 { 34 34 Q_OBJECT; … … 44 44 public: 45 45 46 UIVMLogViewer SettingsPanel(QWidget *pParent, UIVMLogViewerWidget *pViewer);46 UIVMLogViewerOptionsPanel(QWidget *pParent, UIVMLogViewerWidget *pViewer); 47 47 48 48 void setShowLineNumbers(bool bShowLineNumbers); … … 79 79 }; 80 80 81 #endif /* !___UIVMLogViewer SettingsPanel_h___ */81 #endif /* !___UIVMLogViewerOptionsPanel_h___ */ -
trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerWidget.cpp
r75161 r75424 47 47 # include "UIVMLogViewerFilterPanel.h" 48 48 # include "UIVMLogViewerSearchPanel.h" 49 # include "UIVMLogViewer SettingsPanel.h"49 # include "UIVMLogViewerOptionsPanel.h" 50 50 # include "UIToolBar.h" 51 51 … … 73 73 , m_pFilterPanel(0) 74 74 , m_pBookmarksPanel(0) 75 , m_p SettingsPanel(0)75 , m_pOptionsPanel(0) 76 76 , m_pMainLayout(0) 77 77 , m_pToolBar(0) … … 194 194 m_pActionPool->action(UIActionIndex_M_Log_S_Save)->setEnabled(!noLogsToShow); 195 195 m_pActionPool->action(UIActionIndex_M_Log_T_Bookmark)->setEnabled(!noLogsToShow); 196 m_pActionPool->action(UIActionIndex_M_Log_T_ Settings)->setEnabled(!noLogsToShow);196 m_pActionPool->action(UIActionIndex_M_Log_T_Options)->setEnabled(!noLogsToShow); 197 197 198 198 m_pTabWidget->show(); … … 402 402 } 403 403 404 void UIVMLogViewerWidget::sltReset SettingsToDefault()404 void UIVMLogViewerWidget::sltResetOptionsToDefault() 405 405 { 406 406 sltShowLineNumbers(true); … … 408 408 sltChangeFont(QFontDatabase::systemFont(QFontDatabase::FixedFont)); 409 409 410 if (m_p SettingsPanel)411 { 412 m_p SettingsPanel->setShowLineNumbers(true);413 m_p SettingsPanel->setWrapLines(false);414 m_p SettingsPanel->setFontSizeInPoints(m_font.pointSize());410 if (m_pOptionsPanel) 411 { 412 m_pOptionsPanel->setShowLineNumbers(true); 413 m_pOptionsPanel->setWrapLines(false); 414 m_pOptionsPanel->setFontSizeInPoints(m_font.pointSize()); 415 415 } 416 416 } … … 422 422 /* Prepare widgets: */ 423 423 prepareWidgets(); 424 /* Load settings: */425 load Settings();424 /* Load options: */ 425 loadOptions(); 426 426 427 427 /* Apply language settings: */ … … 440 440 addAction(m_pActionPool->action(UIActionIndex_M_Log_T_Filter)); 441 441 addAction(m_pActionPool->action(UIActionIndex_M_Log_T_Bookmark)); 442 addAction(m_pActionPool->action(UIActionIndex_M_Log_T_ Settings));442 addAction(m_pActionPool->action(UIActionIndex_M_Log_T_Options)); 443 443 addAction(m_pActionPool->action(UIActionIndex_M_Log_S_Refresh)); 444 444 addAction(m_pActionPool->action(UIActionIndex_M_Log_S_Save)); … … 451 451 connect(m_pActionPool->action(UIActionIndex_M_Log_T_Bookmark), &QAction::toggled, 452 452 this, &UIVMLogViewerWidget::sltPanelActionToggled); 453 connect(m_pActionPool->action(UIActionIndex_M_Log_T_ Settings), &QAction::toggled,453 connect(m_pActionPool->action(UIActionIndex_M_Log_T_Options), &QAction::toggled, 454 454 this, &UIVMLogViewerWidget::sltPanelActionToggled); 455 455 connect(m_pActionPool->action(UIActionIndex_M_Log_S_Refresh), &QAction::triggered, … … 533 533 } 534 534 535 /* Create VM Log-Viewer settings-panel: */536 m_p SettingsPanel = new UIVMLogViewerSettingsPanel(0, this);537 if (m_p SettingsPanel)535 /* Create VM Log-Viewer options-panel: */ 536 m_pOptionsPanel = new UIVMLogViewerOptionsPanel(0, this); 537 if (m_pOptionsPanel) 538 538 { 539 539 /* Configure panel: */ 540 m_p SettingsPanel->hide();541 m_p SettingsPanel->setShowLineNumbers(m_bShowLineNumbers);542 m_p SettingsPanel->setWrapLines(m_bWrapLines);543 m_p SettingsPanel->setFontSizeInPoints(m_font.pointSize());544 connect(m_p SettingsPanel, &UIVMLogViewerSettingsPanel::sigShowLineNumbers, this, &UIVMLogViewerWidget::sltShowLineNumbers);545 connect(m_p SettingsPanel, &UIVMLogViewerSettingsPanel::sigWrapLines, this, &UIVMLogViewerWidget::sltWrapLines);546 connect(m_p SettingsPanel, &UIVMLogViewerSettingsPanel::sigChangeFontSizeInPoints, this, &UIVMLogViewerWidget::sltFontSizeChanged);547 connect(m_p SettingsPanel, &UIVMLogViewerSettingsPanel::sigChangeFont, this, &UIVMLogViewerWidget::sltChangeFont);548 connect(m_p SettingsPanel, &UIVMLogViewerSettingsPanel::sigResetToDefaults, this, &UIVMLogViewerWidget::sltResetSettingsToDefault);549 m_panelActionMap.insert(m_p SettingsPanel, m_pActionPool->action(UIActionIndex_M_Log_T_Settings));540 m_pOptionsPanel->hide(); 541 m_pOptionsPanel->setShowLineNumbers(m_bShowLineNumbers); 542 m_pOptionsPanel->setWrapLines(m_bWrapLines); 543 m_pOptionsPanel->setFontSizeInPoints(m_font.pointSize()); 544 connect(m_pOptionsPanel, &UIVMLogViewerOptionsPanel::sigShowLineNumbers, this, &UIVMLogViewerWidget::sltShowLineNumbers); 545 connect(m_pOptionsPanel, &UIVMLogViewerOptionsPanel::sigWrapLines, this, &UIVMLogViewerWidget::sltWrapLines); 546 connect(m_pOptionsPanel, &UIVMLogViewerOptionsPanel::sigChangeFontSizeInPoints, this, &UIVMLogViewerWidget::sltFontSizeChanged); 547 connect(m_pOptionsPanel, &UIVMLogViewerOptionsPanel::sigChangeFont, this, &UIVMLogViewerWidget::sltChangeFont); 548 connect(m_pOptionsPanel, &UIVMLogViewerOptionsPanel::sigResetToDefaults, this, &UIVMLogViewerWidget::sltResetOptionsToDefault); 549 m_panelActionMap.insert(m_pOptionsPanel, m_pActionPool->action(UIActionIndex_M_Log_T_Options)); 550 550 551 551 /* Add into layout: */ 552 m_pMainLayout->addWidget(m_p SettingsPanel);552 m_pMainLayout->addWidget(m_pOptionsPanel); 553 553 } 554 554 } … … 572 572 m_pToolBar->addAction(m_pActionPool->action(UIActionIndex_M_Log_T_Filter)); 573 573 m_pToolBar->addAction(m_pActionPool->action(UIActionIndex_M_Log_T_Bookmark)); 574 m_pToolBar->addAction(m_pActionPool->action(UIActionIndex_M_Log_T_ Settings));574 m_pToolBar->addAction(m_pActionPool->action(UIActionIndex_M_Log_T_Options)); 575 575 m_pToolBar->addSeparator(); 576 576 m_pToolBar->addAction(m_pActionPool->action(UIActionIndex_M_Log_S_Refresh)); … … 590 590 } 591 591 592 void UIVMLogViewerWidget::load Settings()592 void UIVMLogViewerWidget::loadOptions() 593 593 { 594 594 m_bWrapLines = gEDataManager->logViewerWrapLines(); … … 599 599 } 600 600 601 void UIVMLogViewerWidget::save Settings()602 { 603 gEDataManager->setLogViwever Settings(m_font, m_bWrapLines, m_bShowLineNumbers);601 void UIVMLogViewerWidget::saveOptions() 602 { 603 gEDataManager->setLogViweverOptions(m_font, m_bWrapLines, m_bShowLineNumbers); 604 604 } 605 605 606 606 void UIVMLogViewerWidget::cleanup() 607 607 { 608 /* Save settings: */609 save Settings();608 /* Save options: */ 609 saveOptions(); 610 610 } 611 611 -
trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerWidget.h
r75268 r75424 44 44 class UIVMLogViewerPanel; 45 45 class UIVMLogViewerSearchPanel; 46 class UIVMLogViewer SettingsPanel;46 class UIVMLogViewerOptionsPanel; 47 47 48 48 /** QWidget extension providing GUI for VirtualBox LogViewer. It … … 125 125 void sltFontSizeChanged(int fontSize); 126 126 void sltChangeFont(QFont font); 127 void sltReset SettingsToDefault();127 void sltResetOptionsToDefault(); 128 128 /** @} */ 129 129 … … 140 140 /** Prepares toolbar. */ 141 141 void prepareToolBar(); 142 /** Loads settings. */143 void load Settings();144 145 /** Saves settings. */146 void save Settings();142 /** Loads options. */ 143 void loadOptions(); 144 145 /** Saves options. */ 146 void saveOptions(); 147 147 /** Cleanups VM Log-Viewer. */ 148 148 void cleanup(); … … 208 208 UIVMLogViewerFilterPanel *m_pFilterPanel; 209 209 UIVMLogViewerBookmarksPanel *m_pBookmarksPanel; 210 UIVMLogViewer SettingsPanel *m_pSettingsPanel;210 UIVMLogViewerOptionsPanel *m_pOptionsPanel; 211 211 QMap<UIVMLogViewerPanel*, QAction*> m_panelActionMap; 212 212 QList<UIVMLogViewerPanel*> m_visiblePanelsList; … … 221 221 /** @name Toolbar and menu variables. Cache these to restore them after refresh. 222 222 * @{ */ 223 /** Showing/hiding line numbers and line wraping settings are set per223 /** Showing/hiding line numbers and line wraping options are set per 224 224 UIVMLogViewerWidget and applies to all log pages (all tabs) */ 225 225 bool m_bShowLineNumbers; … … 230 230 friend class UIVMLogViewerFilterPanel; 231 231 friend class UIVMLogViewerSearchPanel; 232 friend class UIVMLogViewer SettingsPanel;232 friend class UIVMLogViewerOptionsPanel; 233 233 friend class UIVMLogViewerPanel; 234 234 friend class UIVMLogViewerDialog; -
trunk/src/VBox/Frontends/VirtualBox/src/manager/UIVirtualBoxManagerWidget.cpp
r75209 r75424 682 682 m_pToolBar->addAction(actionPool()->action(UIActionIndex_M_Log_T_Filter)); 683 683 m_pToolBar->addAction(actionPool()->action(UIActionIndex_M_Log_T_Bookmark)); 684 m_pToolBar->addAction(actionPool()->action(UIActionIndex_M_Log_T_ Settings));684 m_pToolBar->addAction(actionPool()->action(UIActionIndex_M_Log_T_Options)); 685 685 m_pToolBar->addAction(actionPool()->action(UIActionIndex_M_Log_S_Refresh)); 686 686 m_pToolBar->addSeparator();
Note:
See TracChangeset
for help on using the changeset viewer.

