Changeset View
Changeset View
Standalone View
Standalone View
source/gui/CGUISetting.h
Show First 20 Lines • Show All 49 Lines • ▼ Show 20 Lines | |||||
}; | }; | ||||
template<typename T> | template<typename T> | ||||
class CGUISetting : public IGUISetting | class CGUISetting : public IGUISetting | ||||
{ | { | ||||
public: | public: | ||||
NONCOPYABLE(CGUISetting); | NONCOPYABLE(CGUISetting); | ||||
CGUISetting(IGUIObject& pObject, const CStr& Name); | template<typename... Args> | ||||
CGUISetting(IGUIObject& pObject, const CStr& Name, Args&&... args) | |||||
: m_pSetting(T(std::move(args)...)), m_Name(Name), m_pObject(pObject) | |||||
{ | |||||
} | |||||
/** | /** | ||||
* Parses the given string and assigns to the setting value. Used for parsing XML attributes. | * Parses the given string and assigns to the setting value. Used for parsing XML attributes. | ||||
*/ | */ | ||||
bool FromString(const CStrW& Value, const bool SendMessage) override; | bool FromString(const CStrW& Value, const bool SendMessage) override; | ||||
/** | /** | ||||
* Parses the given JS::Value using ScriptInterface::FromJSVal and assigns it to the setting data. | * Parses the given JS::Value using ScriptInterface::FromJSVal and assigns it to the setting data. | ||||
Show All 30 Lines |
Wildfire Games · Phabricator