refactor(Core): apply clang-tidy modernize-use-default-member-init (#3827)

This commit is contained in:
Francesco Borzì
2020-12-07 20:34:06 +01:00
committed by GitHub
parent 1cf39b3d22
commit c5a35efd7b
47 changed files with 352 additions and 366 deletions

View File

@@ -33,11 +33,11 @@ namespace VMAP
class IVMapManager
{
private:
bool iEnableLineOfSightCalc;
bool iEnableHeightCalc;
bool iEnableLineOfSightCalc{true};
bool iEnableHeightCalc{true};
public:
IVMapManager() : iEnableLineOfSightCalc(true), iEnableHeightCalc(true) { }
IVMapManager() { }
virtual ~IVMapManager() = default;

View File

@@ -52,14 +52,14 @@ namespace VMAP
class ManagedModel
{
public:
ManagedModel() : iModel(nullptr), iRefCount(0) { }
ManagedModel() { }
void setModel(WorldModel* model) { iModel = model; }
WorldModel* getModel() { return iModel; }
void incRefCount() { ++iRefCount; }
int decRefCount() { return --iRefCount; }
protected:
WorldModel* iModel;
int iRefCount;
WorldModel* iModel{nullptr};
int iRefCount{0};
};
typedef std::unordered_map<uint32, StaticMapTree*> InstanceTreeMap;