}
sm_providers->Insert(provider);
+ sm_cache->Clear();
}
/*static*/ bool wxArtProvider::PopProvider()
wxCHECK_MSG( sm_providers, wxNullIcon, _T("no wxArtProvider exists") );
wxBitmap bmp = GetBitmap(id, client, size);
- if ( bmp.Ok() )
- {
- wxIcon icon;
- icon.CopyFromBitmap(bmp);
- return icon;
- }
- else
- {
+ if ( !bmp.Ok() )
return wxNullIcon;
- }
-}
+ wxIcon icon;
+ icon.CopyFromBitmap(bmp);
+ return icon;
+}
class wxArtProviderModule: public wxModule
{
public:
- bool OnInit() { return TRUE; }
- void OnExit() { wxArtProvider::CleanUpProviders(); }
+ bool OnInit()
+ {
+ wxArtProvider::InitStdProvider();
+ return TRUE;
+ }
+ void OnExit()
+ {
+ wxArtProvider::CleanUpProviders();
+ }
DECLARE_DYNAMIC_CLASS(wxArtProviderModule)
};