mirror of
https://github.com/nasa/openmct.git
synced 2025-03-22 03:55:31 +00:00
[Timeline] Remove width method
...from TimelineController. Will replace with a more straightforward call to the zoom controller that uses the exposed end time instead, to address #981.
This commit is contained in:
parent
dc577d4c24
commit
35d7d9b380
@ -79,15 +79,6 @@ define(
|
||||
graphPopulator.populate(swimlanePopulator.get());
|
||||
}
|
||||
|
||||
// Get pixel width for right pane, using zoom controller
|
||||
function width(zoomController) {
|
||||
var start = swimlanePopulator.start(),
|
||||
end = swimlanePopulator.end();
|
||||
return zoomController.toPixels(zoomController.duration(
|
||||
Math.max(end - start, MINIMUM_DURATION)
|
||||
));
|
||||
}
|
||||
|
||||
// Refresh resource graphs
|
||||
function refresh() {
|
||||
if (graphPopulator) {
|
||||
@ -121,10 +112,10 @@ define(
|
||||
// Expose active set of swimlanes
|
||||
return {
|
||||
/**
|
||||
* Get the width, in pixels, of the timeline area
|
||||
* @returns {number} width, in pixels
|
||||
* Get the end of the displayed timeline, in milliseconds.
|
||||
* @returns {number} the end of the displayed timeline
|
||||
*/
|
||||
width: width,
|
||||
end: swimlanePopulator.end.bind(swimlanePopulator),
|
||||
/**
|
||||
* Get the swimlanes which should currently be displayed.
|
||||
* @returns {TimelineSwimlane[]} the swimlanes
|
||||
|
Loading…
x
Reference in New Issue
Block a user