Skip to content

PersistentDialog migrations: four remaining dialogs + wasFresh comment polish #2679

Description

@ten9876

Background

PR #2676 (closes #2672) migrated 7 dialogs to PersistentDialog. Four QDialog-based holdouts remain in MainWindow::setFramelessWindow() and a couple of minor polish items came out of the review.

Remaining dialog migrations

These four dialogs are still on bare QDialog and still need explicit qobject_cast<> branches in MainWindow::setFramelessWindow() to receive the frameless toggle:

Dialog File Notes
ProfileImportExportDialog src/gui/ProfileImportExportDialog.{cpp,h} The single straggler explicitly called out in MainWindow.cpp:11586-11589 as a "#2605 follow-up" — finish it.
RadioSetupDialog src/gui/RadioSetupDialog.{cpp,h} Large dialog, lots of tabs — apply the same recipe (#2672) — risk-order this last.
PropDashboardDialog src/gui/PropDashboardDialog.{cpp,h} Standard migration.
TxBandDialog src/gui/TxBandDialog.{cpp,h} Wired via setDialogFramelessMode helper today; should switch to the registry-based propagation after migration.

After migrating all four, the explicit-cast block at MainWindow.cpp:11541-11597 collapses entirely — every frameless-propagation goes through m_persistentDialogs.

Recipe is the same one from #2672 — change base class, retype the QPointer<> member, replace the construct site with showOrRaisePersistent(), drop the explicit cast in setFramelessWindow().

Minor polish — wasFresh pattern comment

The new wasFresh capture in MainWindow.cpp (e.g. showMemoryDialog, DxClusterDialog callsite) is correct but cryptic on first read — capture state before showOrRaisePersistent because the slot may mutate during the call. A one-line comment near the first use would help future readers:

// Capture before showOrRaisePersistent — it may create the dialog and
// mutate the slot.  We use the captured flag to attach signals exactly
// once on creation.
const bool wasFresh = !m_memoryDialog;
showOrRaisePersistent(m_memoryDialog, &m_radioModel);
if (wasFresh && m_memoryDialog) { /* wire signals */ }

Pickup

All four are AetherClaude-eligible — mechanical, well-scoped, single-dialog PRs guided by the same recipe. ProfileImportExportDialog is the natural first one (it's the single remaining #2605 follow-up comment in setFramelessWindow). RadioSetupDialog last given its size.

73, Jeremy KK7GWY & Claude (AI dev partner)

Metadata

Metadata

Assignees

No one assigned

    Labels

    GUIUser interfaceenhancementImprovement to existing featuremaintainer-reviewRequires maintainer review before any action is taken

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions