disabled non client dpi scaling until issue is fixed

This commit is contained in:
fourtf 2017-12-18 02:47:01 +01:00
parent 929552f74d
commit cca065f0f9
7 changed files with 12 additions and 13 deletions

View file

@ -31,8 +31,8 @@ public:
EnableNonClientDpiScaling enableNonClientDpiScaling =
(EnableNonClientDpiScaling)user32.resolve("EnableNonClientDpiScaling");
if (enableNonClientDpiScaling)
enableNonClientDpiScaling(msg->hwnd);
// if (enableNonClientDpiScaling)
// enableNonClientDpiScaling(msg->hwnd);
}
}
return false;

View file

@ -123,7 +123,7 @@ AccountPopupWidget::AccountPopupWidget(std::shared_ptr<Channel> channel)
util::twitch::getUserID(userNickname, this,
[=](const QString &id) { currentTwitchUser->setUserId(id); });
this->dpiMultiplyerChanged(this->getDpiMultiplier(), this->getDpiMultiplier());
this->dpiMultiplierChanged(this->getDpiMultiplier(), this->getDpiMultiplier());
}
void AccountPopupWidget::setName(const QString &name)
@ -200,7 +200,7 @@ void AccountPopupWidget::updatePermissions()
}
}
void AccountPopupWidget::dpiMultiplyerChanged(float oldDpi, float newDpi)
void AccountPopupWidget::dpiMultiplierChanged(float oldDpi, float newDpi)
{
this->setStyleSheet(QString("* { font-size: <font-size>px; }")
.replace("<font-size>", QString::number((int)(12 * newDpi))));

View file

@ -31,7 +31,7 @@ public:
void updatePermissions();
protected:
virtual void dpiMultiplyerChanged(float oldDpi, float newDpi) override;
virtual void dpiMultiplierChanged(float oldDpi, float newDpi) override;
private:
Ui::AccountPopup *_ui;

View file

@ -2,10 +2,9 @@
#include "colorscheme.hpp"
#include "settingsmanager.hpp"
//#include <QApplication>
#include <QDebug>
//#include <QDesktopWidget>
//#include <QScreen>
#include <QLayout>
#include <QtGlobal>
#include <boost/signals2.hpp>
#include "util/nativeeventhelper.hpp"
@ -91,7 +90,7 @@ bool BaseWidget::nativeEvent(const QByteArray &eventType, void *message, long *r
this->dpiMultiplier = dpi / 96.f;
float scale = this->dpiMultiplier / oldDpiMultiplier;
this->dpiMultiplyerChanged(oldDpiMultiplier, this->dpiMultiplier);
this->dpiMultiplierChanged(oldDpiMultiplier, this->dpiMultiplier);
this->resize(static_cast<int>(this->width() * scale),
static_cast<int>(this->height() * scale));

View file

@ -35,7 +35,7 @@ protected:
virtual bool nativeEvent(const QByteArray &eventType, void *message, long *result) override;
#endif
virtual void dpiMultiplyerChanged(float oldDpi, float newDpi)
virtual void dpiMultiplierChanged(float oldDpi, float newDpi)
{
}
void initAsWindow();

View file

@ -67,7 +67,7 @@ SettingsDialog::SettingsDialog()
this->addTabs();
this->dpiMultiplyerChanged(this->getDpiMultiplier(), this->getDpiMultiplier());
this->dpiMultiplierChanged(this->getDpiMultiplier(), this->getDpiMultiplier());
}
void SettingsDialog::addTabs()
@ -608,7 +608,7 @@ void SettingsDialog::showDialog()
instance->setFocus();
}
void SettingsDialog::dpiMultiplyerChanged(float oldDpi, float newDpi)
void SettingsDialog::dpiMultiplierChanged(float oldDpi, float newDpi)
{
QFile file(":/qss/settings.qss");
file.open(QFile::ReadOnly);

View file

@ -34,7 +34,7 @@ public:
static void showDialog();
protected:
virtual void dpiMultiplyerChanged(float oldDpi, float newDpi) override;
virtual void dpiMultiplierChanged(float oldDpi, float newDpi) override;
private:
SettingsSnapshot snapshot;