Implemented "Clear Traces" tool
This commit is contained in:
parent
dc4d92c9cd
commit
56414a7ca1
@ -19,7 +19,7 @@ TODO
|
||||
- [ ] Zoom Easing
|
||||
- [ ] 2-touch Pan & Zoom
|
||||
- [ ] Multi-touch Mass Create
|
||||
- [ ] Tool to Clear Traces
|
||||
- [x] Tool to Clear Traces
|
||||
- [ ] Undo feature:
|
||||
- [ ] Undo "Clear Traces" Action
|
||||
- [ ] Undo "Reset
|
||||
|
||||
@ -87,5 +87,12 @@ export class PlayPause extends Tool {
|
||||
this.updateButtons();
|
||||
}
|
||||
});
|
||||
|
||||
clearTraces.addEventListener('click', () => {
|
||||
// Obliterate object histories
|
||||
this.sim.objects.forEachObject(obj => {
|
||||
obj.history = [];
|
||||
}, null);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user