Make an empty database popup a dialog.

Fix #1.
Fix whitespace.