mirror of
https://github.com/nasa/openmct.git
synced 2024-12-19 21:27:52 +00:00
[Plot] Only highlight legend if multiple
Legend items will only be highlighted when selected for inspection if there are more than one legend item in the plot.
This commit is contained in:
parent
15152d26f8
commit
cebdf24666
@ -166,13 +166,14 @@ define(
|
||||
}
|
||||
|
||||
// Determines if the legend item is being inspected. If so, the class
|
||||
// is 'inspected'
|
||||
// is 'inspected' -- unless that is the only legend item for the plot
|
||||
function getInspectedClass(telemetryObject) {
|
||||
if ($scope.ngModel &&
|
||||
$scope.ngModel.inspectionObjects &&
|
||||
$scope.ngModel.inspectionObjects.indexOf(telemetryObject) !== -1) {
|
||||
$scope.ngModel.inspectionObjects.indexOf(telemetryObject) !== -1 &&
|
||||
self.modeOptions.getModeHandler().getSubPlots()[0].telemetryObjects.length > 1) {
|
||||
return "inspected";
|
||||
}
|
||||
}
|
||||
}
|
||||
this.getInspectedClass = getInspectedClass;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user