The dialog box is now be centered properly when it contains images with an unknown height and width.

The dialog will also show a scrollbar if it is higher than the window.