X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/526954c5968baa29218c994ec48e476ae2bd4b9f..31fda0c2cfb6843a98271fc3eb60022db4630925:/samples/widgets/bmpcombobox.cpp diff --git a/samples/widgets/bmpcombobox.cpp b/samples/widgets/bmpcombobox.cpp index 8fa31d0568..f1d0dbfa26 100644 --- a/samples/widgets/bmpcombobox.cpp +++ b/samples/widgets/bmpcombobox.cpp @@ -4,7 +4,6 @@ // Purpose: Part of the widgets sample showing wxBitmapComboBox // Author: Jaakko Salli // Created: Sep-01-2006 -// Id: $Id$ // Copyright: (c) 2006 Jaakko Salli // Licence: wxWindows licence ///////////////////////////////////////////////////////////////////////////// @@ -486,7 +485,7 @@ void BitmapComboBoxWidgetsPage::CreateCombo() m_sizerCombo->Add(m_combobox, 0, wxGROW | wxALL, 5); m_sizerCombo->Layout(); - // Allow changing height inorder to demonstrate flexible + // Allow changing height in order to demonstrate flexible // size of image "thumbnail" painted in the control itself. long h = 0; m_textChangeHeight->GetValue().ToLong(&h); @@ -712,10 +711,10 @@ void BitmapComboBoxWidgetsPage::LoadWidgetImages( wxArrayString* strings, wxImag #if wxUSE_IMAGE wxASSERT(fn.FileExists()); wxImage image(fn.GetFullPath()); - wxASSERT(image.Ok()); + wxASSERT(image.IsOk()); RescaleImage(image, foundSize.x, foundSize.y); wxBitmap bmp(image); - wxASSERT( bmp.Ok() ); + wxASSERT( bmp.IsOk() ); #else wxBitmap bmp(wxNullBitmap); #endif @@ -803,7 +802,7 @@ void BitmapComboBoxWidgetsPage::OnComboText(wxCommandEvent& event) wxASSERT_MSG( s == m_combobox->GetValue(), wxT("event and combobox values should be the same") ); - if (event.GetEventType() == wxEVT_COMMAND_TEXT_ENTER) + if (event.GetEventType() == wxEVT_TEXT_ENTER) { wxLogMessage(wxT("BitmapCombobox enter pressed (now '%s')"), s.c_str()); } @@ -842,7 +841,7 @@ wxBitmap BitmapComboBoxWidgetsPage::LoadBitmap(const wxString& filepath) } wxImage image(filepath); - if ( image.Ok() ) + if ( image.IsOk() ) { // Rescale very large images int ow = image.GetWidth(); @@ -884,7 +883,7 @@ wxBitmap BitmapComboBoxWidgetsPage::QueryBitmap(wxString* pStr) ::wxSetCursor( *wxHOURGLASS_CURSOR ); - if ( filepath.length() ) + if ( !filepath.empty() ) { if ( pStr ) {