namespace
{
+#define TOKEN_STRING(x) #x
+
const std::string KEYNAME_STYLES = "styles";
const std::string KEYNAME_TYPE = "type";
const std::string KEYNAME_ACTORS = "actors";
ret = ToString( value.Get<int>() );
break;
}
- case Property::UNSIGNED_INTEGER:
- {
- ret = ToString( value.Get<unsigned int>() );
- break;
- }
case Property::VECTOR2:
{
ret = ToString( value.Get<Vector2>() );
// special field 'effect' references the shader effect instances
if(key == "effect")
{
- RenderableActor actor = RenderableActor::DownCast(handle);
+ ImageActor actor = ImageActor::DownCast(handle);
if( actor )
{
OptionalString str = constant.IsString( keyChild.second );
if( Property::INVALID_INDEX == index )
{
- RenderableActor actor = RenderableActor::DownCast(handle);
+ ImageActor actor = ImageActor::DownCast(handle);
if( actor )
{
if( ShaderEffect effect = actor.GetShaderEffect() )
if( SetPropertyFromNode( *image, Property::MAP, property, constant ) )
{
Property::Map* map = property.GetMap();
- (*map)[ KEYNAME_TYPE ] = Property::Value(std::string("FrameBufferImage") );
- ret = FrameBufferImage::DownCast( Dali::Scripting::NewImage( property ) );
- mFrameBufferImageLut[ name ] = ret;
+
+ if( map )
+ {
+ (*map)[ KEYNAME_TYPE ] = Property::Value(std::string("FrameBufferImage") );
+ ret = FrameBufferImage::DownCast( Dali::Scripting::NewImage( property ) );
+ mFrameBufferImageLut[ name ] = ret;
+ }
}
}
}
: mSlotDelegate( this )
{
mParser = Dali::Toolkit::JsonParser::New();
+
+ Property::Map defaultDirs;
+ defaultDirs[ TOKEN_STRING(DALI_IMAGE_DIR) ] = DALI_IMAGE_DIR;
+ defaultDirs[ TOKEN_STRING(DALI_SOUND_DIR) ] = DALI_SOUND_DIR;
+ defaultDirs[ TOKEN_STRING(DALI_STYLE_DIR) ] = DALI_STYLE_DIR;
+
+ AddConstants( defaultDirs );
}
Builder::~Builder()