mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-27 19:24:08 +00:00
Qt5: disable an obsolete Qt4 X11 window focus workaround
I have verified in numerous desktop environments and window managers that the workaround does not work with Qt5. Let us disable it in Qt5 builds to prevent potential issues and eliminate the small performance overhead.
This commit is contained in:
parent
3c4cdaff8e
commit
d530af7781
|
@ -906,7 +906,7 @@ void ScanPopup::requestWindowFocus()
|
|||
// One of the rare, actually working workarounds for requesting a user keyboard focus on X11,
|
||||
// works for Qt::Popup windows, exactly like our Scan Popup (in unpinned state).
|
||||
// Modern window managers actively resist to automatically focus pop-up windows.
|
||||
#ifdef HAVE_X11
|
||||
#if defined HAVE_X11 && QT_VERSION < QT_VERSION_CHECK( 5, 0, 0 )
|
||||
if ( !ui.pinButton->isChecked() )
|
||||
{
|
||||
QMenu m( this );
|
||||
|
|
Loading…
Reference in a new issue