Fix display of "const" methods in wxGTK assert dialog.
Don't separate the function name and its arguments types in 2 different columns in the assert dialog, this doesn't really work with const methods as "const" can't be separated from the function like this. The old code just didn't take "const" into account at all and mangled all the const methods by showing ") cons" (no typo) at the end. Just show everything in one column to avoid the problem and also simplify the code. Closes #14104. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@70954 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -304,25 +304,11 @@ protected:
|
||||
virtual void OnStackFrame(const wxStackFrame& frame)
|
||||
{
|
||||
wxString fncname = frame.GetName();
|
||||
wxString fncargs = fncname;
|
||||
|
||||
size_t n = fncname.find(wxT('('));
|
||||
if (n != wxString::npos)
|
||||
{
|
||||
// remove arguments from function name
|
||||
fncname.erase(n);
|
||||
|
||||
// remove function name and brackets from arguments
|
||||
fncargs = fncargs.substr(n+1, fncargs.length()-n-2);
|
||||
}
|
||||
else
|
||||
fncargs = wxEmptyString;
|
||||
|
||||
// append this stack frame's info in the dialog
|
||||
if (!frame.GetFileName().empty() || !fncname.empty())
|
||||
gtk_assert_dialog_append_stack_frame(m_dlg,
|
||||
fncname.mb_str(),
|
||||
fncargs.mb_str(),
|
||||
frame.GetFileName().mb_str(),
|
||||
frame.GetLine());
|
||||
}
|
||||
|
Reference in New Issue
Block a user