From 63af846600e0467e6233a37691dfc9817e36c4c8 Mon Sep 17 00:00:00 2001 From: Leland Lucius Date: Sun, 14 Feb 2021 03:02:32 -0600 Subject: [PATCH] Reposition help button on Export dialog --- src/export/Export.cpp | 29 ++++++++++++++--------------- 1 file changed, 14 insertions(+), 15 deletions(-) diff --git a/src/export/Export.cpp b/src/export/Export.cpp index d6b5aea43..6cebc4def 100644 --- a/src/export/Export.cpp +++ b/src/export/Export.cpp @@ -50,6 +50,7 @@ #include "../widgets/FileDialog/FileDialog.h" +#include "../src/AllThemeResources.h" #include "../Mix.h" #include "../Prefs.h" #include "../prefs/ImportExportPrefs.h" @@ -59,6 +60,7 @@ #include "../ProjectWindow.h" #include "../ShuttleGui.h" #include "../Tags.h" +#include "../Theme.h" #include "../WaveTrack.h" #include "../widgets/AudacityMessageBox.h" #include "../widgets/Warning.h" @@ -964,38 +966,35 @@ void Exporter::CreateUserPane(wxWindow *parent) { ShuttleGui S(parent, eIsCreating); - S.StartVerticalLay(); + S.StartStatic(XO("Format Options"), 1); { S.StartHorizontalLay(wxEXPAND); { - S.StartStatic(XO("Format Options"), 1); + mBook = S.Position(wxEXPAND).StartSimplebook(); { - mBook = S.Position(wxEXPAND) - .StartSimplebook(); - for (const auto &pPlugin : mPlugins) { for (int j = 0; j < pPlugin->GetFormatCount(); j++) { // Name of simple book page is not displayed S.StartNotebookPage( {} ); - pPlugin->OptionsCreate(S, j); + { + pPlugin->OptionsCreate(S, j); + } S.EndNotebookPage(); } } - - S.EndSimplebook(); } - S.EndStatic(); + S.EndSimplebook(); + + auto b = safenew wxBitmapButton(S.GetParent(), wxID_HELP, theTheme.Bitmap( bmpHelpIcon )); + b->SetToolTip( XO("Help").Translation() ); + b->SetLabel(XO("Help").Translation()); // for screen readers + S.Position(wxALIGN_BOTTOM | wxRIGHT | wxBOTTOM).AddWindow(b); } S.EndHorizontalLay(); } - S.StartHorizontalLay(wxALIGN_RIGHT, 0); - { - S.AddStandardButtons(eHelpButton); - } - S.EndHorizontalLay(); - S.EndVerticalLay(); + S.EndStatic(); return; }