cancel button of tool bar

hi,can any one help me to know how cancel the last action done. i want to develop the "ctrl Z" fonctionnality in my own module. thanh's.

Loader.
Up arrow icon