diff options
| author | Amlal El Mahrouss <amlal@nekernel.org> | 2025-11-19 19:41:49 +0100 |
|---|---|---|
| committer | Amlal El Mahrouss <amlal@nekernel.org> | 2025-11-19 19:41:49 +0100 |
| commit | 73adafc405eae26d9c65809ca5612967b8f534cb (patch) | |
| tree | 35ac20be06594c133c46dccb983049ebee7fc0a2 /lib/libsteps/steps.h | |
| parent | 712140303d88a0e7e689376c862954811623c5ae (diff) | |
feat: libsteps: improvements on the steps library.
Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'lib/libsteps/steps.h')
| -rw-r--r-- | lib/libsteps/steps.h | 47 |
1 files changed, 0 insertions, 47 deletions
diff --git a/lib/libsteps/steps.h b/lib/libsteps/steps.h deleted file mode 100644 index 357f0df..0000000 --- a/lib/libsteps/steps.h +++ /dev/null @@ -1,47 +0,0 @@ -/* ------------------------------------------- - -Copyright (C) 2025, Amlal El Mahrouss, licensed under the Apache 2.0 license. - -------------------------------------------- */ - -#pragma once - -#include <lib/core/includes.hpp> - -#define kSysStepsExtension ".stp" -#define kSysStepsStrLen (256U) - -#define kSysStepsMagic " pls" -#define kSysStepsMagicLen (4U) -#define kSysStepsVersion (0x0100) - -#define kStepsMime "ne-application-kind/steps" - -namespace steps { -struct record final { - char magic[kSysStepsMagicLen] = {kSysStepsMagic[0], kSysStepsMagic[1], - kSysStepsMagic[2], kSysStepsMagic[3]}; - char name[kSysStepsStrLen] = ""; - char company[kSysStepsStrLen] = ""; - char author[kSysStepsStrLen] = ""; - int32_t version = 0; - int32_t pages = 0; - int32_t check_page = 0, eula_page = 0; -}; - -namespace operators { -/// =========================================================== /// -/// @brief Equal operator for steps records. -/// =========================================================== /// -inline bool operator==(const record &r, const record &l) { - return (std::strncmp(r.magic, l.magic, kSysStepsMagicLen) == 0); -} - -/// =========================================================== /// -/// @brief Not equal operator for steps records. -/// =========================================================== /// -inline bool operator!=(const record &r, const record &l) { - return (std::strncmp(r.magic, l.magic, kSysStepsMagicLen) > 0); -} -} // namespace operators -} // namespace steps |
