2010-01-23 19:44:49 +00:00
|
|
|
/**********************************************************************
|
|
|
|
|
|
|
|
Audacity: A Digital Audio Editor
|
|
|
|
|
|
|
|
AboutDialog.h
|
|
|
|
|
|
|
|
Dominic Mazzoni
|
|
|
|
|
|
|
|
**********************************************************************/
|
|
|
|
|
|
|
|
#ifndef __AUDACITY_ABOUT_DLG__
|
|
|
|
#define __AUDACITY_ABOUT_DLG__
|
|
|
|
|
2016-02-13 16:20:14 +00:00
|
|
|
#include <vector>
|
2019-03-30 19:06:57 +00:00
|
|
|
#include "widgets/wxPanelWrapper.h" // to inherit
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2018-11-14 20:23:25 +00:00
|
|
|
class wxStaticBitmap;
|
2019-12-24 19:47:12 +00:00
|
|
|
class wxTextOutputStream;
|
2018-11-14 20:23:25 +00:00
|
|
|
|
2015-06-18 14:24:36 +00:00
|
|
|
class ShuttleGui;
|
2010-01-23 19:44:49 +00:00
|
|
|
|
|
|
|
struct AboutDialogCreditItem {
|
2019-12-14 17:53:59 +00:00
|
|
|
AboutDialogCreditItem( TranslatableString str, int r )
|
|
|
|
: description{ std::move( str ) }, role{ r }
|
2016-02-13 16:20:14 +00:00
|
|
|
{}
|
2019-12-14 17:53:59 +00:00
|
|
|
TranslatableString description;
|
|
|
|
int role;
|
2010-01-23 19:44:49 +00:00
|
|
|
};
|
|
|
|
|
2016-02-13 16:20:14 +00:00
|
|
|
using AboutDialogCreditItemsList = std::vector<AboutDialogCreditItem>;
|
2010-01-23 19:44:49 +00:00
|
|
|
|
2020-09-28 12:50:18 +00:00
|
|
|
class AUDACITY_DLL_API AboutDialog final : public wxDialogWrapper {
|
2010-01-23 19:44:49 +00:00
|
|
|
DECLARE_DYNAMIC_CLASS(AboutDialog)
|
|
|
|
|
|
|
|
public:
|
|
|
|
AboutDialog(wxWindow * parent);
|
|
|
|
virtual ~ AboutDialog();
|
|
|
|
|
2016-06-20 23:12:03 +00:00
|
|
|
static AboutDialog *ActiveIntance();
|
|
|
|
|
2010-01-23 19:44:49 +00:00
|
|
|
void OnOK(wxCommandEvent & event);
|
|
|
|
|
|
|
|
wxStaticBitmap *icon;
|
|
|
|
|
2016-06-20 23:12:03 +00:00
|
|
|
DECLARE_EVENT_TABLE()
|
2014-06-03 20:30:19 +00:00
|
|
|
|
2010-01-23 19:44:49 +00:00
|
|
|
private:
|
|
|
|
enum Role {
|
2016-03-18 22:33:49 +00:00
|
|
|
roleTeamMember,
|
|
|
|
roleEmeritusTeam,
|
2017-08-31 16:54:49 +00:00
|
|
|
roleDeceased,
|
2010-01-23 19:44:49 +00:00
|
|
|
roleContributor,
|
2018-05-24 11:57:26 +00:00
|
|
|
roleGraphics,
|
2010-01-23 19:44:49 +00:00
|
|
|
roleLibrary,
|
|
|
|
roleThanks
|
|
|
|
};
|
2014-06-03 20:30:19 +00:00
|
|
|
|
2010-01-23 19:44:49 +00:00
|
|
|
AboutDialogCreditItemsList creditItems;
|
|
|
|
void PopulateAudacityPage( ShuttleGui & S );
|
|
|
|
void PopulateLicensePage( ShuttleGui & S );
|
|
|
|
void PopulateInformationPage (ShuttleGui & S );
|
|
|
|
|
|
|
|
void CreateCreditsList();
|
2019-12-14 17:53:59 +00:00
|
|
|
void AddCredit( const wxString &name, Role role );
|
|
|
|
void AddCredit( const wxString &name, TranslatableString format, Role role );
|
2010-01-23 19:44:49 +00:00
|
|
|
wxString GetCreditsByRole(AboutDialog::Role role);
|
|
|
|
|
2019-12-24 19:47:12 +00:00
|
|
|
void AddBuildinfoRow( wxTextOutputStream *str, const wxChar * libname,
|
2020-05-06 04:47:16 +00:00
|
|
|
const TranslatableString &libdesc, const TranslatableString &status);
|
2019-12-24 19:47:12 +00:00
|
|
|
void AddBuildinfoRow( wxTextOutputStream *str,
|
|
|
|
const TranslatableString &description, const wxChar *spec);
|
2010-01-23 19:44:49 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|