Skip to content

Commit

Permalink
Minor
Browse files Browse the repository at this point in the history
  • Loading branch information
deepnight committed Jan 12, 2024
1 parent cba6580 commit 686935f
Showing 1 changed file with 4 additions and 23 deletions.
27 changes: 4 additions & 23 deletions src/electron.renderer/page/Editor.hx
Original file line number Diff line number Diff line change
Expand Up @@ -1588,7 +1588,10 @@ class Editor extends Page {
jButton.appendTo(jPendingActions);
jButton.append('<span class="icon $iconId"/>');
jButton.append(label);
jButton.click(_->cb());
jButton.click(_->{
removePendingAction(className);
cb();
});
ui.Tip.attach(jButton, desc);

jButton.slideDown(0.2);
Expand All @@ -1606,7 +1609,6 @@ class Editor extends Page {
N.success("Done");
levelRender.invalidateAll();
worldRender.invalidateAll();
removePendingAction("rebuildAutoLayers");
});
});
}
Expand Down Expand Up @@ -1677,27 +1679,6 @@ class Editor extends Page {
}


// public function invalidateLayerRules(layerDefUid:Int) {
// // if( active )
// addPendingAction("layerRules", "autoLayer", "Rebuild all auto-layers", "All project auto-layers need to be updated to adapt to your latest changes.", ()->{
// for(w in project.worlds)
// for(l in w.levels)
// for(li in l.layerInstances)
// if( li.layerDefUid==layerDefUid )
// li.autoTilesCache = null;

// checkAutoLayersCache( (_)->{
// N.success("Done");
// levelRender.invalidateAll();
// worldRender.invalidateAll();
// // setProjectFlag(RequireAutoLayerRebuild, false);
// });
// });
// // else
// // removePendingAction(flag.getName());
// }


public function setWorldMode(v:Bool, usedMouseWheel=false) {
if( worldMode==v )
return;
Expand Down

0 comments on commit 686935f

Please # to comment.