don't append trailing tab to items which don't have stock accels
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@41214 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -171,20 +171,16 @@ wxString wxGetStockLabel(wxWindowID id, long flags)
|
|||||||
|
|
||||||
if ( !(flags & wxSTOCK_WITH_MNEMONIC) )
|
if ( !(flags & wxSTOCK_WITH_MNEMONIC) )
|
||||||
{
|
{
|
||||||
stockLabel = wxStripMenuCodes( stockLabel );
|
stockLabel = wxStripMenuCodes(stockLabel);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if wxUSE_ACCEL
|
#if wxUSE_ACCEL
|
||||||
|
if ( !stockLabel.empty() && (flags & wxSTOCK_WITH_ACCELERATOR) )
|
||||||
if (!stockLabel.empty() && (flags & wxSTOCK_WITH_ACCELERATOR))
|
|
||||||
{
|
{
|
||||||
stockLabel += _T("\t");
|
|
||||||
|
|
||||||
wxAcceleratorEntry accel = wxGetStockAccelerator(id);
|
wxAcceleratorEntry accel = wxGetStockAccelerator(id);
|
||||||
if (accel.IsOk())
|
if (accel.IsOk())
|
||||||
stockLabel += accel.ToString();
|
stockLabel << _T('\t') << accel.ToString();
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // wxUSE_ACCEL
|
#endif // wxUSE_ACCEL
|
||||||
|
|
||||||
return stockLabel;
|
return stockLabel;
|
||||||
|
Reference in New Issue
Block a user