api/public/core.js in artoo-0.1.2 vs api/public/core.js in artoo-0.1.3

- old
+ new

@@ -210,10 +210,12 @@ ]); }).call(this); (function() { + window.driversWithOutput = ["Pinger", "Pinger2", "ardrone_navigation", "wiiclassic"]; + this.RobotIndexCtrl = function($scope, $http, $location, $route) { $http.get('/robots').success(function(data) { return $scope.robots = data; }); return $scope.robotDetail = function(robotId) { @@ -229,9 +231,14 @@ $scope.getDeviceDetail = function(deviceId) { return $http.get('/robots/' + $scope.robot.name + "/devices/" + deviceId).success(function(data) { $scope.deviceDetail = data; return device.console(); }); + }; + $scope.driverHasOutput = function(driverId) { + if ($.inArray(driverId, window.driversWithOutput) !== -1) { + return true; + } }; device = { console: function() { if (window.ws) { window.ws.close();