use more clear messaage about the custom labels in message box test
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@55480 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -653,18 +653,29 @@ void MyFrame::LogDialog(wxCommandEvent& WXUNUSED(event))
|
|||||||
void MyFrame::MessageBox(wxCommandEvent& WXUNUSED(event) )
|
void MyFrame::MessageBox(wxCommandEvent& WXUNUSED(event) )
|
||||||
{
|
{
|
||||||
wxMessageDialog dialog(this,
|
wxMessageDialog dialog(this,
|
||||||
_T("This is a message box\nA long, long string to test out the message box properly"),
|
"This is a message box\n"
|
||||||
_T("Message box text"),
|
"A long, long string to test out the message box "
|
||||||
|
"layout properly.",
|
||||||
|
"Message box text",
|
||||||
wxCENTER | wxNO_DEFAULT | wxYES_NO | wxCANCEL | wxICON_INFORMATION);
|
wxCENTER | wxNO_DEFAULT | wxYES_NO | wxCANCEL | wxICON_INFORMATION);
|
||||||
|
|
||||||
if ( dialog.SetYesNoLabels(_T("Answer &Yes"),_T("Answer &No")) )
|
wxString extmsg;
|
||||||
|
if ( dialog.SetYesNoCancelLabels
|
||||||
|
(
|
||||||
|
"Answer &Yes",
|
||||||
|
"Answer &No",
|
||||||
|
"Refuse to answer"
|
||||||
|
) )
|
||||||
{
|
{
|
||||||
dialog.SetExtendedMessage(_T("This platform supports custom button labels"));
|
extmsg = "This platform supports custom button labels,\n"
|
||||||
|
"so you should see the descriptiva text below.";
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
dialog.SetExtendedMessage(_T("Custom button labels are not supported."));
|
extmsg = "Custom button labels are not supported on this platform,\n"
|
||||||
|
"so the default \"Yes\"/\"No\"/\"Cancel\" buttons are used.";
|
||||||
}
|
}
|
||||||
|
dialog.SetExtendedMessage(extmsg);
|
||||||
|
|
||||||
switch ( dialog.ShowModal() )
|
switch ( dialog.ShowModal() )
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user