minor code fix

This commit is contained in:
Alexander Nozik 2018-07-10 13:57:26 +03:00
parent 4efeac7657
commit fbd5fc50e6
2 changed files with 4 additions and 3 deletions

View File

@ -47,7 +47,7 @@ class AmplitudeView : View(title = "Numass amplitude spectrum plot", icon = Imag
"showLine" to true
"showSymbol" to false
"showErrors" to false
}.setType(DataPlot::class)
}.setType<DataPlot>()
}
val binningProperty = SimpleObjectProperty(20)

View File

@ -34,7 +34,7 @@ class HVView : View(title = "High voltage time plot", icon = ImageView(dfIcon))
"showSymbol" to false
"showErrors" to false
}
plots.setType(DataPlot::class)
plots.setType<DataPlot>()
}
private val container = PlotContainer(frame);
@ -58,7 +58,8 @@ class HVView : View(title = "High voltage time plot", icon = ImageView(dfIcon))
} ui { hvData ->
hvData?.let {
for (dp in it) {
val plot: TimePlot = frame[change.key] as TimePlot? ?: TimePlot(change.key).apply { frame.add(this) }
val plot: TimePlot = frame[change.key] as TimePlot?
?: TimePlot(change.key).apply { frame.add(this) }
plot.put(dp.getValue("timestamp").time, dp.getValue("value"))
}
}