return NULL;
}
- if ( !node.GetChildren() )
+ const bool hasOnlyRefAttr = node.GetAttributes() != NULL &&
+ node.GetAttributes()->GetNext() == NULL;
+
+ if ( hasOnlyRefAttr && !node.GetChildren() )
{
// In the typical, simple case, <object_ref> is used to link
// to another node and doesn't have any content of its own that
// the colour doesn't use #RRGGBB format, check if it is symbolic
// colour name:
clr = GetSystemColour(v);
- if (clr.Ok())
+ if (clr.IsOk())
return clr;
ReportParamError
art_id, art_client) )
{
wxBitmap stockArt(wxArtProvider::GetBitmap(art_id, art_client, size));
- if ( stockArt.Ok() )
+ if ( stockArt.IsOk() )
return stockArt;
}
wxImage img(name);
#endif
- if (!img.Ok())
+ if (!img.IsOk())
{
ReportParamError
(
{
if (n->GetType() == wxXML_ELEMENT_NODE && n->GetName() == parambitmap)
{
- wxIcon icon = GetIcon(n);
+ wxIcon icon = GetIcon(n, wxART_OTHER, size);
if ( !imagelist )
{
// We need the real image list size to create it.
// is this font based on a system font?
wxFont font = GetSystemFont(GetParamValue(wxT("sysfont")));
- if (font.Ok())
+ if (font.IsOk())
{
if (hasSize && isize != -1)
font.SetPointSize(isize);