mirror of
https://github.com/cookiengineer/audacity
synced 2025-08-16 08:34:10 +02:00
Re-fit the UpdateNoticeDialog to fix dialog size with wxGTK
This commit is contained in:
parent
23da17eef2
commit
9a07826cd2
@ -39,6 +39,7 @@ static const auto thirdParagraph =
|
|||||||
|
|
||||||
BEGIN_EVENT_TABLE(UpdateNoticeDialog, wxDialogWrapper)
|
BEGIN_EVENT_TABLE(UpdateNoticeDialog, wxDialogWrapper)
|
||||||
EVT_BUTTON(wxID_OK, UpdateNoticeDialog::OnOk)
|
EVT_BUTTON(wxID_OK, UpdateNoticeDialog::OnOk)
|
||||||
|
EVT_SIZE(UpdateNoticeDialog::OnSize)
|
||||||
END_EVENT_TABLE()
|
END_EVENT_TABLE()
|
||||||
|
|
||||||
IMPLEMENT_CLASS(UpdateNoticeDialog, wxDialogWrapper)
|
IMPLEMENT_CLASS(UpdateNoticeDialog, wxDialogWrapper)
|
||||||
@ -55,7 +56,7 @@ UpdateNoticeDialog::UpdateNoticeDialog(wxWindow* parent)
|
|||||||
{
|
{
|
||||||
S.AddSpace(0, 16);
|
S.AddSpace(0, 16);
|
||||||
|
|
||||||
S.StartHorizontalLay();
|
S.StartHorizontalLay(wxEXPAND, 0);
|
||||||
{
|
{
|
||||||
S.AddSpace(24, 0);
|
S.AddSpace(24, 0);
|
||||||
|
|
||||||
@ -104,7 +105,7 @@ UpdateNoticeDialog::UpdateNoticeDialog(wxWindow* parent)
|
|||||||
}
|
}
|
||||||
S.EndHorizontalLay();
|
S.EndHorizontalLay();
|
||||||
|
|
||||||
S.StartHorizontalLay(wxEXPAND, 0);
|
S.StartHorizontalLay(wxEXPAND);
|
||||||
{
|
{
|
||||||
S.AddSpace(1, 0, 1);
|
S.AddSpace(1, 0, 1);
|
||||||
|
|
||||||
@ -117,8 +118,9 @@ UpdateNoticeDialog::UpdateNoticeDialog(wxWindow* parent)
|
|||||||
|
|
||||||
S.EndVerticalLay();
|
S.EndVerticalLay();
|
||||||
|
|
||||||
Layout();
|
|
||||||
Fit();
|
Fit();
|
||||||
|
Layout();
|
||||||
|
|
||||||
Center();
|
Center();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -126,3 +128,9 @@ void UpdateNoticeDialog::OnOk(wxCommandEvent&)
|
|||||||
{
|
{
|
||||||
EndModal(wxOK);
|
EndModal(wxOK);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void UpdateNoticeDialog::OnSize(wxSizeEvent&)
|
||||||
|
{
|
||||||
|
Fit();
|
||||||
|
Layout();
|
||||||
|
}
|
||||||
|
@ -24,7 +24,8 @@ public:
|
|||||||
explicit UpdateNoticeDialog (wxWindow* parent);
|
explicit UpdateNoticeDialog (wxWindow* parent);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void OnOk (wxCommandEvent& event);
|
void OnOk (wxCommandEvent&);
|
||||||
|
void OnSize(wxSizeEvent&);
|
||||||
|
|
||||||
DECLARE_EVENT_TABLE ()
|
DECLARE_EVENT_TABLE ()
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user