From: Gilles Depeyrot Date: Fri, 3 May 2002 20:20:55 +0000 (+0000) Subject: corrected warnings when compiling with -Wall -W X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/9f081f02ead106131223cb8078713dbc7844e885 corrected warnings when compiling with -Wall -W git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@15353 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/generic/paletteg.cpp b/src/generic/paletteg.cpp index ce66f89140..336afdc2ba 100644 --- a/src/generic/paletteg.cpp +++ b/src/generic/paletteg.cpp @@ -72,6 +72,7 @@ wxPalette::wxPalette(int n, const unsigned char *red, const unsigned char *green } wxPalette::wxPalette(const wxPalette& palette) + : wxGDIObject() { Ref(palette); } diff --git a/src/generic/prop.cpp b/src/generic/prop.cpp index 028427d935..cca2ecdd45 100644 --- a/src/generic/prop.cpp +++ b/src/generic/prop.cpp @@ -47,6 +47,7 @@ wxPropertyValue::wxPropertyValue(void) } wxPropertyValue::wxPropertyValue(const wxPropertyValue& copyFrom) + : wxObject() { m_value.string = (wxChar*) NULL; m_modifiedFlag = FALSE; @@ -834,6 +835,7 @@ wxProperty::wxProperty(void) } wxProperty::wxProperty(wxProperty& copyFrom) + : wxObject() { m_value = copyFrom.GetValue(); m_name = copyFrom.GetName(); diff --git a/src/generic/spinctlg.cpp b/src/generic/spinctlg.cpp index b8c1f48b40..c0dca645a1 100644 --- a/src/generic/spinctlg.cpp +++ b/src/generic/spinctlg.cpp @@ -28,8 +28,8 @@ #pragma hdrstop #endif -#if !(defined(__WXMSW__) || defined(__WXGTK__) || defined(__WXPM__)) || defined(__WXMAC__) || \ - defined(__WXUNIVERSAL__) +#if !(defined(__WXMSW__) || defined(__WXGTK__) || defined(__WXPM__)) || \ + defined(__WXMAC__) || defined(__WXUNIVERSAL__) #ifndef WX_PRECOMP #include "wx/textctrl.h" @@ -134,7 +134,7 @@ BEGIN_EVENT_TABLE(wxSpinCtrlButton, wxSpinButton) END_EVENT_TABLE() IMPLEMENT_DYNAMIC_CLASS(wxSpinCtrl, wxControl) - + // ============================================================================ // implementation // ============================================================================ diff --git a/src/mac/carbon/listbox.cpp b/src/mac/carbon/listbox.cpp index 58cf2550c7..9a10e64d29 100644 --- a/src/mac/carbon/listbox.cpp +++ b/src/mac/carbon/listbox.cpp @@ -64,7 +64,6 @@ static pascal void wxMacListDefinition( short message, Boolean isSelected, Rect Cell cell, short dataOffset, short dataLength, ListHandle listHandle ) { - FontInfo fontInfo; GrafPtr savePort; GrafPtr grafPtr; RgnHandle savedClipRegion; @@ -681,10 +680,10 @@ void wxListBox::MacSetSelection( int n , bool select ) Cell cell = { 0 , 0 } ; if ( ! (m_windowStyle & wxLB_MULTIPLE) ) { - if ( LGetSelect( true , &cell , (ListHandle)m_macList ) ) - { - LSetSelect( false , cell , (ListHandle)m_macList ) ; - } + if ( LGetSelect( true , &cell , (ListHandle)m_macList ) ) + { + LSetSelect( false , cell , (ListHandle)m_macList ) ; + } } cell.v = n ; diff --git a/src/mac/carbon/pen.cpp b/src/mac/carbon/pen.cpp index 732889b467..bb60cfae65 100644 --- a/src/mac/carbon/pen.cpp +++ b/src/mac/carbon/pen.cpp @@ -32,6 +32,7 @@ wxPenRefData::wxPenRefData() } wxPenRefData::wxPenRefData(const wxPenRefData& data) + : wxGDIRefData() { m_style = data.m_style; m_width = data.m_width; diff --git a/src/mac/carbon/radiobut.cpp b/src/mac/carbon/radiobut.cpp index 0d060bdb95..7fcaaf579d 100644 --- a/src/mac/carbon/radiobut.cpp +++ b/src/mac/carbon/radiobut.cpp @@ -68,7 +68,6 @@ bool wxRadioButton::Create(wxWindow *parent, wxWindowID id, void wxRadioButton::SetValue(bool val) { - int i; wxRadioButton *cycle; if ( GetControlValue( (ControlHandle) m_macControl ) == val ) return ; diff --git a/src/mac/listbox.cpp b/src/mac/listbox.cpp index 58cf2550c7..9a10e64d29 100644 --- a/src/mac/listbox.cpp +++ b/src/mac/listbox.cpp @@ -64,7 +64,6 @@ static pascal void wxMacListDefinition( short message, Boolean isSelected, Rect Cell cell, short dataOffset, short dataLength, ListHandle listHandle ) { - FontInfo fontInfo; GrafPtr savePort; GrafPtr grafPtr; RgnHandle savedClipRegion; @@ -681,10 +680,10 @@ void wxListBox::MacSetSelection( int n , bool select ) Cell cell = { 0 , 0 } ; if ( ! (m_windowStyle & wxLB_MULTIPLE) ) { - if ( LGetSelect( true , &cell , (ListHandle)m_macList ) ) - { - LSetSelect( false , cell , (ListHandle)m_macList ) ; - } + if ( LGetSelect( true , &cell , (ListHandle)m_macList ) ) + { + LSetSelect( false , cell , (ListHandle)m_macList ) ; + } } cell.v = n ; diff --git a/src/mac/pen.cpp b/src/mac/pen.cpp index 732889b467..bb60cfae65 100644 --- a/src/mac/pen.cpp +++ b/src/mac/pen.cpp @@ -32,6 +32,7 @@ wxPenRefData::wxPenRefData() } wxPenRefData::wxPenRefData(const wxPenRefData& data) + : wxGDIRefData() { m_style = data.m_style; m_width = data.m_width; diff --git a/src/mac/radiobut.cpp b/src/mac/radiobut.cpp index 0d060bdb95..7fcaaf579d 100644 --- a/src/mac/radiobut.cpp +++ b/src/mac/radiobut.cpp @@ -68,7 +68,6 @@ bool wxRadioButton::Create(wxWindow *parent, wxWindowID id, void wxRadioButton::SetValue(bool val) { - int i; wxRadioButton *cycle; if ( GetControlValue( (ControlHandle) m_macControl ) == val ) return ;