diff options
author | saturneric <[email protected]> | 2024-01-19 14:09:04 +0000 |
---|---|---|
committer | saturneric <[email protected]> | 2024-01-19 14:09:04 +0000 |
commit | 0a12c88db5ca2e71de0ea24e7d75a6df10a727d3 (patch) | |
tree | 9e3167f12ffb2f16979ef5435017faa44175fc6d /src | |
parent | fix: solve discovered bugs and improve ui operations (diff) | |
download | GpgFrontend-0a12c88db5ca2e71de0ea24e7d75a6df10a727d3.tar.gz GpgFrontend-0a12c88db5ca2e71de0ea24e7d75a6df10a727d3.zip |
fix: slove app building problems
Diffstat (limited to 'src')
-rw-r--r-- | src/pinentry/pinentrydialog.cpp | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/src/pinentry/pinentrydialog.cpp b/src/pinentry/pinentrydialog.cpp index c823c1f3..0eafeb42 100644 --- a/src/pinentry/pinentrydialog.cpp +++ b/src/pinentry/pinentrydialog.cpp @@ -55,34 +55,21 @@ #include "pinlineedit.h" #include "util.h" -#ifdef Q_OS_WIN -#include <windows.h> -#if QT_VERSION >= 0x050700 -#include <QtPlatformHeaders/QWindowsWindowFunctions> -#endif -#endif - void raiseWindow(QWidget *w) { -#ifdef Q_OS_WIN -#if QT_VERSION >= 0x050700 - QWindowsWindowFunctions::setWindowActivationBehavior( - QWindowsWindowFunctions::AlwaysActivateWindow); -#endif -#endif w->setWindowState((w->windowState() & ~Qt::WindowMinimized) | Qt::WindowActive); w->activateWindow(); w->raise(); } -QPixmap applicationIconPixmap(const QIcon &overlayIcon) { +auto applicationIconPixmap(const QIcon &overlayIcon) -> QPixmap { QPixmap pm = qApp->windowIcon().pixmap(48, 48); if (!overlayIcon.isNull()) { QPainter painter(&pm); - const int emblemSize = 22; - painter.drawPixmap(pm.width() - emblemSize, 0, - overlayIcon.pixmap(emblemSize, emblemSize)); + const int emblem_size = 22; + painter.drawPixmap(pm.width() - emblem_size, 0, + overlayIcon.pixmap(emblem_size, emblem_size)); } return pm; |