update stock index visuals on widget.add event
This commit is contained in:
parent
aa54857ed8
commit
e1d83b01c6
2 changed files with 6 additions and 1 deletions
|
|
@ -90,6 +90,12 @@ CAM.init = function(kiri, api) {
|
|||
}
|
||||
}
|
||||
|
||||
api.event.on("widget.add", widget => {
|
||||
if (isCamMode) {
|
||||
setAnimationStyle(api.conf.get());
|
||||
}
|
||||
});
|
||||
|
||||
// wire up animate button in ui
|
||||
api.event.on("function.animate", (mode) => {
|
||||
if (isAnimate) {
|
||||
|
|
|
|||
|
|
@ -89,7 +89,6 @@ function platformUpdateTopZ(zdelta) {
|
|||
const { process, stock } = current();
|
||||
const hasStock = stock.x && stock.y && stock.z;
|
||||
const MODE = get_mode();
|
||||
|
||||
api.widgets.each(widget => {
|
||||
if (MODE === MODES.CAM) {
|
||||
const bounds = widget.getBoundingBox();
|
||||
|
|
|
|||
Loading…
Reference in a new issue