layer dialog moved to ui_manager
tool dialog moved to ui manager
color picker button moved to ui manager
unified dialog initialization code
fixed layer buttons crashing the program after undo