Patch [ 584078 ] Misc samples fixes from Dimitri Schoolwerth
Addresses: printf-format warinigs indentation/style unused variable warnings used wxID_ABOUT for about menu entry removed references to "minimal sample" in other samples some other misc warinigs git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16345 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
		@@ -757,8 +757,7 @@ MyPanel::MyPanel( wxFrame *frame, int x, int y, int w, int h )
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
#if !defined(__WXMOTIF__) && !defined(__WIN16__)  // wxStaticBitmap not working under Motif yet; and icons not allowed under WIN16.
 | 
					#if !defined(__WXMOTIF__) && !defined(__WIN16__)  // wxStaticBitmap not working under Motif yet; and icons not allowed under WIN16.
 | 
				
			||||||
    wxIcon icon = wxArtProvider::GetIcon(wxART_INFORMATION);
 | 
					    wxIcon icon = wxArtProvider::GetIcon(wxART_INFORMATION);
 | 
				
			||||||
    wxStaticBitmap *bmpStatic = new wxStaticBitmap(panel, -1, icon,
 | 
					    (void) new wxStaticBitmap( panel, -1, icon, wxPoint(10, 10) );
 | 
				
			||||||
                                                   wxPoint(10, 10));
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
    // VZ: don't leak memory
 | 
					    // VZ: don't leak memory
 | 
				
			||||||
    // bmpStatic = new wxStaticBitmap(panel, -1, wxNullIcon, wxPoint(50, 10));
 | 
					    // bmpStatic = new wxStaticBitmap(panel, -1, wxNullIcon, wxPoint(50, 10));
 | 
				
			||||||
@@ -1254,8 +1253,8 @@ void MyPanel::OnSpinCtrlText(wxCommandEvent& event)
 | 
				
			|||||||
    if ( m_spinctrl )
 | 
					    if ( m_spinctrl )
 | 
				
			||||||
    {
 | 
					    {
 | 
				
			||||||
        wxString s;
 | 
					        wxString s;
 | 
				
			||||||
        s.Printf(_T("Spin ctrl text changed: now %d (from event: %s)\n"),
 | 
					        s.Printf( _T("Spin ctrl text changed: now %d (from event: %s)\n"),
 | 
				
			||||||
                 m_spinctrl->GetValue(), event.GetString());
 | 
					                 m_spinctrl->GetValue(), event.GetString().c_str() );
 | 
				
			||||||
        m_text->AppendText(s);
 | 
					        m_text->AppendText(s);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
@@ -1265,8 +1264,8 @@ void MyPanel::OnSpinCtrl(wxSpinEvent& event)
 | 
				
			|||||||
    if ( m_spinctrl )
 | 
					    if ( m_spinctrl )
 | 
				
			||||||
    {
 | 
					    {
 | 
				
			||||||
        wxString s;
 | 
					        wxString s;
 | 
				
			||||||
        s.Printf(_T("Spin ctrl changed: now %d (from event: %d)\n"),
 | 
					        s.Printf( _T("Spin ctrl changed: now %d (from event: %ld)\n"),
 | 
				
			||||||
                 m_spinctrl->GetValue(), event.GetInt());
 | 
					                 m_spinctrl->GetValue(), event.GetInt() );
 | 
				
			||||||
        m_text->AppendText(s);
 | 
					        m_text->AppendText(s);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
@@ -1275,8 +1274,9 @@ void MyPanel::OnSpinCtrlUp(wxSpinEvent& event)
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
    if ( m_spinctrl )
 | 
					    if ( m_spinctrl )
 | 
				
			||||||
    {
 | 
					    {
 | 
				
			||||||
        m_text->AppendText(wxString::Format(_T("Spin up: %d (from event: %d)\n"),
 | 
					        m_text->AppendText( wxString::Format(
 | 
				
			||||||
                           m_spinctrl->GetValue(), event.GetInt()));
 | 
					            _T("Spin up: %d (from event: %ld)\n"),
 | 
				
			||||||
 | 
					            m_spinctrl->GetValue(), event.GetInt() ) );
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@@ -1284,8 +1284,9 @@ void MyPanel::OnSpinCtrlDown(wxSpinEvent& event)
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
    if ( m_spinctrl )
 | 
					    if ( m_spinctrl )
 | 
				
			||||||
    {
 | 
					    {
 | 
				
			||||||
        m_text->AppendText(wxString::Format(_T("Spin down: %d (from event: %d)\n"),
 | 
					        m_text->AppendText( wxString::Format(
 | 
				
			||||||
                           m_spinctrl->GetValue(), event.GetInt()));
 | 
					            _T("Spin down: %d (from event: %ld)\n"),
 | 
				
			||||||
 | 
					            m_spinctrl->GetValue(), event.GetInt() ) );
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -1760,7 +1760,7 @@ void DnDShapeFrame::OnDrop(wxCoord x, wxCoord y, DnDShape *shape)
 | 
				
			|||||||
    wxPoint pt(x, y);
 | 
					    wxPoint pt(x, y);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    wxString s;
 | 
					    wxString s;
 | 
				
			||||||
    s.Printf(wxT("Shape dropped at (%ld, %ld)"), pt.x, pt.y);
 | 
					    s.Printf(wxT("Shape dropped at (%d, %d)"), pt.x, pt.y);
 | 
				
			||||||
    SetStatusText(s);
 | 
					    SetStatusText(s);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    shape->Move(pt);
 | 
					    shape->Move(pt);
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user