Skip to content

Backport: Add header guards and clean up Button self-qualification (aeos)#153

Merged
livingkurt merged 1 commit intoaeosfrom
backport/152-cleanup-into-aeos
Mar 28, 2026
Merged

Backport: Add header guards and clean up Button self-qualification (aeos)#153
livingkurt merged 1 commit intoaeosfrom
backport/152-cleanup-into-aeos

Conversation

@livingkurt
Copy link
Copy Markdown
Collaborator

Summary

Port of master PR #152 cleanup changes to the aeos branch. These are the same underlying API files so the cleanups apply identically.

  • Add proper #ifndef/#define header guards to Button.h, Helios.h, ColorConstants.h, and Random.h (replacing #pragma once where used)
  • Rename Colortypes.h guard from COLOR_HCOLORTYPES_H to match the filename
  • Remove Helios::wakeup() from the embedded ISR (not used on embedded, was never needed)
  • Remove unnecessary Button:: self-qualification on static method calls within Button.cpp (holdPressing, processPreInput, processPostInput)
  • Extract repeated Time::getCurtime() calls into a const local variable in Button::update()
  • Move Led::setBrightness() out of inline in the header into Led.cpp
  • Remove commented-out dead include from Pattern.cpp
  • Remove unused Led.h include from TimeControl.cpp
  • Update TimeControl.h comments for clarity (remove stale singleton comment, improve API docs)

Test plan

  • CLI builds cleanly
  • Embedded builds cleanly

Made with Cursor

Port of master PR #152 cleanup changes to aeos branch:

- Add proper #ifndef/#define header guards to Button.h, Helios.h,
  ColorConstants.h, and Random.h (replacing #pragma once where used)
- Rename Colortypes.h guard from COLOR_H to COLORTYPES_H
- Remove Helios::wakeup() from ISR (not used on embedded)
- Remove unnecessary Button:: self-qualification on static method calls
  within Button.cpp (holdPressing, processPreInput, processPostInput)
- Extract repeated Time::getCurtime() calls into const local variable
  in Button::update()
- Move Led::setBrightness() out of inline into Led.cpp
- Remove commented-out include from Pattern.cpp
- Remove unused Led.h include from TimeControl.cpp
- Update TimeControl.h comments for clarity

Made-with: Cursor
@livingkurt livingkurt merged commit 9caa8c2 into aeos Mar 28, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants