mirror of
https://github.com/nasa/openmct.git
synced 2025-04-13 22:23:13 +00:00
track display addChild time diff
This commit is contained in:
parent
4dd559f6fa
commit
9a8934b626
@ -500,12 +500,6 @@ export default {
|
||||
}
|
||||
},
|
||||
addItem(itemType, ...options) {
|
||||
const now = Date.now();
|
||||
const oldAddItemTime = this.addItemTime ?? now;
|
||||
this.addItemTime = now;
|
||||
const timeDifference = this.addItemTime - oldAddItemTime;
|
||||
console.log(`addItem for ${itemType} time difference (ms):`, timeDifference);
|
||||
|
||||
let item = getItemDefinition(itemType, this.openmct, this.gridSize, ...options);
|
||||
item.type = itemType;
|
||||
item.id = uuid();
|
||||
@ -615,9 +609,15 @@ export default {
|
||||
}
|
||||
},
|
||||
addChild(child) {
|
||||
console.log('addChild', child);
|
||||
if (this.isItemAlreadyTracked(child)) {
|
||||
return;
|
||||
}
|
||||
const now = Date.now();
|
||||
const oldChildTime = this.childTime ?? now;
|
||||
this.childTime = now;
|
||||
const timeDifference = this.childTime - oldChildTime;
|
||||
console.log(`addChild for ${child.name} time difference (ms):`, timeDifference);
|
||||
|
||||
let type;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user