]> git.mxchange.org Git - flightgear.git/blobdiff - src/Scripting/nasal-props.cxx
Modified Files:
[flightgear.git] / src / Scripting / nasal-props.cxx
index 77c74a830b3b2042c77981cd943c2ee4f526f8a1..0ff80e7649f65320234446954049c5e80066a229 100644 (file)
@@ -83,6 +83,8 @@ static naRef f_getAttribute(naContext c, naRef me, int argc, naRef* args)
     SGPropertyNode::Attribute attr;
     if(!a) a = "";
     if(!strcmp(a, "children"))         return naNum((*node)->nChildren());
+    else if(!strcmp(a, "listeners"))   return naNum((*node)->nListeners());
+    else if(!strcmp(a, "references"))  return naNum(node->getNumRefs());
     else if(!strcmp(a, "tied"))        return naNum((*node)->isTied());
     else if(!strcmp(a, "alias"))       return naNum((*node)->isAlias());
     else if(!strcmp(a, "read"))        attr = SGPropertyNode::READ;
@@ -325,7 +327,7 @@ static naRef f_globals(naContext c, naRef me, int argc, naRef* args)
 
 static struct {
     naCFunction func;
-    char* name;
+    const char* name;
 } propfuncs[] = {
     { f_getType, "_getType" },
     { f_getAttribute, "_getAttribute" },