shadPS4/src/qt_gui/gui_settings.cpp
raziel1000 ca6f582ea8 - Gui rewrite.
- Gui: Bug fixes and cleanup.
- Gui: Performance improvement (loading, resizing...etc)
- Added a simple PKG Viewer(Settings-> Utils -> PKG Viewer), added pkg folders will be saved.
- PKG Viewer: Shows game info(name, id, region...etc)
- PKG Viewer: Right click -> Install PKG to install/extract a game. Patch installation is also possible.
- Added option to dump game list  (Settings -> Utils -> Dump Game List), will be dumped to emu folder GameList.txt
2024-03-28 23:43:46 -06:00

24 lines
832 B
C++

// SPDX-FileCopyrightText: Copyright 2024 shadPS4 Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later
#include "gui_settings.h"
GuiSettings::GuiSettings(QObject* parent) {
m_settings.reset(new QSettings("shadps4qt.ini", QSettings::Format::IniFormat,
parent)); // TODO make the path configurable
}
void GuiSettings::SetGamelistColVisibility(int col, bool val) const {
SetValue(GetGuiSaveForColumn(col), val);
}
bool GuiSettings::GetGamelistColVisibility(int col) const {
return GetValue(GetGuiSaveForColumn(col)).toBool();
}
GuiSave GuiSettings::GetGuiSaveForColumn(int col) {
return GuiSave{gui::game_list,
"visibility_" +
gui::get_game_list_column_name(static_cast<gui::game_list_columns>(col)),
true};
}