started to refactor Application

This commit is contained in:
fourtf
2018-07-07 11:41:01 +02:00
parent 6a418e6e59
commit c609a9fd37
32 changed files with 195 additions and 147 deletions
+1 -16
View File
@@ -29,26 +29,11 @@ Settings &Settings::getInstance()
void Settings::initialize()
{
this->timestampFormat.connect([](auto, auto) {
auto app = getApp();
app->windows->layoutChannelViews();
});
this->emoteScale.connect([](auto, auto) { getApp()->windows->forceLayoutChannelViews(); });
this->timestampFormat.connect([](auto, auto) { getApp()->windows->forceLayoutChannelViews(); });
this->alternateMessageBackground.connect(
[](auto, auto) { getApp()->windows->forceLayoutChannelViews(); });
this->separateMessages.connect(
[](auto, auto) { getApp()->windows->forceLayoutChannelViews(); });
this->collpseMessagesMinLines.connect(
[](auto, auto) { getApp()->windows->forceLayoutChannelViews(); });
}
void Settings::load()
{
auto app = getApp();
QString settingsPath = app->paths->settingsDirectory + "/settings.json";
QString settingsPath = getPaths()->settingsDirectory + "/settings.json";
pajlada::Settings::SettingManager::load(qPrintable(settingsPath));
}