From f274e658ed8214882e48b6a1754c9d2103bd7d99 Mon Sep 17 00:00:00 2001 From: YiFang Xiao Date: Tue, 10 Oct 2023 21:37:11 +0800 Subject: [PATCH] fix: remove unused method --- src/ui/scanpopup.cc | 9 --------- src/ui/scanpopup.hh | 1 - 2 files changed, 10 deletions(-) diff --git a/src/ui/scanpopup.cc b/src/ui/scanpopup.cc index 1c295712..c165fe9e 100644 --- a/src/ui/scanpopup.cc +++ b/src/ui/scanpopup.cc @@ -851,19 +851,10 @@ void ScanPopup::enterEvent( QEvent * event ) } } -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. -} - void ScanPopup::showEvent( QShowEvent * ev ) { QMainWindow::showEvent( ev ); - QTimer::singleShot( 100, this, &ScanPopup::requestWindowFocus ); - if ( groups.size() <= 1 ) // Only the default group? Hide then. ui.groupList->hide(); diff --git a/src/ui/scanpopup.hh b/src/ui/scanpopup.hh index 7be1c63e..aa26b762 100644 --- a/src/ui/scanpopup.hh +++ b/src/ui/scanpopup.hh @@ -88,7 +88,6 @@ signals: #endif public slots: - void requestWindowFocus(); void inspectElementWhenPinned( QWebEnginePage * page ); /// Translates the word from the clipboard, showing the window etc.