diff options
author | Dimitri van Heesch <doxygen@gmail.com> | 2020-08-02 12:24:52 (GMT) |
---|---|---|
committer | Dimitri van Heesch <doxygen@gmail.com> | 2020-08-02 12:24:52 (GMT) |
commit | 4f18ae106a216a465713a0c7be78105419146881 (patch) | |
tree | db61b0cb3a8e97d0f68eb86d86593f17996cf8f0 /src/resourcemgr.h | |
parent | 713a6167733e660dcdfd48a36134576aaa8b80d3 (diff) | |
download | Doxygen-4f18ae106a216a465713a0c7be78105419146881.zip Doxygen-4f18ae106a216a465713a0c7be78105419146881.tar.gz Doxygen-4f18ae106a216a465713a0c7be78105419146881.tar.bz2 |
Modernize code for the resource manager
Diffstat (limited to 'src/resourcemgr.h')
-rw-r--r-- | src/resourcemgr.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/resourcemgr.h b/src/resourcemgr.h index 1959ec4..2d7ad9b 100644 --- a/src/resourcemgr.h +++ b/src/resourcemgr.h @@ -15,6 +15,9 @@ #ifndef RESOURCEMGR_H #define RESOURCEMGR_H +#include <memory> +#include <initializer_list> + #include <qcstring.h> /** @brief Compiled resource */ @@ -36,7 +39,7 @@ class ResourceMgr static ResourceMgr &instance(); /** Registers an array of resources */ - void registerResources(const Resource resources[],int numResources); + void registerResources(std::initializer_list<Resource> resources); /** Writes all resource belonging to a given category to a given target directory */ bool writeCategory(const char *categoryName,const char *targetDir) const; @@ -57,7 +60,7 @@ class ResourceMgr ResourceMgr(); ~ResourceMgr(); class Private; - Private *p; + std::unique_ptr<Private> p; }; #endif |