Skip to content

Commit f9158dd

Browse files
committed
Fix for Qt-5.5
1 parent 0e20465 commit f9158dd

File tree

1 file changed

+6
-10
lines changed

1 file changed

+6
-10
lines changed

src/mainwindow.cpp

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -429,16 +429,12 @@ void MainWindow::showBrowserContextMenu(ViewWindow* browser,
429429

430430
if ( !link.isEmpty() )
431431
{
432-
m->addAction( i18n("Open Link in a new tab\tShift+LMB"),
433-
[this, link] ()
434-
{
435-
openPage( link, UBrowser::OPEN_IN_NEW );
436-
});
437-
m->addAction( i18n("Open Link in a new background tab\tCtrl+LMB"),
438-
[this, link] ()
439-
{
440-
openPage( link, UBrowser::OPEN_IN_BACKGROUND );
441-
});
432+
QAction* newTab = m->addAction( i18n( "Open Link in a new tab\tShift+LMB" ) );
433+
connect( newTab, &QAction::triggered,
434+
[this, link]() { openPage( link, UBrowser::OPEN_IN_NEW ); } );
435+
QAction* bckgTab = m->addAction( i18n( "Open Link in a new background tab\tCtrl+LMB" ) );
436+
connect( bckgTab, &QAction::triggered,
437+
[this, link]() { openPage( link, UBrowser::OPEN_IN_BACKGROUND ); } );
442438
m->addSeparator();
443439
}
444440

0 commit comments

Comments
 (0)