monster860 / FastDMM

A robust BYOND map editor
GNU General Public License v3.0
36 stars 16 forks source link

Added rudimentary undo/redo functionality #40

Closed Cruix closed 7 years ago

Cruix commented 7 years ago

Closes #38

Added undo and redo for the following operations:

At the moment, moving a selection is considered two operations: pasting the selection to the new place, and removing it from the old place.

The only way to use undo and redo is to use the dropdown menu. No hotkeys yet.

ghost commented 7 years ago

you are a god.

Cruix commented 7 years ago

You mean keeping a copy of the entire map for every single change that is made? That seems a bit excessive.

monster860 commented 7 years ago

No, keeping only the changes to the map (location (1,1) used to point to "aa" now it points to "bb") and the meanings of the keys referenced before and after the change.

bauen1 commented 7 years ago
Sure, it uses a bit of extra memory but it's not like we don't have a fuckton of it

And thats how bloatware happens.

Keeping a copy of the entire map will make its a memory gun and make it slow, how about a diff for each action instead ?

monster860 commented 7 years ago

how about a diff for each action instead ?

That is literally what I've been suggesting the whole time.....

Iamgoofball commented 7 years ago

@monster860 @Cruix can you guys do this

monster860 commented 7 years ago

I don't like the way this change is implemented.