mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-02-21 15:14:13 +00:00
LibCore: Add ConfigFile::get_for_lib()
This commit is contained in:
committed by
Andreas Kling
parent
1176865276
commit
afbeb8f977
@@ -34,6 +34,14 @@
|
||||
|
||||
namespace Core {
|
||||
|
||||
NonnullRefPtr<ConfigFile> ConfigFile::get_for_lib(const String& lib_name)
|
||||
{
|
||||
String directory = StandardPaths::config_directory();
|
||||
auto path = String::format("%s/lib/%s.ini", directory.characters(), lib_name.characters());
|
||||
|
||||
return adopt(*new ConfigFile(path));
|
||||
}
|
||||
|
||||
NonnullRefPtr<ConfigFile> ConfigFile::get_for_app(const String& app_name)
|
||||
{
|
||||
String directory = StandardPaths::config_directory();
|
||||
|
||||
Reference in New Issue
Block a user