Changeset 76977 in vbox
- Timestamp:
- Jan 24, 2019 2:43:37 PM (6 years ago)
- svn:sync-xref-src-repo-rev:
- 128368
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src
- Files:
-
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataDefs.cpp
r76626 r76977 223 223 const char *UIExtraDataDefs::GUI_LogViewerShowLineNumbersDisabled = "showLineNumbersDisabled"; 224 224 const char *UIExtraDataDefs::GUI_LogViewerNoFontStyleName = "noFontStyleName"; 225 const char *UIExtraDataDefs::GUI_GuestControl_LogViewerVisiblePanels = "GUI/LogViewerVisiblePanels"; 225 226 226 227 -
trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataDefs.h
r76626 r76977 411 411 SHARED_LIBRARY_STUFF extern const char *GUI_LogViewerShowLineNumbersDisabled; 412 412 SHARED_LIBRARY_STUFF extern const char *GUI_LogViewerNoFontStyleName; 413 SHARED_LIBRARY_STUFF extern const char *GUI_GuestControl_LogViewerVisiblePanels; 413 414 /** @} */ 414 415 -
trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.cpp
r76825 r76977 4653 4653 } 4654 4654 4655 void UIExtraDataManager::setLogViewerVisiblePanels(const QStringList &panelNameList) 4656 { 4657 setExtraDataStringList(GUI_GuestControl_LogViewerVisiblePanels, panelNameList); 4658 } 4659 4660 QStringList UIExtraDataManager::logViewerVisiblePanels() 4661 { 4662 return extraDataStringList(GUI_GuestControl_LogViewerVisiblePanels); 4663 } 4664 4655 4665 void UIExtraDataManager::sltExtraDataChange(const QUuid &uMachineID, const QString &strKey, const QString &strValue) 4656 4666 { -
trunk/src/VBox/Frontends/VirtualBox/src/extradata/UIExtraDataManager.h
r76626 r76977 723 723 /** Tries to find system font by searching by family and style strings within the font database. */ 724 724 QFont logViewerFont(); 725 void setLogViewerVisiblePanels(const QStringList &panelNameList); 726 QStringList logViewerVisiblePanels(); 725 727 /** @} */ 726 728 -
trunk/src/VBox/Frontends/VirtualBox/src/guestctrl/UIFileManager.cpp
r76950 r76977 101 101 UIFileManagerOptions::~UIFileManagerOptions() 102 102 { 103 104 103 } 105 104 -
trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerWidget.cpp
r76961 r76977 49 49 /* COM includes: */ 50 50 #include "CSystemProperties.h" 51 52 53 51 54 52 UIVMLogViewerWidget::UIVMLogViewerWidget(EmbedTo enmEmbedding, … … 76 74 /* Prepare VM Log-Viewer: */ 77 75 prepare(); 76 restorePanelVisibility(); 78 77 } 79 78 … … 607 606 } 608 607 608 void UIVMLogViewerWidget::restorePanelVisibility() 609 { 610 /** Reset the action states first: */ 611 foreach(QAction* pAction, m_panelActionMap.values()) 612 { 613 pAction->blockSignals(true); 614 pAction->setChecked(false); 615 pAction->blockSignals(false); 616 } 617 618 /* Load the visible panel list and show them: */ 619 QStringList strNameList = gEDataManager->logViewerVisiblePanels(); 620 foreach(const QString strName, strNameList) 621 { 622 foreach(UIDialogPanel* pPanel, m_panelActionMap.keys()) 623 { 624 if (strName == pPanel->panelName()) 625 { 626 showPanel(pPanel); 627 break; 628 } 629 } 630 } 631 } 632 609 633 void UIVMLogViewerWidget::saveOptions() 610 634 { 635 /* Save a list of currently visible panels: */ 636 QStringList strNameList; 637 foreach(UIDialogPanel* pPanel, m_visiblePanelsList) 638 strNameList.append(pPanel->panelName()); 639 gEDataManager->setLogViewerVisiblePanels(strNameList); 640 611 641 gEDataManager->setLogViweverOptions(m_font, m_bWrapLines, m_bShowLineNumbers); 612 642 } -
trunk/src/VBox/Frontends/VirtualBox/src/logviewer/UIVMLogViewerWidget.h
r76961 r76977 147 147 /** Loads options. */ 148 148 void loadOptions(); 149 /** Shows the panels that have been visible the last time logviewer is closed. */ 150 void restorePanelVisibility(); 149 151 150 152 /** Saves options. */
Note:
See TracChangeset
for help on using the changeset viewer.