[Tables] Default UTC time system if available and none others defined

This commit is contained in:
Henry
2017-01-25 15:41:08 -08:00
parent 6cd99efbb9
commit ef8efbd53d
3 changed files with 21 additions and 4 deletions

View File

@@ -22,7 +22,8 @@
define([
"./src/UTCTimeSystem",
'legacyRegistry'
'legacyRegistry',
'openmct'
], function (
UTCTimeSystem,
legacyRegistry
@@ -34,7 +35,23 @@ define([
"implementation": UTCTimeSystem,
"depends": ["$timeout"]
}
],
"runs": [
{
"implementation": function (openmct, $timeout) {
// Temporary shim to initialize the time conductor to
// something
if (!openmct.conductor.timeSystem()) {
var utcTimeSystem = new UTCTimeSystem($timeout);
openmct.conductor.timeSystem(utcTimeSystem, utcTimeSystem.defaults().bounds);
}
},
"depends": ["openmct", "$timeout"],
"priority": "fallback"
}
]
}
});
});