xDialog updates

Added a test and made some small changes