Added dialogs and Firefox 18 compatibility