From: vsr Date: Fri, 27 Feb 2015 11:52:19 +0000 (+0300) Subject: Add Back and Forward actions to menu; add "Reload" action to menu and toolbar. X-Git-Tag: V7_6_0a1~16 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=2ed043ee6f5d7bb1ca4d44fcc935141042a50905;p=modules%2Fgui.git Add Back and Forward actions to menu; add "Reload" action to menu and toolbar. --- diff --git a/src/Qtx/QtxWebBrowser.cxx b/src/Qtx/QtxWebBrowser.cxx index fc705c6e4..146029464 100644 --- a/src/Qtx/QtxWebBrowser.cxx +++ b/src/Qtx/QtxWebBrowser.cxx @@ -340,6 +340,8 @@ QtxWebBrowser::QtxWebBrowser( ) : QMainWindow( 0 ) myWebView->pageAction( QWebPage::OpenLinkInNewWindow )->setVisible( false ); myWebView->pageAction( QWebPage::Back )->setText( tr( "Go Back" ) ); myWebView->pageAction( QWebPage::Forward )->setText( tr( "Go Forward" ) ); + myWebView->pageAction( QWebPage::Reload )->setText( tr( "Refresh" ) ); + myWebView->page()->setLinkDelegationPolicy( QWebPage::DelegateAllLinks ); myFindPanel = new QtxSearchTool( frame, myWebView, @@ -353,12 +355,17 @@ QtxWebBrowser::QtxWebBrowser( ) : QMainWindow( 0 ) QToolBar* toolbar = addToolBar( tr( "Navigation" ) ); toolbar->addAction( myWebView->pageAction( QWebPage::Back ) ); toolbar->addAction( myWebView->pageAction( QWebPage::Forward ) ); + toolbar->addAction( myWebView->pageAction( QWebPage::Reload ) ); QMenu* fileMenu = menuBar()->addMenu( tr( "&File" ) ); fileMenu->addAction( QPixmap( ":/images/open.png" ), tr( "&Open..." ), this, SLOT( open() ), QKeySequence( QKeySequence::Open ) ); fileMenu->addSeparator(); + fileMenu->addAction( myWebView->pageAction( QWebPage::Back ) ); + fileMenu->addAction( myWebView->pageAction( QWebPage::Forward ) ); + fileMenu->addAction( myWebView->pageAction( QWebPage::Reload ) ); + fileMenu->addSeparator(); fileMenu->addAction( tr( "&Find in text..." ), myFindPanel, SLOT( find() ), QKeySequence( QKeySequence::Find ) );