Clean up...
Added a debug possibility and wrote some debug tasks for the DialogAPI
and the Frames.