Notifications
Clear all

[Closed] Undo issue any suggestions

 PEN

I’m editing keys with a Max script UI, I’m using a dotNet based UI and in a mouseMove event I’m moving keys. If I wrap the undo on around the code in the mouseMove event it is capturing every move, not the whole move. So I get 100 undos in no time at all. I want to capture the whole move, any way around it that you see?

12 Replies
1 Reply
(@denist)
Joined: 11 months ago

Posts: 0

I have a lot of tools which are working on mouse move. Because I control all mouse moves, mouse start, and mouse stop, usually I do any ZERO but undoable operation (like move on [0,0,0]) on mouse start (down) and do all other changes with undo off on move. On mouse end (Up) I check for cancel (right click or ESC). If it was canceled I do max undo .

Second solution is to use theHold interface. You can start a BLOCK of operations with UNDO and end it after some condition. (see theHold in MXS Help). It’s a better way then first one, because in case of CANCEL you can cancel your undo block, restore “pre undo” state, and “undo string name” will not go in undo/redo stack.

 PEN

I don’t think there is a solution to it so I have just written my own undo functions. Works just the way I need now.

You’re gonna end up writing your own 3d app if you keep this pace up. =P

 PEN

Some body, any one! I need an INTERVENTION! Stop meeeeeeeee;)

 PEN

Pleeeeeeeeeeeese stop me!

And this is probably when you’ll find that MAX already has a window just like that built in. =P

 JHN

Paul, maybe it’s time to change “R&D/Technical Director” to “Application Developer”
Although I’m sure there’s lots of R&D going on!

Looks pretty complex!
-Johan

You have to love that. But come on Paul, enough is enough. There is more to life than making UI controls for 3D programs. err…can someone please let me know what that is.

 PEN

Your right, maybe I should go model and texture some thing:S

Looks interesting, what does it do paul?

Page 1 / 2