var txt = gettext('Do you really want to exit?');
if(documentIsDirty) {
txt += ' ' + gettext('Document contains unsaved changes!');
var txt = gettext('Do you really want to exit?');
if(documentIsDirty) {
txt += ' ' + gettext('Document contains unsaved changes!');