Skip to content

Consolidate dialog boilerplate into AtlasBlockDialog#45

Merged
CoderJoeW merged 1 commit intomainfrom
consolidate-dialog-boilerplate
Mar 27, 2026
Merged

Consolidate dialog boilerplate into AtlasBlockDialog#45
CoderJoeW merged 1 commit intomainfrom
consolidate-dialog-boilerplate

Conversation

@CoderJoeW
Copy link
Copy Markdown
Owner

Summary

  • Add generic showBlockDialog() helper to AtlasBlockDialog that accepts display-name and body-builder lambdas, eliminating duplicated notice-dialog plumbing across subsystems
  • Remove redundant init(), cleanup(), and sendDialog() wrapper methods from PowerBlockDialog, FluidBlockDialog, and TransportBlockDialog
  • Collapse 3x init()/cleanup() calls in Atlas.kt into single AtlasBlockDialog.init()/cleanup() calls

Net result: -62 lines across 8 files, with each subsystem dialog reduced to pure content logic.

…sBlockDialog

Each subsystem dialog (Power, Fluid, Transport) duplicated identical init(),
cleanup(), and sendDialog() methods that just delegated to AtlasBlockDialog.
Add a generic showBlockDialog() helper that accepts display-name and body-builder
lambdas, letting each subsystem dialog become a pure content provider.
@CoderJoeW CoderJoeW merged commit f5d13cf into main Mar 27, 2026
3 checks passed
@CoderJoeW CoderJoeW deleted the consolidate-dialog-boilerplate branch March 27, 2026 05:21
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.

1 participant