CWorld: Make use of std::move in SetName()
Allows calling code to avoid copies.
This commit is contained in:
parent
e18e73cca5
commit
c9270b65ed
|
@ -123,7 +123,7 @@ public:
|
||||||
CStringTable* AreaName(uint32 AreaIndex) const { return mAreas[AreaIndex].pAreaName; }
|
CStringTable* AreaName(uint32 AreaIndex) const { return mAreas[AreaIndex].pAreaName; }
|
||||||
bool DoesAreaAllowPakDuplicates(uint32 AreaIndex) const { return mAreas[AreaIndex].AllowPakDuplicates; }
|
bool DoesAreaAllowPakDuplicates(uint32 AreaIndex) const { return mAreas[AreaIndex].AllowPakDuplicates; }
|
||||||
|
|
||||||
void SetName(const TString& rkName) { mName = rkName; }
|
void SetName(TString rkName) { mName = std::move(rkName); }
|
||||||
void SetAreaAllowsPakDuplicates(uint32 AreaIndex, bool Allow) { mAreas[AreaIndex].AllowPakDuplicates = Allow; }
|
void SetAreaAllowsPakDuplicates(uint32 AreaIndex, bool Allow) { mAreas[AreaIndex].AllowPakDuplicates = Allow; }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue