diff options
author | Daniel Wilhelm <shieldwed@outlook.com> | 2016-10-29 11:41:53 +0200 |
---|---|---|
committer | Daniel Wilhelm <shieldwed@outlook.com> | 2016-10-29 11:41:53 +0200 |
commit | 7302bb4484d517a72cdffbd13ec7a9f2324cde01 (patch) | |
tree | 17d2964c6768d49510206836a496fb1802a63e08 /wx+/image_resources.cpp | |
parent | 8.5 (diff) | |
download | FreeFileSync-7302bb4484d517a72cdffbd13ec7a9f2324cde01.tar.gz FreeFileSync-7302bb4484d517a72cdffbd13ec7a9f2324cde01.tar.bz2 FreeFileSync-7302bb4484d517a72cdffbd13ec7a9f2324cde01.zip |
8.6
Diffstat (limited to 'wx+/image_resources.cpp')
-rw-r--r-- | wx+/image_resources.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/wx+/image_resources.cpp b/wx+/image_resources.cpp index 110539e7..3eb91ee4 100644 --- a/wx+/image_resources.cpp +++ b/wx+/image_resources.cpp @@ -49,7 +49,7 @@ public: static std::shared_ptr<GlobalBitmaps> instance() { static Global<GlobalBitmaps> inst(std::make_unique<GlobalBitmaps>()); - assert(std::this_thread::get_id() == mainThreadId); //wxWidgets is not thread-safe! + assert(std::this_thread::get_id() == mainThreadId); //wxWidgets is not thread-safe! return inst.get(); } @@ -137,35 +137,35 @@ const wxAnimation& GlobalBitmaps::getAnimation(const wxString& name) const void zen::initResourceImages(const Zstring& filepath) { - if (std::shared_ptr<GlobalBitmaps> inst = GlobalBitmaps::instance()) - inst->init(filepath); - else - assert(false); + if (std::shared_ptr<GlobalBitmaps> inst = GlobalBitmaps::instance()) + inst->init(filepath); + else + assert(false); } -void zen::cleanupResourceImages() +void zen::cleanupResourceImages() { - if (std::shared_ptr<GlobalBitmaps> inst = GlobalBitmaps::instance()) - inst->cleanup(); - else - assert(false); + if (std::shared_ptr<GlobalBitmaps> inst = GlobalBitmaps::instance()) + inst->cleanup(); + else + assert(false); } -const wxBitmap& zen::getResourceImage(const wxString& name) +const wxBitmap& zen::getResourceImage(const wxString& name) { - if (std::shared_ptr<GlobalBitmaps> inst = GlobalBitmaps::instance()) - return inst->getImage(name); + if (std::shared_ptr<GlobalBitmaps> inst = GlobalBitmaps::instance()) + return inst->getImage(name); assert(false); return wxNullBitmap; } -const wxAnimation& zen::getResourceAnimation(const wxString& name) +const wxAnimation& zen::getResourceAnimation(const wxString& name) { - if (std::shared_ptr<GlobalBitmaps> inst = GlobalBitmaps::instance()) - return inst->getAnimation(name); + if (std::shared_ptr<GlobalBitmaps> inst = GlobalBitmaps::instance()) + return inst->getAnimation(name); assert(false); return wxNullAnimation; } |