diff --git a/apps/documenteditor/mobile/app/controller/Toolbar.js b/apps/documenteditor/mobile/app/controller/Toolbar.js index d7f6367d3..38ca931e0 100644 --- a/apps/documenteditor/mobile/app/controller/Toolbar.js +++ b/apps/documenteditor/mobile/app/controller/Toolbar.js @@ -49,7 +49,7 @@ define([ ], function (core, $, _, Backbone) { 'use strict'; - DE.Controllers.Toolbar = Backbone.Controller.extend((function() { + DE.Controllers.Toolbar = Backbone.Controller.extend(_.extend((function() { // private var _backUrl; @@ -149,5 +149,5 @@ define([ leaveButtonText : 'Leave this Page', stayButtonText : 'Stay on this Page' } - })()); + })(), DE.Controllers.Toolbar || {})) }); \ No newline at end of file diff --git a/apps/documenteditor/mobile/app/view/Toolbar.js b/apps/documenteditor/mobile/app/view/Toolbar.js index cf0403c61..d24de94b8 100644 --- a/apps/documenteditor/mobile/app/view/Toolbar.js +++ b/apps/documenteditor/mobile/app/view/Toolbar.js @@ -48,7 +48,7 @@ define([ ], function (toolbarTemplate, $, _, Backbone) { 'use strict'; - DE.Views.Toolbar = Backbone.View.extend((function() { + DE.Views.Toolbar = Backbone.View.extend(_.extend((function() { // private return { @@ -86,7 +86,8 @@ define([ $el.prepend(this.template({ android : Common.SharedSettings.get('android'), phone : Common.SharedSettings.get('phone'), - backTitle : Common.SharedSettings.get('android') ? '' : 'Back' + backTitle : Common.SharedSettings.get('android') ? '' : this.textBack, + scope : this })); return this; @@ -131,7 +132,9 @@ define([ // Settings showSettings: function () { DE.getController('Settings').showModal(); - } + }, + + textBack: 'Back' } - })()); -}); + })(), DE.Views.Toolbar || {})) +}); \ No newline at end of file diff --git a/apps/documenteditor/mobile/locale/en.json b/apps/documenteditor/mobile/locale/en.json index 54b465f14..015698d8e 100644 --- a/apps/documenteditor/mobile/locale/en.json +++ b/apps/documenteditor/mobile/locale/en.json @@ -129,5 +129,11 @@ "DE.Views.Settings.textVersion": "Version", "DE.Views.Settings.textAddress": "address", "DE.Views.Settings.textEmail": "email", - "DE.Views.Settings.textTel": "tel" + "DE.Views.Settings.textTel": "tel", + + "DE.Controllers.Toolbar.dlgLeaveTitleText": "You leave the application", + "DE.Controllers.Toolbar.dlgLeaveMsgText": "You have unsaved changes in this document. Click 'Stay on this Page' to await the autosave of the document. Click 'Leave this Page' to discard all the unsaved changes.", + "DE.Controllers.Toolbar.leaveButtonText": "Leave this Page", + "DE.Controllers.Toolbar.stayButtonText": "Stay on this Page", + "DE.Views.Toolbar.textBack": "Back" } \ No newline at end of file