Micro optimization in wxStaticTextBase::UpdateLabel()
Avoid an unnecessary wxString copy.
This commit is contained in:
@@ -232,7 +232,7 @@ void wxStaticTextBase::UpdateLabel()
|
|||||||
if (!IsEllipsized())
|
if (!IsEllipsized())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
wxString newlabel = GetEllipsizedLabel();
|
const wxString& newlabel = GetEllipsizedLabel();
|
||||||
|
|
||||||
// we need to touch the "real" label (i.e. the text set inside the control,
|
// we need to touch the "real" label (i.e. the text set inside the control,
|
||||||
// using port-specific functions) instead of the string returned by GetLabel().
|
// using port-specific functions) instead of the string returned by GetLabel().
|
||||||
|
Reference in New Issue
Block a user