mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-24 04:24:09 +00:00
Handle Ctrl+Tab/Ctrl+Shift+Tab in translate line as tabs switch
This commit is contained in:
parent
21c94bb7dd
commit
896bd350be
|
@ -2541,6 +2541,11 @@ bool MainWindow::eventFilter( QObject * obj, QEvent * ev )
|
||||||
ctrlTabPressed();
|
ctrlTabPressed();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
else if( obj == translateLine )
|
||||||
|
{
|
||||||
|
QApplication::sendEvent( ui.tabWidget, ev );
|
||||||
|
return true;
|
||||||
|
}
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2560,6 +2565,12 @@ bool MainWindow::eventFilter( QObject * obj, QEvent * ev )
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if( keyEvent->matches( QKeySequence::PreviousChild ) ) // Handle only Ctrl+Shist+Tab because Ctrl+Tab was already handled before
|
||||||
|
{
|
||||||
|
QApplication::sendEvent( ui.tabWidget, ev );
|
||||||
|
return true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( ev->type() == QEvent::FocusIn ) {
|
if ( ev->type() == QEvent::FocusIn ) {
|
||||||
|
|
Loading…
Reference in a new issue