From db8e48772fda268a907e4472b77f702757cdccc9 Mon Sep 17 00:00:00 2001 From: rolux Date: Tue, 7 Jan 2014 13:23:11 +0530 Subject: [PATCH] cosmetic changes --- static/js/deleteDocumentDialog.js | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/static/js/deleteDocumentDialog.js b/static/js/deleteDocumentDialog.js index 8fdac612..02829cf2 100644 --- a/static/js/deleteDocumentDialog.js +++ b/static/js/deleteDocumentDialog.js @@ -3,11 +3,12 @@ pandora.ui.deleteDocumentDialog = function(files, callback) { - var that = pandora.ui.iconDialog({ + var string = files.length == 1 ? 'Document' : 'Documents', + that = pandora.ui.iconDialog({ buttons: [ Ox.Button({ id: 'keep', - title: files.length == 1 ? Ox._('Keep Document') : Ox._('Keep Documents') + title: Ox._('Keep ' + string) }).bindEvent({ click: function() { that.close(); @@ -15,7 +16,7 @@ pandora.ui.deleteDocumentDialog = function(files, callback) { }), Ox.Button({ id: 'delete', - title: files.length == 1 ? Ox._('Delete Document') : Ox._('Delete Documents') + title: Ox._('Delete ' + string) }).bindEvent({ click: function() { that.close(); @@ -29,7 +30,9 @@ pandora.ui.deleteDocumentDialog = function(files, callback) { ? Ox._('Are you sure you want to delete the document "{0}"?', [files[0]]) : Ox._('Are you sure you want to delete {0} documents?', [files.length]), keys: {enter: 'delete', escape: 'keep'}, - title: files.length == 1 ? Ox._('Delete Document') : Ox._('Delete {0} Documents', [files.length]) + title: files.length == 1 + ? Ox._('Delete Document') + : Ox._('Delete {0} Documents', [files.length]) }); return that;