Removed unused QDesktopWidget includes

Also made the overlooked deprecation fixes (which is now a necessary fix because deprecation warning became a compilation error now), Extends #2647
This commit is contained in:
zneix 2021-07-31 18:50:35 +02:00
parent 0ea7db094e
commit c99f12e8fe
No known key found for this signature in database
GPG key ID: 911916E0523B22F6
3 changed files with 2 additions and 5 deletions

View file

@ -1,7 +1,6 @@
#include "singletons/WindowManager.hpp" #include "singletons/WindowManager.hpp"
#include <QDebug> #include <QDebug>
#include <QDesktopWidget>
#include <QJsonArray> #include <QJsonArray>
#include <QJsonDocument> #include <QJsonDocument>
#include <QJsonObject> #include <QJsonObject>

View file

@ -13,7 +13,6 @@
#include <QApplication> #include <QApplication>
#include <QDebug> #include <QDebug>
#include <QDesktopWidget>
#include <QFont> #include <QFont>
#include <QIcon> #include <QIcon>
#include <functional> #include <functional>
@ -349,14 +348,14 @@ bool BaseWindow::event(QEvent *event)
void BaseWindow::wheelEvent(QWheelEvent *event) void BaseWindow::wheelEvent(QWheelEvent *event)
{ {
if (event->orientation() != Qt::Vertical) if (!event->angleDelta().y())
{ {
return; return;
} }
if (event->modifiers() & Qt::ControlModifier) if (event->modifiers() & Qt::ControlModifier)
{ {
if (event->delta() > 0) if (event->angleDelta().y() > 0)
{ {
getSettings()->setClampedUiScale( getSettings()->setClampedUiScale(
getSettings()->getClampedUiScale() + 0.1); getSettings()->getClampedUiScale() + 0.1);

View file

@ -4,7 +4,6 @@
#include "singletons/Fonts.hpp" #include "singletons/Fonts.hpp"
#include <QDebug> #include <QDebug>
#include <QDesktopWidget>
#include <QStyle> #include <QStyle>
#include <QVBoxLayout> #include <QVBoxLayout>