44 #ifndef __CU_WIDGET_VALUE_H__
45 #define __CU_WIDGET_VALUE_H__
46 #include <cugl/base/CUBase.h>
47 #include <cugl/assets/CUJsonValue.h>
61 std::shared_ptr<JsonValue>
json;
65 #pragma mark Constructors
91 bool init(
const std::shared_ptr<JsonValue>
json) {
92 if (
json ==
nullptr) {
101 #pragma mark Static Constructors
109 static std::shared_ptr<WidgetValue>
alloc(std::shared_ptr<JsonValue>
json) {
110 std::shared_ptr<WidgetValue> result = std::make_shared<WidgetValue>();
111 return (result->init(
json) ? result :
nullptr);
115 #pragma mark Value Access
122 const std::shared_ptr<JsonValue>
getJson()
const {