Intercept user's Remove event

Hi Folksss!!

Do you know any trick to intercept a Remove event triggered by User on removing a Module from Rack?

I’ve try the onRemove’s Widget method:

void onRemove(const RemoveEvent &e) override {

But it’s called in both case: when I remove the Module manually or when I normally close Rack, so I can’t really distinguish them.

Who know? :slight_smile:

Unfortunately you can’t.

What exactly do you want to do inside onRemove?

1 Like

Basically, restore an external module state.

I bet the only solution is to correctly save states and restore it conveniently.