Add phoebe and titan connections.
This commit is contained in:
@@ -60,40 +60,26 @@ function updateVoltage(voltage)
|
||||
function updateTopicsGUI()
|
||||
{
|
||||
|
||||
ros.getTopics(ros.buildTopicList);
|
||||
ros.getTopics(function(result)
|
||||
{
|
||||
ros.topics = result;
|
||||
});
|
||||
|
||||
var topics = ros.getTopicsList();
|
||||
var topics = ros.topics;
|
||||
topics.sort()
|
||||
|
||||
if(topics != null){
|
||||
var innerHTML = "";
|
||||
for (var i = 0; i < topics.length; i++ )
|
||||
{
|
||||
innerHTML = innerHTML.concat(generateTopicCheckbox(topics[i]));
|
||||
innerHTML = innerHTML.concat(topics[i]);
|
||||
innerHTML = innerHTML.concat("<br>");
|
||||
}
|
||||
document.getElementById("ROSTopics").innerHTML = innerHTML;
|
||||
}
|
||||
|
||||
};
|
||||
|
||||
function generateTopicCheckbox(topic)
|
||||
{
|
||||
var str = "<div class=\"checkbox\">";
|
||||
var checked_str = "unchecked";
|
||||
if (topic.bag == true)
|
||||
{
|
||||
checked_str = "checked"
|
||||
}
|
||||
str =str.concat("<label><input type=\"checkbox\" onclick=\"toggleToBag(\'"+ topic.name + "\')\" id=\"" + topic.name + "_checkbox\" "+ checked_str +">");
|
||||
str = str.concat(topic.name);
|
||||
str = str.concat("</label></div>");
|
||||
return str;
|
||||
};
|
||||
|
||||
function toggleToBag(topic_name)
|
||||
{
|
||||
// if($.inArray(topic_name, ros.topics))
|
||||
ros.topics[ros.topics.indexOfTopic(topic_name)].bag = !ros.topics[ros.topics.indexOfTopic(topic_name)].bag ;
|
||||
}
|
||||
|
||||
function updateNodesGUI()
|
||||
{
|
||||
@@ -113,7 +99,6 @@ function updateNodesGUI()
|
||||
{
|
||||
innerHTML = innerHTML.concat(nodes[i]);
|
||||
innerHTML = innerHTML.concat("<br>");
|
||||
|
||||
}
|
||||
document.getElementById("ROSNodes").innerHTML = innerHTML;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user