mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 12:48:10 +00:00
LibConfig: Add removal/notifcation for keys
This commit is contained in:
parent
a4a89a63cb
commit
b97f9f8e17
4 changed files with 24 additions and 0 deletions
|
@ -60,6 +60,11 @@ void Client::write_bool(StringView domain, StringView group, StringView key, boo
|
|||
async_write_bool_value(domain, group, key, value);
|
||||
}
|
||||
|
||||
void Client::remove_key(StringView domain, StringView group, StringView key)
|
||||
{
|
||||
async_remove_key(domain, group, key);
|
||||
}
|
||||
|
||||
void Client::notify_changed_string_value(String const& domain, String const& group, String const& key, String const& value)
|
||||
{
|
||||
Listener::for_each([&](auto& listener) {
|
||||
|
@ -81,4 +86,11 @@ void Client::notify_changed_bool_value(String const& domain, String const& group
|
|||
});
|
||||
}
|
||||
|
||||
void Client::notify_removed_key(const String& domain, const String& group, const String& key)
|
||||
{
|
||||
Listener::for_each([&](auto& listener) {
|
||||
listener.config_key_was_removed(domain, group, key);
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue