Resize dialog size on high DPI monitors

This commit is contained in:
Chocobo1 2017-12-03 15:32:58 +08:00
parent aaaa67050c
commit 27cf98a962
No known key found for this signature in database
GPG key ID: 210D9C873253A68C
26 changed files with 125 additions and 80 deletions

View file

@ -53,6 +53,7 @@
#include "guiiconprovider.h"
#include "autoexpandabledialog.h"
#include "ui_automatedrssdownloader.h"
#include "utils.h"
const QString EXT_JSON {QStringLiteral(".json")};
const QString EXT_LEGACY {QStringLiteral(".rssrules")};
@ -155,14 +156,14 @@ AutomatedRssDownloader::~AutomatedRssDownloader()
void AutomatedRssDownloader::loadSettings()
{
const Preferences *const pref = Preferences::instance();
resize(pref->getRssGeometrySize(this->size()));
Utils::Gui::resize(this, pref->getRssGeometrySize());
m_ui->hsplitter->restoreState(pref->getRssHSplitterSizes());
}
void AutomatedRssDownloader::saveSettings()
{
Preferences *const pref = Preferences::instance();
pref->setRssGeometrySize(this->size());
pref->setRssGeometrySize(size());
pref->setRssHSplitterSizes(m_ui->hsplitter->saveState());
}