ui cleanup. stub in animate button when stock set in cam mode
This commit is contained in:
parent
bc7541a8dc
commit
de2ad2a02d
6 changed files with 86 additions and 76 deletions
|
|
@ -13,10 +13,11 @@
|
|||
isArrange,
|
||||
isCamMode,
|
||||
camStock,
|
||||
API, SPACE, MODES, VIEWS, UI, UC;
|
||||
API, SPACE, STACKS, MODES, VIEWS, UI, UC;
|
||||
|
||||
CAM.init = function(kiri, api) {
|
||||
// console.log({kiri,api})
|
||||
STACKS = api.const.STACKS;
|
||||
SPACE = api.const.SPACE;
|
||||
MODES = api.const.MODES;
|
||||
VIEWS = api.const.VIEWS;
|
||||
|
|
@ -64,12 +65,19 @@
|
|||
"selection.scale",
|
||||
"selection.rotate"
|
||||
], updateStock);
|
||||
|
||||
api.event.on("preview.end", () => {
|
||||
if (camStock) STACKS.getStack("bounds").button("animate", animate);
|
||||
});
|
||||
};
|
||||
|
||||
function updateStock(args, event) {
|
||||
const SPACE = API.const.SPACE;
|
||||
const STACKS = API.const.STACKS;
|
||||
function animate() {
|
||||
API.view.set(VIEWS.ARRANGE);
|
||||
API.widgets.opacity(0.75);
|
||||
// console.log("animate", API.conf.get().stock);
|
||||
}
|
||||
|
||||
function updateStock(args, event) {
|
||||
STACKS.remove('bounds');
|
||||
if (isCamMode && isArrange) {
|
||||
STACKS.clear();
|
||||
|
|
|
|||
Loading…
Reference in a new issue