2020-05-31 16:23:55 +03:00
|
|
|
|
/*
|
|
|
|
|
* Copyright (c) 2020, Hüseyin Aslıtürk <asliturk@hotmail.com>
|
|
|
|
|
*
|
2021-04-22 11:24:48 +03:00
|
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
2020-05-31 16:23:55 +03:00
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
|
|
#include <AK/JsonObject.h>
|
|
|
|
|
#include <LibKeyboard/CharacterMapData.h>
|
|
|
|
|
|
|
|
|
|
namespace Keyboard {
|
|
|
|
|
|
|
|
|
|
class CharacterMapFile {
|
|
|
|
|
|
|
|
|
|
public:
|
2023-12-16 17:19:34 +03:00
|
|
|
|
static ErrorOr<CharacterMapData> load_from_file(ByteString const& filename);
|
2020-05-31 16:23:55 +03:00
|
|
|
|
|
|
|
|
|
private:
|
2023-12-16 17:19:34 +03:00
|
|
|
|
static Vector<u32> read_map(JsonObject const& json, ByteString const& name);
|
2020-05-31 16:23:55 +03:00
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
}
|