projects
/
platform
/
core
/
uifw
/
dali-toolkit.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
DALi Version 1.2.61
[platform/core/uifw/dali-toolkit.git]
/
dali-toolkit
/
internal
/
builder
/
builder-impl.cpp
diff --git
a/dali-toolkit/internal/builder/builder-impl.cpp
b/dali-toolkit/internal/builder/builder-impl.cpp
index
4a23ed1
..
5a18bef
100644
(file)
--- a/
dali-toolkit/internal/builder/builder-impl.cpp
+++ b/
dali-toolkit/internal/builder/builder-impl.cpp
@@
-202,7
+202,12
@@
void Builder::LoadFromString( std::string const& data, Dali::Toolkit::Builder::U
}
}
}
}
- if( !mParser.Parse( data ) )
+ if( mParser.Parse( data ) )
+ {
+ // Drop the styles and get them to be rebuilt against the new parse tree as required.
+ mStyles.Clear();
+ }
+ else
{
DALI_LOG_WARNING( "JSON Parse Error:%d:%d:'%s'\n",
mParser.GetErrorLineNumber(),
{
DALI_LOG_WARNING( "JSON Parse Error:%d:%d:'%s'\n",
mParser.GetErrorLineNumber(),
@@
-213,8
+218,8
@@
void Builder::LoadFromString( std::string const& data, Dali::Toolkit::Builder::U
}
}
}
}
- DUMP_PARSE_TREE(
p
arser); // This macro only writes out if DEBUG is enabled and the "DUMP_TREE" constant is defined in the stylesheet.
- DUMP_TEST_MAPPINGS(
p
arser);
+ DUMP_PARSE_TREE(
mP
arser); // This macro only writes out if DEBUG is enabled and the "DUMP_TREE" constant is defined in the stylesheet.
+ DUMP_TEST_MAPPINGS(
mP
arser);
DALI_ASSERT_ALWAYS(mParser.GetRoot() && "Cannot parse JSON");
}
DALI_ASSERT_ALWAYS(mParser.GetRoot() && "Cannot parse JSON");
}