Changeset 87208 in vbox for trunk/src/VBox
- Timestamp:
- Jan 11, 2021 9:04:21 AM (4 years ago)
- Location:
- trunk/src/VBox/Frontends/VirtualBox/src/helpbrowser
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/VBox/Frontends/VirtualBox/src/helpbrowser/UIHelpBrowserWidget.cpp
r87176 r87208 764 764 { 765 765 if (m_pContentViewer) 766 m_pContentViewer-> toggleFindInPageWidget(fToggled);766 m_pContentViewer->sltToggleFindInPageWidget(fToggled); 767 767 } 768 768 -
trunk/src/VBox/Frontends/VirtualBox/src/helpbrowser/UIHelpViewer.cpp
r87204 r87208 385 385 } 386 386 387 void UIHelpViewer:: toggleFindInPageWidget(bool fVisible)387 void UIHelpViewer::sltToggleFindInPageWidget(bool fVisible) 388 388 { 389 389 if (!m_pFindInPageWidget) … … 423 423 m_pFindInPageWidget->setFont(wFont); 424 424 } 425 } 426 427 bool UIHelpViewer::isFindInPageWidgetVisible() const 428 { 429 if (m_pFindInPageWidget) 430 return m_pFindInPageWidget->isVisible(); 431 return false; 425 432 } 426 433 … … 454 461 this, &UIHelpViewer::sltHandleCopyLink); 455 462 463 464 QAction *pFindInPage = new QAction(UIHelpBrowserWidget::tr("Find in Page")); 465 pFindInPage->setCheckable(true); 466 if (m_pFindInPageWidget) 467 pFindInPage->setChecked(m_pFindInPageWidget->isVisible()); 468 connect(pFindInPage, &QAction::toggled, this, &UIHelpViewer::sltToggleFindInPageWidget); 469 456 470 pMenu.addAction(pNavigationActions); 457 471 pMenu.addAction(pOpenLinkAction); 458 472 pMenu.addAction(pOpenInNewTabAction); 459 473 pMenu.addAction(pCopyLink); 474 pMenu.addAction(pFindInPage); 460 475 461 476 QString strAnchor = anchorAt(event->pos()); -
trunk/src/VBox/Frontends/VirtualBox/src/helpbrowser/UIHelpViewer.h
r87160 r87208 53 53 void emitHistoryChangedSignal(); 54 54 void setSource(const QUrl &url) /* override */; 55 void toggleFindInPageWidget(bool fVisible);56 55 int initialFontPointSize() const; 57 56 void setFont(const QFont &); 57 bool isFindInPageWidgetVisible() const; 58 58 59 59 public slots: 60 60 void sltToggleFindInPageWidget(bool fVisible); 61 61 62 62 protected:
Note:
See TracChangeset
for help on using the changeset viewer.