CDC Badge OS
Firmware for the CDC Badge v1.0 hardware security key
Loading...
Searching...
No Matches
SettingsHandlers.h File Reference
#include <cstdint>
#include <cstddef>

Go to the source code of this file.

Namespaces

namespace  cdc
namespace  cdc::hal
namespace  cdc::ui
 Centralized key-code constants for cdc_views.
namespace  cdc::ui::settings

Functions

void cdc::ui::settings::init (hal::IDisplay *display, hal::ISleepController *sleep, LockScreenView *lockScreen)
 Initializes shared dependencies used by the settings handlers.
void cdc::ui::settings::processPendingBadgeText ()
 Processes the next pending badge-text wizard step.
void cdc::ui::settings::onBrightnessSave (uint16_t value)
 Persists and applies selected backlight value.
void cdc::ui::settings::onBrightnessChange (uint16_t value)
 Applies backlight preview without persisting.
uint16_t cdc::ui::settings::brightnessStepCallback (uint16_t current, bool increasing)
 Returns adaptive brightness step size.
void cdc::ui::settings::onSleepIntervalSave (uint16_t value)
 Saves lock-screen sleep interval in minutes.
void cdc::ui::settings::onTimezoneSave (uint16_t value)
 Saves timezone offset and refreshes lock-screen clock.
void cdc::ui::settings::onDateConfirm (uint8_t day, uint8_t month, uint16_t year)
 Applies confirmed date to system time.
void cdc::ui::settings::onTimeConfirm (uint8_t hour, uint8_t minute)
 Applies confirmed time to system clock.
void cdc::ui::settings::onPinChangeComplete (bool success)
 Handles completion of PIN-change flow.
void cdc::ui::settings::startBadgeTextEdit ()
 Starts badge-text editing wizard.
void cdc::ui::settings::saveDisplayField (const char *key, const char *value)
 Saves one display text field to NVS.
bool cdc::ui::settings::loadDisplayField (const char *key, char *out, size_t outSize)
 Reads one display text field from NVS into the caller buffer.