From: ThorstenB Date: Sun, 12 Jun 2011 11:31:23 +0000 (+0200) Subject: Make some properties read-only to avoid sim-reset issues. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=a1fe0f6305d7f64870f9e13299e65cde8a405a4e;p=simgear.git Make some properties read-only to avoid sim-reset issues. Do not loose internal statistics/state on sim-reset --- diff --git a/simgear/scene/tsync/terrasync.cxx b/simgear/scene/tsync/terrasync.cxx index 88710f4d..e2d28860 100644 --- a/simgear/scene/tsync/terrasync.cxx +++ b/simgear/scene/tsync/terrasync.cxx @@ -619,7 +619,11 @@ void SGTerraSync::bind() _tiedProperties.Tie( _terraRoot->getNode("update-count", true), (int*) &_svnThread->_success_count ); _tiedProperties.Tie( _terraRoot->getNode("error-count", true), (int*) &_svnThread->_fail_count ); _tiedProperties.Tie( _terraRoot->getNode("tile-count", true), (int*) &_svnThread->_updated_tile_count ); - + _terraRoot->getNode("busy", true)->setAttribute(SGPropertyNode::WRITE,false); + _terraRoot->getNode("active", true)->setAttribute(SGPropertyNode::WRITE,false); + _terraRoot->getNode("update-count", true)->setAttribute(SGPropertyNode::WRITE,false); + _terraRoot->getNode("error-count", true)->setAttribute(SGPropertyNode::WRITE,false); + _terraRoot->getNode("tile-count", true)->setAttribute(SGPropertyNode::WRITE,false); // stalled is used as a signal handler (to connect listeners triggering GUI pop-ups) _stalled_node = _terraRoot->getNode("stalled", true); _stalled_node->setBoolValue(_svnThread->_stalled);