Skip to content

[spots] Restore custom spot colors on launch#1133

Merged
ten9876 merged 1 commit into
aethersdr:mainfrom
jensenpat:bug/custom-spot-color-reload
Apr 11, 2026
Merged

[spots] Restore custom spot colors on launch#1133
ten9876 merged 1 commit into
aethersdr:mainfrom
jensenpat:bug/custom-spot-color-reload

Conversation

@jensenpat

Copy link
Copy Markdown
Collaborator

Summary

  • restore saved custom spot text/background colors and opacity when wiring each spectrum widget at launch
  • ensure custom spot appearance matches the saved Spot settings immediately after app startup

Root Cause

The startup path restored the override booleans but did not reapply the saved custom spot colors and background opacity to newly created spectrum widgets, so they fell back to defaults until a later refresh path ran.

Validation

  • confirmed the fix locally in the worktree
  • user reports this fix is working

@jensenpat jensenpat changed the title [codex] Restore custom spot colors on launch [spots] Restore custom spot colors on launch Apr 10, 2026
@jensenpat jensenpat marked this pull request as ready for review April 10, 2026 17:30
@jensenpat jensenpat requested a review from ten9876 as a code owner April 10, 2026 17:30

@aethersdr-agent aethersdr-agent Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good fix — clean, minimal, and exactly right.

The three new lines slot neatly into the existing { auto& s = AppSettings::instance(); ... } block in wirePanadapter(), so they share the same settings reference and stay inside the same scope as the surrounding restore calls. Key names (SpotsOverrideColor, SpotsOverrideBgColor, SpotsBackgroundOpacity) and defaults (#FFFF00, #000000, 48) match exactly what SpotSettingsDialog and DxClusterDialog write, so round-trip fidelity is correct.

No null-pointer risk beyond what sw already assumes (the pointer is dereferenced unconditionally at line 4892, so the new calls are consistent with existing behavior). No scope creep — only MainWindow.cpp, only the startup restore path.

Thanks for tracking this down and submitting a focused fix, @jensenpat!

@ten9876 ten9876 merged commit e275b2a into aethersdr:main Apr 11, 2026
5 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