maskDialog almost complete

debug adds some comments.