]> git.saurik.com Git - wxWidgets.git/commitdiff
DP: GetBitmap() added to wxImageList
authorDenis Pershin <dyp@inetlab.com>
Mon, 10 Aug 1998 18:09:07 +0000 (18:09 +0000)
committerDenis Pershin <dyp@inetlab.com>
Mon, 10 Aug 1998 18:09:07 +0000 (18:09 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@496 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/generic/imaglist.h
src/generic/imaglist.cpp

index 72ce155305c8d667187bd55ed01913962a92f220..d13864cbbf914f2f1af7334de8717012630fc971 100644 (file)
@@ -59,6 +59,7 @@ class wxImageList: public wxObject
     bool Create();
     int GetImageCount() const;
     int Add( const wxBitmap &bitmap );
+    wxBitmap *GetBitmap(int index);
     bool Replace( int index, const wxBitmap &bitmap );
     bool Remove( int index );
     bool RemoveAll();
index 61819c387aba02e92c09219ef7e689ce7cca33ad..1629c414d97d2c559cc9ec4dce5a6ec81f8f374f 100644 (file)
@@ -48,6 +48,11 @@ int wxImageList::Add( const wxBitmap &bitmap )
   return m_images.Number();
 };
 
+wxBitmap *wxImageList::GetBitmap(int index) {
+  wxNode *node = m_images.Nth( index );
+  return (wxBitmap*)node->Data();
+}
+    
 bool wxImageList::Replace( int index, const wxBitmap &bitmap )
 {
   wxNode *node = m_images.Nth( index );