wxwidgets.cfg: Added support for wxSizer::Add().

This commit is contained in:
orbitcowboy 2018-11-22 14:04:22 +01:00
parent d6c85118a7
commit 428d0147bc
2 changed files with 39 additions and 0 deletions

View File

@ -937,6 +937,25 @@
<not-uninit/>
</arg>
</function>
<!-- wxSizerItem* wxSizer::Add ( wxWindow * window, int proportion = 0, int flag = 0, int border = 0, wxObject * userData = NULL) -->
<function name="wxSizer::Add,wxBoxSizer::Add,wxGridSizer::Add,wxStaticBoxSizer::Add,wxStdDialogButtonSizer::Add,wxWrapSizer::Add,wxFlexGridSizer::Add,wxGridBagSizer::Add">
<noreturn>false</noreturn>
<leak-ignore/>
<returnValue type="wxSizerItem*"/>
<arg nr="1">
<not-null/>
</arg>
<arg nr="2" default="0">
<not-uninit/>
</arg>
<arg nr="3" default="0">
<not-uninit/>
</arg>
<arg nr="4" default="0">
<not-uninit/>
</arg>
<arg nr="5" default="NULL"/>
</function>
<!-- http://docs.wxwidgets.org/3.1/classwx_box_sizer.html#a58007d1fd88698b9f733ba651977ad55 -->
<!-- virtual wxSize wxBoxSizer::CalcMin()-->
<function name="wxBoxSizer::CalcMin">

View File

@ -21,6 +21,7 @@
#include <wx/frame.h>
#include <wx/menu.h>
#include <wx/stattext.h>
#include <wx/sizer.h>
void validCode()
{
@ -77,7 +78,26 @@ void nullPointer(const wxString &str)
unsigned long long * ulongLongPtr = NULL;
// cppcheck-suppress nullPointer
(void)str.ToULongLong(ulongLongPtr);
}
void nullPointer_wxSizer_Add(wxSizer &sizer, wxWindow *w)
{
wxWindow * const ptr = 0;
// cppcheck-suppress nullPointer
sizer.Add(ptr);
// No warning shall be issued for
sizer.Add(w);
}
void uninitvar_wxSizer_Add(wxSizer &sizer, wxWindow *w,wxObject* userData )
{
int uninit;
// cppcheck-suppress uninitvar
sizer.Add(w,uninit);
// cppcheck-suppress uninitvar
sizer.Add(w,4,uninit);
// cppcheck-suppress uninitvar
sizer.Add(w,4,2,uninit,userData);
}
void ignoredReturnValue(const wxString &s)