Remove the input.cpp/hpp, made dialog more consistent in handling events. Made dialog respect child widget z-order.