feat: track instance copies that use links

confirm deleations when other instances link to it

Signed-off-by: Rachel Powers <508861+Ryex@users.noreply.github.com>
This commit is contained in:
Rachel Powers
2023-02-15 22:01:27 -07:00
parent 3ec92acfe7
commit 1ca2c59f2e
11 changed files with 213 additions and 2 deletions

View File

@ -183,3 +183,21 @@ void INIFile::set(QString key, QVariant val)
{
this->operator[](key) = val;
}
void INIFile::setList(QString key, QVariantList val)
{
QString stringList = QJsonDocument(QVariant(val).toJsonArray()).toJson(QJsonDocument::Compact);
this->operator[](key) = stringList;
}
QVariantList INIFile::getList(QString key, QVariantList def) const
{
if (this->contains(key)) {
auto src = this->operator[](key);
return QJsonDocument::fromJson(src.toByteArray()).toVariant().toList();
}
return def;
}