Skip to content

Commit

Permalink
Removed leftover script calling in the Settings code
Browse files Browse the repository at this point in the history
  • Loading branch information
mmatyas committed Sep 2, 2018
1 parent 2948c0f commit 4175609
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 17 deletions.
15 changes: 1 addition & 14 deletions src/backend/model/settings/Settings.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
#include "AppArgs.h"
#include "LocaleUtils.h"
#include "Paths.h"
#include "ScriptRunner.h"

#include <QDebug>
#include <QDir>
Expand Down Expand Up @@ -56,12 +55,7 @@ Settings::Settings(QObject* parent)
, m_locales(this)
, m_themes(this)
, m_providers(this)
{
connect(&m_locales, &LocaleList::localeChanged,
this, &Settings::callScripts);
connect(&m_themes, &ThemeList::themeChanged,
this, &Settings::callScripts);
}
{}

void Settings::setFullscreen(bool new_val)
{
Expand All @@ -74,13 +68,6 @@ void Settings::setFullscreen(bool new_val)
emit fullscreenChanged();
}

void Settings::callScripts()
{
using ScriptEvent = ScriptRunner::EventType;
ScriptRunner::findAndRunScripts(ScriptEvent::CONFIG_CHANGED);
ScriptRunner::findAndRunScripts(ScriptEvent::SETTINGS_CHANGED);
}

QStringList Settings::gameDirs() const
{
QSet<QString> dirset;
Expand Down
3 changes: 0 additions & 3 deletions src/backend/model/settings/Settings.h
Original file line number Diff line number Diff line change
Expand Up @@ -57,9 +57,6 @@ class Settings : public QObject {
void fullscreenChanged();
void gameDirsChanged();

private slots:
void callScripts();

private:
LocaleList m_locales;
ThemeList m_themes;
Expand Down

0 comments on commit 4175609

Please sign in to comment.