0011866: free global _ for lodash library
authorCornelius Weiß <c.weiss@metaways.de>
Tue, 10 May 2016 16:17:39 +0000 (18:17 +0200)
committerPhilipp Schüle <p.schuele@metaways.de>
Wed, 18 May 2016 12:32:34 +0000 (14:32 +0200)
A modern JavaScript utility library delivering
 modularity, performance, & extras.

https://lodash.com/
https://github.com/lodash/lodash

https://forge.tine20.org/view.php?id=11866

Change-Id: I9e902bf6dd61e85addc653195dd1758977ab20f8
Reviewed-on: http://gerrit.tine20.com/customers/3146
Reviewed-by: Philipp Schüle <p.schuele@metaways.de>
Tested-by: Philipp Schüle <p.schuele@metaways.de>
215 files changed:
tine20/Addressbook/js/Addressbook.js
tine20/Addressbook/js/Model.js
tine20/Admin/js/Applications.js
tine20/Admin/js/GroupEditDialog.js
tine20/Admin/js/Groups.js
tine20/Admin/js/RoleEditDialog.js
tine20/Admin/js/Roles.js
tine20/Admin/js/TagEditDialog.js
tine20/Admin/js/Tags.js
tine20/Admin/js/config/FieldManager.js
tine20/Admin/js/customfield/EditDialog.js
tine20/Admin/js/user/EditDialog.js
tine20/Calendar/js/AttendeeFilterGrid.js
tine20/Calendar/js/AttendeeGridPanel.js
tine20/Calendar/js/Calendar.js
tine20/Calendar/js/DaysView.js
tine20/Calendar/js/EventContextAttendeesItem.js
tine20/Calendar/js/EventDetailsPanel.js
tine20/Calendar/js/EventEditDialog.js
tine20/Calendar/js/ImportDialog.js
tine20/Calendar/js/MainScreenCenterPanel.js
tine20/Calendar/js/Model.js
tine20/Calendar/js/MonthView.js
tine20/Calendar/js/SearchCombo.js
tine20/Calendar/js/YearView.js
tine20/Courses/js/AddMemberDialog.js
tine20/Courses/js/CourseEditDialog.js
tine20/Courses/js/Models.js
tine20/Crm/js/Crm.js
tine20/Crm/js/Model.js
tine20/ExampleApplication/js/Example.js
tine20/Expressodriver/js/AdminPanel.js
tine20/Expressodriver/js/ExceptionHandler.js
tine20/Expressodriver/js/Expressodriver.js
tine20/Expressodriver/js/ExternalAdapterEditDialog.js
tine20/Expressodriver/js/GridContextMenu.js
tine20/Expressodriver/js/Model.js
tine20/Expressodriver/js/NodeGridPanel.js
tine20/Expressodriver/js/NodeTreePanel.js
tine20/Expressomail/js/AccountEditDialog.js
tine20/Expressomail/js/AclsEditDialog.js
tine20/Expressomail/js/AclsGrid.js
tine20/Expressomail/js/AddressbookGridPanelHook.js
tine20/Expressomail/js/ContactGrid.js
tine20/Expressomail/js/Expressomail.js
tine20/Expressomail/js/FolderSelectPanel.js
tine20/Expressomail/js/GridPanel.js
tine20/Expressomail/js/ImportEmlDialog.js
tine20/Expressomail/js/MessageEditDialog.js
tine20/Expressomail/js/Model.js
tine20/Expressomail/js/RecipientGrid.js
tine20/Expressomail/js/TreeContextMenu.js
tine20/Expressomail/js/editorplugins/Ext.ux.form.HtmlEditor.SpellChecker.js
tine20/Expressomail/js/editorplugins/Ext.ux.form.HtmlEditor.Table.js
tine20/Expressomail/js/editorplugins/Ext.ux.form.HtmlEditor.UploadImage.js
tine20/Expressomail/js/sieve/RuleEditDialog.js
tine20/Expressomail/js/sieve/RulesGridPanel.js
tine20/Felamimail/js/ContactGrid.js
tine20/Felamimail/js/Felamimail.js
tine20/Felamimail/js/FolderSelectPanel.js
tine20/Felamimail/js/GridPanel.js
tine20/Felamimail/js/MessageEditDialog.js
tine20/Felamimail/js/Model.js
tine20/Felamimail/js/RecipientGrid.js
tine20/Felamimail/js/TreeContextMenu.js
tine20/Felamimail/js/sieve/RulesGridPanel.js
tine20/Filemanager/js/DownloadLinkGridPanel.js
tine20/Filemanager/js/ExceptionHandler.js
tine20/Filemanager/js/Filemanager.js
tine20/Filemanager/js/GridContextMenu.js
tine20/Filemanager/js/Model.js
tine20/Filemanager/js/NodeGridPanel.js
tine20/Filemanager/js/NodeTreePanel.js
tine20/HumanResources/js/ContractDetailsPanel.js
tine20/HumanResources/js/ContractEditDialog.js
tine20/HumanResources/js/ExtraFreeTimeDetailsPanel.js
tine20/HumanResources/js/FreeTimeEditDialog.js
tine20/HumanResources/js/Models.js
tine20/Projects/js/Model.js
tine20/Sales/js/AddressEditDialog.js
tine20/Sales/js/AdminPanel.js
tine20/Sales/js/BillingDateDialog.js
tine20/Sales/js/CopyAddressDialog.js
tine20/Sales/js/CustomerDetailsPanel.js
tine20/Sales/js/CustomerGridPanel.js
tine20/Sales/js/InvoiceGridPanel.js
tine20/Sales/js/InvoicePositionGridPanel.js
tine20/Sales/js/ProductAggregateGridPanel.js
tine20/Sales/js/PurchaseInvoiceGridPanel.js
tine20/Sales/js/SupplierDetailsPanel.js
tine20/Sales/js/SupplierGridPanel.js
tine20/Setup/js/EnvCheckGridPanel.js
tine20/SimpleFAQ/js/Model.js
tine20/Sipgate/js/AccountEditDialog.js
tine20/Sipgate/js/CallStateWindow.js
tine20/Sipgate/js/DialNumberDialog.js
tine20/Sipgate/js/LineGridPanel.js
tine20/Sipgate/js/Models.js
tine20/Sipgate/js/SearchAddressDialog.js
tine20/Sipgate/js/SmsEditDialog.js
tine20/Tasks/js/Models.js
tine20/Tasks/js/TaskEditDialog.js
tine20/Tasks/js/Tasks.js
tine20/Timetracker/js/DurationSlider.js
tine20/Timetracker/js/DurationSpinner.js
tine20/Timetracker/js/Models.js
tine20/Timetracker/js/TimeaccountEditDialog.js
tine20/Timetracker/js/TimeaccountGridPanel.js
tine20/Timetracker/js/TimesheetGridPanel.js
tine20/Tinebase/js/AboutDialog.js
tine20/Tinebase/js/AdminPanel.js
tine20/Tinebase/js/AppManager.js
tine20/Tinebase/js/Application.js
tine20/Tinebase/js/ApplicationStarter.js
tine20/Tinebase/js/Container.js
tine20/Tinebase/js/CreditsScreen.js
tine20/Tinebase/js/ExceptionDialog.js
tine20/Tinebase/js/ExceptionHandler.js
tine20/Tinebase/js/LicenseScreen.js
tine20/Tinebase/js/LoginPanel.js
tine20/Tinebase/js/MainMenu.js
tine20/Tinebase/js/MainScreen.js
tine20/Tinebase/js/Models.js
tine20/Tinebase/js/PasswordChangeDialog.js
tine20/Tinebase/js/common.js
tine20/Tinebase/js/data/Record.js
tine20/Tinebase/js/prototypeTranslations.js
tine20/Tinebase/js/tineInit.js
tine20/Tinebase/js/ux/ConnectionStatus.js
tine20/Tinebase/js/ux/Percentage.js
tine20/Tinebase/js/ux/PopupWindow.js
tine20/Tinebase/js/ux/PopupWindowManager.js
tine20/Tinebase/js/ux/SearchField.js
tine20/Tinebase/js/ux/form/ComboBoxRecentsPlugin.js
tine20/Tinebase/js/ux/form/ImageField.js
tine20/Tinebase/js/ux/form/LayerCombo.js
tine20/Tinebase/js/ux/grid/GroupingGridPlugin.js
tine20/Tinebase/js/ux/grid/PagingToolbar.js
tine20/Tinebase/js/widgets/ActivitiesGridPanel.js
tine20/Tinebase/js/widgets/ActivitiesPanel.js
tine20/Tinebase/js/widgets/ContentTypeTreePanel.js
tine20/Tinebase/js/widgets/CountryCombo.js
tine20/Tinebase/js/widgets/EditRecord.js
tine20/Tinebase/js/widgets/LangChooser.js
tine20/Tinebase/js/widgets/MainScreen.js
tine20/Tinebase/js/widgets/TimezoneChooser.js
tine20/Tinebase/js/widgets/VersionCheck.js
tine20/Tinebase/js/widgets/account/ChangeAccountAction.js
tine20/Tinebase/js/widgets/account/PickerGridPanel.js
tine20/Tinebase/js/widgets/container/CalDAVContainerPropertiesHookField.js
tine20/Tinebase/js/widgets/container/ContainerSelect.js
tine20/Tinebase/js/widgets/container/FilterModel.js
tine20/Tinebase/js/widgets/container/GrantsDialog.js
tine20/Tinebase/js/widgets/container/GrantsGrid.js
tine20/Tinebase/js/widgets/container/PropertiesDialog.js
tine20/Tinebase/js/widgets/container/TreePanel.js
tine20/Tinebase/js/widgets/customfields/EditDialogPlugin.js
tine20/Tinebase/js/widgets/dialog/AddToRecordPanel.js
tine20/Tinebase/js/widgets/dialog/AdminPanel.js
tine20/Tinebase/js/widgets/dialog/AlarmPanel.js
tine20/Tinebase/js/widgets/dialog/AttachmentsGridPanel.js
tine20/Tinebase/js/widgets/dialog/CredentialsDialog.js
tine20/Tinebase/js/widgets/dialog/DuplicateMergeDialog.js
tine20/Tinebase/js/widgets/dialog/DuplicateResolveGridPanel.js
tine20/Tinebase/js/widgets/dialog/EditDialog.js
tine20/Tinebase/js/widgets/dialog/ExceptionHandlerDialog.js
tine20/Tinebase/js/widgets/dialog/ExportDialog.js
tine20/Tinebase/js/widgets/dialog/FileListDialog.js
tine20/Tinebase/js/widgets/dialog/ImportDialog.js
tine20/Tinebase/js/widgets/dialog/LinkPanel.js
tine20/Tinebase/js/widgets/dialog/MultiOptionsDialog.js
tine20/Tinebase/js/widgets/dialog/MultipleEditDialogPlugin.js
tine20/Tinebase/js/widgets/dialog/MultipleEditResultSummary.js
tine20/Tinebase/js/widgets/dialog/PreferencesDialog.js
tine20/Tinebase/js/widgets/dialog/PreferencesPanel.js
tine20/Tinebase/js/widgets/dialog/PreferencesTreePanel.js
tine20/Tinebase/js/widgets/dialog/SimpleImportDialog.js
tine20/Tinebase/js/widgets/dialog/WizardPanel.js
tine20/Tinebase/js/widgets/form/ConfigPanel.js
tine20/Tinebase/js/widgets/form/FileUploadButton.js
tine20/Tinebase/js/widgets/form/RecordPickerComboBox.js
tine20/Tinebase/js/widgets/form/RecordPickerManager.js
tine20/Tinebase/js/widgets/grid/BbarGridPanel.js
tine20/Tinebase/js/widgets/grid/FileUploadGrid.js
tine20/Tinebase/js/widgets/grid/FilterModel.js
tine20/Tinebase/js/widgets/grid/FilterModelMultiSelect.js
tine20/Tinebase/js/widgets/grid/FilterPanel.js
tine20/Tinebase/js/widgets/grid/FilterStructureTreePanel.js
tine20/Tinebase/js/widgets/grid/FilterToolbar.js
tine20/Tinebase/js/widgets/grid/FilterToolbarQuickFilterPlugin.js
tine20/Tinebase/js/widgets/grid/ForeignRecordFilter.js
tine20/Tinebase/js/widgets/grid/GridPanel.js
tine20/Tinebase/js/widgets/grid/LinkGridPanel.js
tine20/Tinebase/js/widgets/grid/MonthFilter.js
tine20/Tinebase/js/widgets/grid/PickerFilter.js
tine20/Tinebase/js/widgets/grid/PickerGridPanel.js
tine20/Tinebase/js/widgets/grid/QuickaddGridPanel.js
tine20/Tinebase/js/widgets/grid/RendererManager.js
tine20/Tinebase/js/widgets/keyfield/ConfigField.js
tine20/Tinebase/js/widgets/keyfield/ConfigGrid.js
tine20/Tinebase/js/widgets/mainscreen/WestPanel.js
tine20/Tinebase/js/widgets/persistentfilter/EditPersistentFilterPanel.js
tine20/Tinebase/js/widgets/persistentfilter/PickerPanel.js
tine20/Tinebase/js/widgets/relation/FilterModel.js
tine20/Tinebase/js/widgets/relation/GenericPickerGridPanel.js
tine20/Tinebase/js/widgets/relation/PickerCombo.js
tine20/Tinebase/js/widgets/tags/TagCombo.js
tine20/Tinebase/js/widgets/tags/TagFilter.js
tine20/Tinebase/js/widgets/tags/TagToggleBox.js
tine20/Tinebase/js/widgets/tags/TagsMassAttachAction.js
tine20/Tinebase/js/widgets/tags/TagsMassDetachAction.js
tine20/Tinebase/js/widgets/tags/TagsPanel.js
tine20/Tinebase/js/widgets/tree/ContextMenu.js
tine20/Voipmanager/js/Models.js
tine20/Voipmanager/js/Snom/LocationGridPanel.js

index 89b7f0d..3b2c032 100755 (executable)
@@ -19,7 +19,7 @@ Ext.ns('Tine.Addressbook');
 Tine.Addressbook.Application = Ext.extend(Tine.Tinebase.Application, {
     
     /**
-     * auto hook text _('New Contact')
+     * auto hook text i18n._('New Contact')
      */
     addButtonText: 'New Contact',
     
index 11a1ef2..f59f82b 100644 (file)
@@ -48,13 +48,13 @@ Tine.Addressbook.Model.ContactArray = Tine.Tinebase.Model.genericFields.concat([
     {name: 'adr_two_countryname', label: 'Country (Private Address)', group: 'Private Address' }, //_('Country (Private Address)')
     {name: 'adr_two_lon', group: 'Private Address', omitDuplicateResolving: true},
     {name: 'adr_two_lat', group: 'Private Address', omitDuplicateResolving: true},
-    {name: 'tel_work', label: 'Phone', group: 'Company Communication' }, //_('Phone') _('Company Communication') 
+    {name: 'tel_work', label: 'Phone', group: 'Company Communication' }, //_('Phone') _('Company Communication')
     {name: 'tel_cell', label: 'Mobile', group: 'Company Communication' }, //_('Mobile')
     {name: 'tel_fax', label: 'Fax', group: 'Company Communication' }, //_('Fax')
     {name: 'tel_assistent', group: 'contact_infos', omitDuplicateResolving: true },
     {name: 'tel_car', group: 'contact_infos', omitDuplicateResolving: true },
     {name: 'tel_pager', group: 'contact_infos', omitDuplicateResolving: true },
-    {name: 'tel_home', label: 'Phone (private)', group: 'Private Communication' }, //_('Phone (private)') _('Private Communication') 
+    {name: 'tel_home', label: 'Phone (private)', group: 'Private Communication' }, //_('Phone (private)') _('Private Communication')
     {name: 'tel_fax_home', label: 'Fax (private)', group: 'Private Communication' }, //_('Fax (private)')
     {name: 'tel_cell_private', label: 'Mobile (private)', group: 'Private Communication' }, //_('Mobile (private)')
     {name: 'tel_other', group: 'contact_infos', omitDuplicateResolving: true },
@@ -154,7 +154,7 @@ Tine.Addressbook.Model.Contact.getFilterModel = function() {
     var typeStore = [['contact', app.i18n._('Contact')], ['user', app.i18n._('User Account')]];
     
     return [
-        {label: _('Quick Search'),                                                      field: 'query',              operators: ['contains']},
+        {label: i18n._('Quick Search'),                                                      field: 'query',              operators: ['contains']},
         {filtertype: 'tine.widget.container.filtermodel', app: app, recordClass: Tine.Addressbook.Model.Contact},
         {filtertype: 'addressbook.listMember', app: app},
         {filtertype: 'addressbook.listRoleMember', app: app},
@@ -182,10 +182,10 @@ Tine.Addressbook.Model.Contact.getFilterModel = function() {
         {label: app.i18n._('City') + ' (' + app.i18n._('Private Address') + ')',        field: 'adr_two_locality'},
         {label: app.i18n._('Country') + '  (' + app.i18n._('Private Address') + ')',    field: 'adr_two_countryname', valueType: 'country'},
         {label: app.i18n._('Type'), defaultValue: 'contact', valueType: 'combo',        field: 'type',               store: typeStore},
-        {label: _('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
-        {label: _('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
-        {label: _('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
-        {label: _('Created By'),                                                        field: 'created_by',         valueType: 'user'}
+        {label: i18n._('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
+        {label: i18n._('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
+        {label: i18n._('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
+        {label: i18n._('Created By'),                                                        field: 'created_by',         valueType: 'user'}
     ];
 };
     
@@ -246,15 +246,15 @@ Tine.Addressbook.Model.List.getFilterModel = function() {
     var typeStore = [['list', app.i18n._('List')], ['user', app.i18n._('User Account')]];
     
     return [
-        {label: _('Quick search'),                                                      field: 'query',              operators: ['contains']},
+        {label: i18n._('Quick search'),                                                      field: 'query',              operators: ['contains']},
         {filtertype: 'tine.widget.container.filtermodel', app: app, recordClass: Tine.Addressbook.Model.Contact},
         {filtertype: 'addressbook.listMember', app: app},
         {label: app.i18n._('Name'),                                               field: 'name' },
         {label: app.i18n._('Description'),                                                field: 'description'},
-        {label: _('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
-        {label: _('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
-        {label: _('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
-        {label: _('Created By'),                                                        field: 'created_by',         valueType: 'user'},
+        {label: i18n._('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
+        {label: i18n._('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
+        {label: i18n._('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
+        {label: i18n._('Created By'),                                                        field: 'created_by',         valueType: 'user'},
         {filtertype: 'tinebase.tag', app: app}
     ];
 };
@@ -311,7 +311,7 @@ Tine.Addressbook.Model.EmailAddress = Tine.Tinebase.data.Record.create([
  */ 
 Tine.Addressbook.Model.EmailAddress.getFilterModel = function() {
     return [
-        {label: _('Quick search'),       field: 'query',              operators: ['contains']}
+        {label: i18n._('Quick search'),       field: 'query',              operators: ['contains']}
     ];
 };
 
@@ -341,6 +341,6 @@ Tine.Addressbook.Model.ListRole = Tine.Tinebase.data.Record.create([
  */
 Tine.Addressbook.Model.ListRole.getFilterModel = function() {
     return [
-        {label: _('Quick search'),       field: 'query',              operators: ['contains']}
+        {label: i18n._('Quick search'),       field: 'query',              operators: ['contains']}
     ];
 };
index 7cc5361..395d145 100644 (file)
@@ -152,7 +152,7 @@ Tine.Admin.Applications.Main = function() {
         var ApplicationsAdminQuickSearchField = new Ext.ux.SearchField({
             id: 'ApplicationsAdminQuickSearchField',
             width:240,
-            emptyText: Tine.Tinebase.translation._hidden('enter searchfilter')
+            emptyText: i18n._hidden('enter searchfilter')
         });
         ApplicationsAdminQuickSearchField.on('change', function() {
             Ext.getCmp('gridAdminApplications').getStore().load({params:{start:0, limit:50}});
index 4b0f051..9027b0a 100644 (file)
@@ -219,7 +219,7 @@ Tine.Admin.Groups.EditDialog = Ext.extend(Tine.widgets.dialog.EditRecord, {
             scope: this
         }]);
 
-        this.loadMask = new Ext.LoadMask(ct, {msg: String.format(_('Transferring {0}...'), this.translation.gettext('Group'))});
+        this.loadMask = new Ext.LoadMask(ct, {msg: String.format(i18n._('Transferring {0}...'), this.translation.gettext('Group'))});
         
         if (this.group.id !== 0) {
             this.loadMask.show();
index 64b08fe..867107d 100644 (file)
@@ -141,7 +141,7 @@ Tine.Admin.Groups.Main = {
         var GroupsAdminQuickSearchField = new Ext.ux.SearchField({
             id: 'GroupsAdminQuickSearchField',
             width: 240,
-            emptyText: Tine.Tinebase.translation._hidden('enter searchfilter')
+            emptyText: i18n._hidden('enter searchfilter')
         });
         GroupsAdminQuickSearchField.on('change', function () {
             Ext.getCmp('AdminGroupsGrid').getStore().load({
index 8f90b12..7fa91c4 100644 (file)
@@ -358,7 +358,7 @@ Tine.Admin.Roles.EditDialog = Ext.extend(Tine.widgets.dialog.EditRecord, {
             scope: this
         }]);
 
-        this.loadMask = new Ext.LoadMask(ct, {msg: String.format(_('Transferring {0}...'), this.translation.gettext('Role'))});
+        this.loadMask = new Ext.LoadMask(ct, {msg: String.format(i18n._('Transferring {0}...'), this.translation.gettext('Role'))});
         this.loadMask.show();
     },
     
index 4a98955..fb6dea5 100644 (file)
@@ -140,7 +140,7 @@ Tine.Admin.Roles.Main = {
         var RolesQuickSearchField = new Ext.ux.SearchField({
             id: 'RolesQuickSearchField',
             width:240,
-            emptyText: Tine.Tinebase.translation._hidden('enter searchfilter')
+            emptyText: i18n._hidden('enter searchfilter')
         });
         RolesQuickSearchField.on('change', function(){
             Ext.getCmp('AdminRolesGrid').getStore().load({
index 6e81098..70c7446 100644 (file)
@@ -290,7 +290,7 @@ Tine.Admin.Tags.EditDialog = Ext.extend(Tine.widgets.dialog.EditRecord, {
             scope: this
         }]);
 
-        this.loadMask = new Ext.LoadMask(ct, {msg: String.format(_('Transferring {0}...'), this.translation.gettext('Tag'))});
+        this.loadMask = new Ext.LoadMask(ct, {msg: String.format(i18n._('Transferring {0}...'), this.translation.gettext('Tag'))});
         this.loadMask.show();
     },
     
index ba1fbd1..4b8cd31 100644 (file)
@@ -133,7 +133,7 @@ Tine.Admin.Tags.Main = {
         var TagsQuickSearchField = new Ext.ux.SearchField({
             id: 'TagsQuickSearchField',
             width: 240,
-            emptyText: Tine.Tinebase.translation._hidden('enter searchfilter')
+            emptyText: i18n._hidden('enter searchfilter')
         });
         
         TagsQuickSearchField.on('change', function () {
@@ -224,7 +224,7 @@ Tine.Admin.Tags.Main = {
             },
             columns: [
                 { id: 'color', header: this.translation.gettext('Color'), dataIndex: 'color', width: 25, renderer: function (color,meta,record) {
-                    return '<div style="margin-top:1px;width: 8px; height: 8px; background-color:' + color + '; border-radius:5px;border: 1px solid black;" title="' + record.get('name') + ' (' +  _('Usage:&#160;') + record.get('occurrence') + ')">&#160;</div>';
+                    return '<div style="margin-top:1px;width: 8px; height: 8px; background-color:' + color + '; border-radius:5px;border: 1px solid black;" title="' + record.get('name') + ' (' +  i18n._('Usage:&#160;') + record.get('occurrence') + ')">&#160;</div>';
                 }},
                 { id: 'name', header: this.translation.gettext('Name'), dataIndex: 'name', width: 200 },
                 { id: 'description', header: this.translation.gettext('Description'), dataIndex: 'description', width: 500}
index b85dc6a..f18f402 100644 (file)
@@ -46,7 +46,7 @@ Tine.Admin.config.FieldManager = function() {
                             allowEmpty: false,
                             triggerAction: 'all',
                             editable: false,
-                            store: [[true, _('Yes')], [false, _('No')]]
+                            store: [[true, i18n._('Yes')], [false, i18n._('No')]]
                         }, options);
                         constr = Ext.form.ComboBox;
                         break;
index a0ff09c..c588ede 100644 (file)
@@ -135,7 +135,7 @@ Tine.Admin.CustomfieldEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
      */
     onApplyChanges: function () {
         if (this.fieldsWithStore.indexOf(this.fieldType) !== -1 && ! this[this.fieldType + 'Config']) {
-            Ext.Msg.alert(_('Errors'), this.app.i18n._('Please configure store for this field type'));
+            Ext.Msg.alert(i18n._('Errors'), this.app.i18n._('Please configure store for this field type'));
             return;
         }
         
@@ -271,7 +271,7 @@ Tine.Admin.CustomfieldEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
                 try {
                     var model = eval(this.items.get(1).getValue());
                 } catch (e) {
-                    Ext.Msg.alert(_('Errors'), self.app.i18n._('Given record class not found'));
+                    Ext.Msg.alert(i18n._('Errors'), self.app.i18n._('Given record class not found'));
                     return false;
                 }
                 
@@ -304,13 +304,13 @@ Tine.Admin.CustomfieldEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
             border: false,
             items: this['init' + (this.fieldType.charAt(0).toUpperCase() + this.fieldType.substr(1)) + 'Store'](),
             fbar: ['->', {
-                text: _('Cancel'),
+                text: i18n._('Cancel'),
                 minWidth: 70,
                 scope: this,
                 handler: this.onStoreWindowClose,
                 iconCls: 'action_cancel'
             }, {
-                text: _('OK'),
+                text: i18n._('OK'),
                 minWidth: 70,
                 scope: this,
                 handler: this.onStoreWindowOK,
index 629db2f..003ba8a 100644 (file)
@@ -282,7 +282,7 @@ Tine.Admin.UserEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
                 return new Ext.grid.ColumnModel({
                     defaults: { sortable: true },
                     columns:  [
-                        {id: 'name', header: _('Name'), dataIndex: this.recordPrefix + 'name', renderer: function (val, meta, record) {
+                        {id: 'name', header: i18n._('Name'), dataIndex: this.recordPrefix + 'name', renderer: function (val, meta, record) {
                             return record.data.id === self.getCurrentPrimaryGroupId() ? (record.data.name + '<span class="x-item-disabled"> (' + self.app.i18n.gettext('Primary group') + ')<span>') : record.data.name;
                         }}
                     ]
@@ -318,7 +318,7 @@ Tine.Admin.UserEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
             autoExpandColumn: 'name',
             store: this.storeRoles,
             recordClass: Tine.Tinebase.Model.Role,
-            columns: [{id: 'name', header: Tine.Tinebase.translation.gettext('Name'), sortable: true, dataIndex: 'name'}],
+            columns: [{id: 'name', header: i18n.gettext('Name'), sortable: true, dataIndex: 'name'}],
             initActionsAndToolbars: function () {
                 // for now removed abillity to edit role membership
 //                Tine.widgets.grid.PickerGridPanel.prototype.initActionsAndToolbars.call(this);
@@ -733,14 +733,14 @@ Tine.Admin.UserEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
                     value: this.app.i18n.gettext('Passwords do not match!')
                 }],
                 buttons: [{
-                    text: _('Cancel'),
+                    text: i18n._('Cancel'),
                     iconCls: 'action_cancel',
                     scope: this,
                     handler: function () {
                         this.passwordConfirmWindow.hide();
                     }
                 }, {
-                    text: _('Ok'),
+                    text: i18n._('Ok'),
                     formBind: true,
                     iconCls: 'action_saveAndClose',
                     scope: this,
index 3f94caa..b938552 100644 (file)
@@ -25,7 +25,7 @@ Tine.Calendar.AttendeeFilterGrid = Ext.extend(Tine.Calendar.AttendeeGridPanel, {
     showMemberOfType: true,
     stateId: 'calendar-attendee-filter-grid',
     cls: 'x-cal-attendee-filter-grid',
-    addNewAttendeeText: 'Add attendee', // _('Add attendee')
+    addNewAttendeeText: 'Add attendee', // i18n._('Add attendee')
     
     enableDragDrop: true,
     ddGroup: 'Tine.Calendar.AttendeeFilterGrid.Sort',
index 3c9932d..fca370a 100644 (file)
@@ -23,7 +23,7 @@ Tine.Calendar.AttendeeGridPanel = Ext.extend(Ext.grid.EditorGridPanel, {
     
     /**
      * @cfg defaut text for new attendee combo
-     * _('Click here to invite another attender...')
+     * i18n._('Click here to invite another attender...')
      */
     addNewAttendeeText: 'Click here to invite another attender...',
     
@@ -149,7 +149,7 @@ Tine.Calendar.AttendeeGridPanel = Ext.extend(Ext.grid.EditorGridPanel, {
             width: 200,
             sortable: false,
             hidden: this.showNamesOnly || true,
-            header: Tine.Tinebase.translation._hidden('Saved in'),
+            header: i18n._hidden('Saved in'),
             tooltip: this.app.i18n._('This is the calendar where the attender has saved this event in'),
             renderer: this.renderAttenderDispContainer.createDelegate(this),
             // disable for the moment, as updating calendarSelectWidget is not working in both directions
index 9cf1608..908203d 100644 (file)
@@ -26,7 +26,7 @@ Ext.onReady(function(){
 Tine.Calendar.Application = Ext.extend(Tine.Tinebase.Application, {
     
     /**
-     * auto hook text _('New Event')
+     * auto hook text i18n._('New Event')
      */
     addButtonText: 'New Event',
     
index 112b419..d27f2f9 100644 (file)
@@ -120,12 +120,12 @@ Ext.extend(Tine.Calendar.DaysView, Ext.Container, {
     wheelIncrement: 50,
     /**
      * @cfg {String} newEventSummary
-     * _('New Event')
+     * i18n._('New Event')
      */
     newEventSummary: 'New Event',
     /**
      * @cfg {String} dayFormatString
-     * _('{0}, the {1}. of {2}')
+     * i18n._('{0}, the {1}. of {2}')
      */
     dayFormatString: '{0}, the {1}. of {2}',
     /**
index 6cfea36..3739318 100644 (file)
@@ -117,13 +117,13 @@ Tine.Calendar.EventContextAttendeesItem = Ext.extend(Ext.menu.Item, {
                 layout: 'fit',
                 items: this.attendeeGridPanel,
                 buttons: [{
-                    text: _('Cancel'),
+                    text: i18n._('Cancel'),
                     minWidth: 70,
                     scope: this,
                     handler: function (btn) {win.close()},
                     iconCls: 'action_cancel'
                 }, {
-                    text: _('Ok'),
+                    text: i18n._('Ok'),
                     minWidth: 70,
                     scope: this,
                     handler: function(btn) {
index 091f833..15c25ca 100644 (file)
@@ -25,7 +25,7 @@ Tine.Calendar.EventDetailsPanel = Ext.extend(Tine.widgets.grid.DetailsPanel, {
      */
     attendeeRenderer: function(attendeeData) {
         if (! attendeeData) {
-            return _('No Information');
+            return i18n._('No Information');
         }
         var attendeeStore = Tine.Calendar.Model.Attender.getAttendeeStore(attendeeData);
         
index e2bbb50..52dbe06 100644 (file)
@@ -161,7 +161,7 @@ Tine.Calendar.EventEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
                                 }], [ this.containerSelectCombo = new Tine.widgets.container.selectionComboBox({
                                     columnWidth: 1,
                                     id: this.app.appName + 'EditDialogContainerSelector' + Ext.id(),
-                                    fieldLabel: _('Saved in'),
+                                    fieldLabel: i18n._('Saved in'),
                                     ref: '../../../../../../../../containerSelect',
                                     //width: 300,
                                     //listWidth: 300,
@@ -629,7 +629,7 @@ Tine.Calendar.EventEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
         } else {
             this.saving = false;
             this.loadMask.hide();
-            Ext.MessageBox.alert(_('Errors'), this.getValidationErrorMessage());
+            Ext.MessageBox.alert(i18n._('Errors'), this.getValidationErrorMessage());
         }
     }
 });
index 0a2a618..e6d23ae 100644 (file)
@@ -136,15 +136,15 @@ Tine.Calendar.ImportDialog = Ext.extend(Tine.widgets.dialog.ImportDialog, {
             baseCls: 'ux-subformpanel',
             id: 'uploadPanel',
             hidden: true,
-            title: _('Choose Import File'),
+            title: i18n._('Choose Import File'),
             height: 100,
             items: [{
                 xtype: 'label',
-                html: '<p>' + _('Please choose the file that contains the records you want to add to Tine 2.0') + '</p><br />'
+                html: '<p>' + i18n._('Please choose the file that contains the records you want to add to Tine 2.0') + '</p><br />'
             }, {
                 xtype: 'tw.uploadbutton',
                 ref: '../../uploadButton',
-                text: String.format(_('Select file containing your {0}'), this.recordClass.getRecordsName()),
+                text: String.format(i18n._('Select file containing your {0}'), this.recordClass.getRecordsName()),
                 handler: this.onFileReady,
                 allowedTypes: this.allowedFileExtensions,
                 scope: this
@@ -381,7 +381,7 @@ Tine.Calendar.ImportDialog = Ext.extend(Tine.widgets.dialog.ImportDialog, {
         
         var types = [
             ['remote_ics', this.app.i18n._('Remote / ICS')],
-            ['remote_caldav', _('Remote / CalDAV (BETA)')],
+            ['remote_caldav', i18n._('Remote / CalDAV (BETA)')],
             ['upload', this.app.i18n._('Upload')]
         ]
         
@@ -472,7 +472,7 @@ Tine.Calendar.ImportDialog = Ext.extend(Tine.widgets.dialog.ImportDialog, {
             */
             onFinishButton: (function() {
                 if (! this.importMask) {
-                    this.importMask = new Ext.LoadMask(this.getEl(), {msg: String.format(_('Importing {0}'), this.recordClass.getRecordsName())});
+                    this.importMask = new Ext.LoadMask(this.getEl(), {msg: String.format(i18n._('Importing {0}'), this.recordClass.getRecordsName())});
                 }
                 this.importMask.show();
 
index f2545a7..7b3751c 100644 (file)
@@ -25,7 +25,7 @@ Tine.Calendar.MainScreenCenterPanel = Ext.extend(Ext.Panel, {
     
     /**
      * @cfg {String} loadMaskText
-     * _('Loading events, please wait...')
+     * i18n._('Loading events, please wait...')
      */
     loadMaskText: 'Loading events, please wait...',
     
@@ -134,7 +134,7 @@ Tine.Calendar.MainScreenCenterPanel = Ext.extend(Ext.Panel, {
     initActions: function () {
         this.action_editInNewWindow = new Ext.Action({
             requiredGrant: 'readGrant',
-            text: this.i18nEditActionText ? this.app.i18n._hidden(this.i18nEditActionText) : String.format(Tine.Tinebase.translation._hidden('Edit {0}'), this.i18nRecordName),
+            text: this.i18nEditActionText ? this.app.i18n._hidden(this.i18nEditActionText) : String.format(i18n._hidden('Edit {0}'), this.i18nRecordName),
             disabled: true,
             handler: this.onEditInNewWindow.createDelegate(this, ["edit"]),
             iconCls: 'action_edit'
@@ -142,7 +142,7 @@ Tine.Calendar.MainScreenCenterPanel = Ext.extend(Ext.Panel, {
         
         this.action_addInNewWindow = new Ext.Action({
             requiredGrant: 'addGrant',
-            text: this.i18nAddActionText ? this.app.i18n._hidden(this.i18nAddActionText) : String.format(Tine.Tinebase.translation._hidden('Add {0}'), this.i18nRecordName),
+            text: this.i18nAddActionText ? this.app.i18n._hidden(this.i18nAddActionText) : String.format(i18n._hidden('Add {0}'), this.i18nRecordName),
             handler: this.onEditInNewWindow.createDelegate(this, ["add"]),
             iconCls: 'action_add'
         });
@@ -172,10 +172,10 @@ Tine.Calendar.MainScreenCenterPanel = Ext.extend(Ext.Panel, {
         this.action_deleteRecord = new Ext.Action({
             requiredGrant: 'deleteGrant',
             allowMultiple: true,
-            singularText: this.i18nDeleteActionText ? i18nDeleteActionText[0] : String.format(Tine.Tinebase.translation.n_hidden('Delete {0}', 'Delete {0}', 1), this.i18nRecordName),
-            pluralText: this.i18nDeleteActionText ? i18nDeleteActionText[1] : String.format(Tine.Tinebase.translation.n_hidden('Delete {0}', 'Delete {0}', 1), this.i18nRecordsName),
-            translationObject: this.i18nDeleteActionText ? this.app.i18n : Tine.Tinebase.translation,
-            text: this.i18nDeleteActionText ? this.i18nDeleteActionText[0] : String.format(Tine.Tinebase.translation.n_hidden('Delete {0}', 'Delete {0}', 1), this.i18nRecordName),
+            singularText: this.i18nDeleteActionText ? i18nDeleteActionText[0] : String.format(i18n.n_hidden('Delete {0}', 'Delete {0}', 1), this.i18nRecordName),
+            pluralText: this.i18nDeleteActionText ? i18nDeleteActionText[1] : String.format(i18n.n_hidden('Delete {0}', 'Delete {0}', 1), this.i18nRecordsName),
+            translationObject: this.i18nDeleteActionText ? this.app.i18n : i18n,
+            text: this.i18nDeleteActionText ? this.i18nDeleteActionText[0] : String.format(i18n.n_hidden('Delete {0}', 'Delete {0}', 1), this.i18nRecordName),
             handler: this.onDeleteRecords,
             disabled: true,
             iconCls: 'action_delete',
@@ -631,7 +631,7 @@ Tine.Calendar.MainScreenCenterPanel = Ext.extend(Ext.Panel, {
             }
             
             addAction = {
-                text: this.i18nAddActionText ? this.app.i18n._hidden(this.i18nAddActionText) : String.format(Tine.Tinebase.translation._hidden('Add {0}'), this.i18nRecordName),
+                text: this.i18nAddActionText ? this.app.i18n._hidden(this.i18nAddActionText) : String.format(i18n._hidden('Add {0}'), this.i18nRecordName),
                 handler: this.onEditInNewWindow.createDelegate(this, ["add", null, null, {dtStart: dtStart, is_all_day_event: datetime && datetime.is_all_day_event}]),
                 iconCls: 'action_add'
             };
@@ -1103,7 +1103,7 @@ Tine.Calendar.MainScreenCenterPanel = Ext.extend(Ext.Panel, {
         
         // else
         var i18nQuestion = String.format(this.app.i18n.ngettext('Do you really want to delete this event?', 'Do you really want to delete the {0} selected events?', selection.length), selection.length);
-        Ext.MessageBox.confirm(Tine.Tinebase.translation._hidden('Confirm'), i18nQuestion, function (btn) {
+        Ext.MessageBox.confirm(i18n._hidden('Confirm'), i18nQuestion, function (btn) {
             if (btn === 'yes') {
                 this.onDeleteRecordsConfirmNonRecur(panel, selection);
             } else {
@@ -1129,7 +1129,7 @@ Tine.Calendar.MainScreenCenterPanel = Ext.extend(Ext.Panel, {
             },
             failure: function () {
                 panel.getTopToolbar().onLoad();
-                Ext.MessageBox.alert(Tine.Tinebase.translation._hidden('Failed'), String.format(this.app.i18n.n_('Failed to delete event', 'Failed to delete the {0} events', selection.length), selection.length));
+                Ext.MessageBox.alert(i18n._hidden('Failed'), String.format(this.app.i18n.n_('Failed to delete event', 'Failed to delete the {0} events', selection.length), selection.length));
             }
         };
         
index 81a1c6b..9649942 100644 (file)
@@ -314,7 +314,7 @@ Tine.Calendar.Model.Event.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Calendar');
     
     return [
-        {label: _('Quick Search'), field: 'query', operators: ['contains']},
+        {label: i18n._('Quick Search'), field: 'query', operators: ['contains']},
         {label: app.i18n._('Summary'), field: 'summary'},
         {label: app.i18n._('Location'), field: 'location'},
         {label: app.i18n._('Description'), field: 'description'},
@@ -360,14 +360,14 @@ Tine.widgets.grid.ForeignRecordFilter.OperatorRegistry.register('Addressbook', '
     foreignRecordClass: 'Calendar.Event',
     linkType: 'foreignId', 
     filterName: 'ContactAttendeeFilter',
-    // _('Event (as attendee)')
+    // i18n._('Event (as attendee)')
     label: 'Event (as attendee)'
 });
 Tine.widgets.grid.ForeignRecordFilter.OperatorRegistry.register('Addressbook', 'Contact', {
     foreignRecordClass: 'Calendar.Event',
     linkType: 'foreignId', 
     filterName: 'ContactOrganizerFilter',
-    // _('Event (as organizer)')
+    // i18n._('Event (as organizer)')
     label: 'Event (as organizer)'
 });
 
@@ -377,7 +377,7 @@ Tine.widgets.grid.ForeignRecordFilter.OperatorRegistry.register('Addressbook', '
 //    foreignRecordClass: 'Calendar.Event',
 //    linkType: 'foreignId', 
 //    filterName: 'ContactAttendeeFilter',
-//    // _('Event attendee')
+//    // i18n._('Event attendee')
 //    label: 'Event attendee'
 //});
 
index 16f4fe2..70e4656 100644 (file)
@@ -80,17 +80,17 @@ Ext.extend(Tine.Calendar.MonthView, Ext.Container, {
     startDate: new Date().clearTime(),
     /**
      * @cfg {String} newEventSummary
-     * _('New Event')
+     * i18n._('New Event')
      */
     newEventSummary: 'New Event',
     /**
      * @cfg {String} calWeekString
-     * _('WK')
+     * i18n._('WK')
      */
     calWeekString: 'WK',
     /**
      * @cfg String moreString
-     * _('{0} more...')
+     * i18n._('{0} more...')
      */
     moreString: '{0} more...',
     /**
index fdc48be..e1cdf15 100644 (file)
@@ -68,7 +68,7 @@ Tine.Calendar.SearchCombo = Ext.extend(Ext.ux.form.ClearableComboBox, {
         }
 
         this.listEmptyText = this.app.i18n._('no events found');
-        this.loadingText = _('Searching...');
+        this.loadingText = i18n._('Searching...');
 
         this.recordClass = Tine.Calendar.Model.Event;
         this.recordProxy = Tine.Calendar.backend;
index 283dd81..1bd8104 100644 (file)
@@ -80,12 +80,12 @@ Ext.extend(Tine.Calendar.YearView, Ext.Container, {
     startDate: new Date().clearTime(),
     /**
      * @cfg {String} newEventSummary
-     * _('New Event')
+     * i18n._('New Event')
      */
     newEventSummary: 'New Event',
     /**
      * @cfg String moreString
-     * _('{0} more...')
+     * i18n._('{0} more...')
      */
     moreString: '{0} more...',
     /**
index 1b297a8..35b236b 100644 (file)
@@ -115,7 +115,7 @@ Tine.Courses.AddMemberDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
             }, this);
             
         } else {
-            Ext.MessageBox.alert(_('Errors'), _('Please fix the errors noted.'));
+            Ext.MessageBox.alert(i18n._('Errors'), i18n._('Please fix the errors noted.'));
         }
     }
 });
index da70bf6..7113193 100644 (file)
@@ -284,12 +284,12 @@ Tine.Courses.CourseEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
                 width: 200,
                 dataIndex: 'data',
                 renderer: function(value) {
-                    return (value.account_id) ? _('unknown') : value;
+                    return (value.account_id) ? i18n._('unknown') : value;
                 }
             }];
             
             var action_resetPwd = new Ext.Action({
-                text: _('Reset Password'),
+                text: i18n._('Reset Password'),
                 scope: this,
                 handler: function(_button, _event) {
                     this.loadMask.show();
index 2eb080e..28bbd62 100644 (file)
@@ -68,7 +68,7 @@ Tine.Courses.Model.Course.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Courses');
     
     return [
-        {label: _('Quick Search'),    field: 'query',       operators: ['contains']},
+        {label: i18n._('Quick Search'),    field: 'query',       operators: ['contains']},
         {label: app.i18n._('Name'),   field: 'name'},
         {
             label: app.i18n._('Internet Access'),
index c75a755..a7cf47b 100644 (file)
@@ -21,7 +21,7 @@ Ext.ns('Tine.Crm');
 Tine.Crm.Application = Ext.extend(Tine.Tinebase.Application, {
     
     /**
-     * auto hook text _('New Lead')
+     * auto hook text i18n._('New Lead')
      */
     addButtonText: 'New Lead',
     
index c5d116b..57fa82c 100644 (file)
@@ -97,7 +97,7 @@ Tine.Crm.Model.Lead.getDefaultData = function() {
 Tine.Crm.Model.Lead.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Crm'),
         filters = [
-            {label: _('Quick Search'),  field: 'query',    operators: ['contains']},
+            {label: i18n._('Quick Search'),  field: 'query',    operators: ['contains']},
             {filtertype: 'tine.widget.container.filtermodel', app: app, recordClass: Tine.Crm.Model.Lead},
             {label: app.i18n._('Lead name'),   field: 'lead_name' },
             {
@@ -117,10 +117,10 @@ Tine.Crm.Model.Lead.getFilterModel = function() {
             },
             {label: app.i18n._('Turnover'),    field: 'turnover', valueType: 'number', defaultOperator: 'greater'},
             {filtertype: 'tinebase.tag', app: app},
-            {label: _('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
-            {label: _('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
-            {label: _('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
-            {label: _('Created By'),                                                        field: 'created_by',         valueType: 'user'},
+            {label: i18n._('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
+            {label: i18n._('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
+            {label: i18n._('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
+            {label: i18n._('Created By'),                                                        field: 'created_by',         valueType: 'user'},
             
             {label: app.i18n._('Estimated end'), field: 'end_scheduled', valueType: 'date'},
             {label: app.i18n._('Resubmission Date'), field: 'resubmission_date', valueType: 'date'},
@@ -145,8 +145,8 @@ Tine.Crm.Model.LeadState = Tine.Tinebase.data.Record.create([
     { name: 'id' },
     { name: 'value' },
     { name: 'system' },
-    { name: 'probability', label: 'Probability', type: 'percentage' }, // _('Probability')
-    { name: 'endslead', label: 'X Lead', type: 'bool'} // _('X Lead')
+    { name: 'probability', label: 'Probability', type: 'percentage' }, // i18n._('Probability')
+    { name: 'endslead', label: 'X Lead', type: 'bool'} // i18n._('X Lead')
 ], {
     appName: 'Crm',
     modelName: 'LeadState',
@@ -159,7 +159,7 @@ Tine.Crm.Model.LeadSource = Tine.Tinebase.data.Record.create([
     { name: 'id' },
     { name: 'value' },
     { name: 'system' },
-    { name: 'archived', label: 'Archived', type: 'bool' } // _('Archived')
+    { name: 'archived', label: 'Archived', type: 'bool' } // i18n._('Archived')
 ], {
     appName: 'Crm',
     modelName: 'LeadSource',
index 5896a74..a0918ec 100644 (file)
@@ -20,7 +20,7 @@ Ext.ns('Tine', 'Tine.Example');
  */
 Tine.Example.Application = Ext.extend(Tine.Tinebase.Application, {
     /**
-     * auto hook text _('New Example')
+     * auto hook text i18n._('New Example')
      */
     addButtonText: 'New Example'
 });
index ce514ec..0dfdd55 100644 (file)
@@ -86,7 +86,7 @@ Tine.Expressodriver.AdminPanel = Ext.extend(Tine.widgets.dialog.EditDialog, {
             return;
         }
 
-        this.window.setTitle(String.format(_('Change settings for application {0}'), this.appName));
+        this.window.setTitle(String.format(i18n._('Change settings for application {0}'), this.appName));
 
         if (this.fireEvent('load', this) !== false) {
             var defaultSettings = this.record.get('default'),
@@ -155,7 +155,7 @@ Tine.Expressodriver.AdminPanel = Ext.extend(Tine.widgets.dialog.EditDialog, {
         } else {
             this.saving = false;
             this.loadMask.hide();
-            Ext.MessageBox.alert(_('Errors'), this.getValidationErrorMessage());
+            Ext.MessageBox.alert(i18n._('Errors'), this.getValidationErrorMessage());
         }
     },
 
index a2d879c..ac846c4 100644 (file)
@@ -33,7 +33,7 @@ Tine.Expressodriver.handleRequestException = function(exception, request) {
             Ext.MessageBox.show({
                 buttons: Ext.Msg.OK,
                 icon: Ext.MessageBox.WARNING,
-                title: _('Service Unavailable'),
+                title: i18n._('Service Unavailable'),
                 msg: String.format(app.i18n._('The Expressodriver is not configured correctly. Please refer to the {0}Tine 2.0 Admin FAQ{1} for configuration advice or contact your administrator.'),
                     '<a href="http://www.tine20.org/wiki/index.php/Admin_FAQ#The_message_.22filesdir_config_value_not_set.22_appears_in_the_logfile_and_I_can.27t_open_the_Expressodriver" target="_blank">',
                     '</a>')
index 5fb761d..3f90b85 100644 (file)
@@ -43,7 +43,7 @@ Tine.Expressodriver.Application = Ext.extend(Tine.Tinebase.Application, {
  * register additional action for genericpickergridpanel
  */
 Tine.widgets.relation.MenuItemManager.register('Expressodriver', 'Node', {
-    text: 'Save locally',   // _('Save locally')
+    text: 'Save locally',   // i18n._('Save locally')
     iconCls: 'action_expressodriver_save_all',
     requiredGrant: 'readGrant',
     actionType: 'download',
index 8287f25..f14d96a 100644 (file)
@@ -45,7 +45,7 @@ Tine.Expressodriver.ExternalAdapterEditDialog = Ext.extend(Tine.widgets.dialog.E
             this.window.close();
 
         } else {
-            Ext.MessageBox.alert(_('Errors'), _('Please fix the errors noted.'));
+            Ext.MessageBox.alert(i18n._('Errors'), i18n._('Please fix the errors noted.'));
         }
     },
     getFormItems: function() {
index 41504bb..3a63856 100644 (file)
@@ -36,13 +36,13 @@ Tine.Expressodriver.GridContextMenu = {
 
             Ext.MessageBox.show({
                 title: this.scope.app.i18n._('Rename') + ' ' + this.nodeName,
-                msg: String.format(_('Please enter the new name of the {0}:'), this.nodeName),
+                msg: String.format(i18n._('Please enter the new name of the {0}:'), this.nodeName),
                 buttons: Ext.MessageBox.OKCANCEL,
                 value: nodeText,
                 fn: function(_btn, _text){
                     if (_btn == 'ok') {
                         if (! _text) {
-                            Ext.Msg.alert(String.format(this.scope.app.i18n._('Not renamed {0}'), this.nodeName), String.format(_('You have to supply a {0} name!'), this.nodeName));
+                            Ext.Msg.alert(String.format(this.scope.app.i18n._('Not renamed {0}'), this.nodeName), String.format(i18n._('You have to supply a {0} name!'), this.nodeName));
                             return;
                         }
                         if (_text === nodeText) {
@@ -69,7 +69,7 @@ Tine.Expressodriver.GridContextMenu = {
                             params.destinationFilenames = [targetFilename + _text];
                             params.method = this.backend + '.moveNodes';
                         }
-                        Ext.MessageBox.wait(_('Please wait'), this.scope.app.i18n._('Renaming nodes...' ));
+                        Ext.MessageBox.wait(i18n._('Please wait'), this.scope.app.i18n._('Renaming nodes...' ));
                         Ext.Ajax.request({
                             params: params,
                             scope: this,
@@ -172,7 +172,7 @@ Tine.Expressodriver.GridContextMenu = {
                             params.filenames = filenames;
                             params.method = this.backend + ".deleteNodes";
                         }
-                        Ext.MessageBox.wait(_('Please wait'), this.scope.app.i18n._('Deleting nodes...' ));
+                        Ext.MessageBox.wait(i18n._('Please wait'), this.scope.app.i18n._('Deleting nodes...' ));
                         Ext.Ajax.request({
                             params: params,
                             scope: this,
index e978697..e62eedf 100644 (file)
@@ -207,7 +207,7 @@ Tine.Expressodriver.fileRecordBackend =  new Tine.Tinebase.data.RecordProxy({
 
         }).createDelegate({items: items});
         var app = Tine.Tinebase.appMgr.get(this.appName);
-        Ext.MessageBox.wait(_('Please wait'), app.i18n._('Deleting nodes...' ));
+        Ext.MessageBox.wait(i18n._('Please wait'), app.i18n._('Deleting nodes...' ));
         return this.doXHTTPRequest(options);
     },
 
@@ -291,7 +291,7 @@ Tine.Expressodriver.fileRecordBackend =  new Tine.Tinebase.data.RecordProxy({
             }
         }
 
-        this.loadMask = new Ext.LoadMask(app.getMainScreen().getCenterPanel().getEl(), {msg: String.format(_('Please wait')) + '. ' + String.format(message, '' )});
+        this.loadMask = new Ext.LoadMask(app.getMainScreen().getCenterPanel().getEl(), {msg: String.format(i18n._('Please wait')) + '. ' + String.format(message, '' )});
         app.getMainScreen().getWestPanel().setDisabled(true);
         app.getMainScreen().getNorthPanel().setDisabled(true);
         this.loadMask.show();
@@ -517,7 +517,7 @@ Tine.Expressodriver.Model.Node.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Expressodriver');
 
     return [
-        {label : _('Quick Search'), field : 'query', operators : [ 'contains' ]},
+        {label : i18n._('Quick Search'), field : 'query', operators : [ 'contains' ]},
         {filtertype : 'tine.expressodriver.pathfiltermodel', app : app}
     ];
 };
index 186a472..664b520 100644 (file)
@@ -342,7 +342,7 @@ Tine.Expressodriver.NodeGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
             allowMultiple: true,
             singularText: this.app.i18n._('Delete'),
             pluralText: this.app.i18n._('Delete'),
-            translationObject: this.i18nDeleteActionText ? this.app.i18n : Tine.Tinebase.translation,
+            translationObject: this.i18nDeleteActionText ? this.app.i18n : i18n,
             text: this.app.i18n._('Delete'),
             handler: this.onDeleteRecords,
             disabled: true,
@@ -492,7 +492,7 @@ Tine.Expressodriver.NodeGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
                     Ext.Msg.alert(String.format(this.app.i18n._('No {0} added'), nodeName), String.format(this.app.i18n._('You have to supply a {0} name!'), nodeName));
                     return;
                 }
-                Ext.MessageBox.wait(_('Please wait'), String.format(_('Creating {0}...' ), nodeName));
+                Ext.MessageBox.wait(i18n._('Please wait'), String.format(i18n._('Creating {0}...' ), nodeName));
                 var filename = currentFolderNode.attributes.path + '/' + _text;
                 Tine.Expressodriver.fileRecordBackend.createFolder(filename);
 
@@ -627,8 +627,8 @@ Tine.Expressodriver.NodeGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
      */
     onUploadFail: function () {
         Ext.MessageBox.alert(
-            _('Upload Failed'),
-            _('Could not upload file. Filesize could be too big. Please notify your Administrator. Max upload size:') + ' '
+            i18n._('Upload Failed'),
+            i18n._('Could not upload file. Filesize could be too big. Please notify your Administrator. Max upload size:') + ' '
             + Tine.Tinebase.common.byteRenderer(Tine.Tinebase.registry.get('maxFileUploadSize'))
         ).setIcon(Ext.MessageBox.ERROR);
 
@@ -779,7 +779,7 @@ Tine.Expressodriver.NodeGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
 
         if(!nodeRecord.isDropFilesAllowed()) {
             Ext.MessageBox.alert(
-                    _('Upload Failed'),
+                    i18n._('Upload Failed'),
                     app.i18n._('Putting files in this folder is not allowed!')
             ).setIcon(Ext.MessageBox.ERROR);
 
index 0f11c26..3562573 100644 (file)
@@ -694,8 +694,8 @@ Ext.extend(Tine.Expressodriver.NodeTreePanel, Tine.widgets.container.TreePanel,
      */
     onUploadFail: function () {
         Ext.MessageBox.alert(
-            _('Upload Failed'),
-            _('Could not upload file. Filesize could be too big. Please notify your Administrator. Max upload size:') + ' ' + Tine.Tinebase.registry.get('maxFileUploadSize')
+            i18n._('Upload Failed'),
+            i18n._('Could not upload file. Filesize could be too big. Please notify your Administrator. Max upload size:') + ' ' + Tine.Tinebase.registry.get('maxFileUploadSize')
         ).setIcon(Ext.MessageBox.ERROR);
     },
 
@@ -718,7 +718,7 @@ Ext.extend(Tine.Expressodriver.NodeTreePanel, Tine.widgets.container.TreePanel,
      */
     onBeforeFolderRename: function(node) {
         var app = Tine.Tinebase.appMgr.get('Expressodriver');
-        Ext.MessageBox.wait(_('Please wait'), app.i18n._('Renaming nodes...' ));
+        Ext.MessageBox.wait(i18n._('Please wait'), app.i18n._('Renaming nodes...' ));
     },
 
     /**
@@ -813,7 +813,7 @@ Ext.extend(Tine.Expressodriver.NodeTreePanel, Tine.widgets.container.TreePanel,
 
         if(!targetNode.attributes.nodeRecord.isDropFilesAllowed()) {
             Ext.MessageBox.alert(
-                    _('Upload Failed'),
+                    i18n._('Upload Failed'),
                     app.i18n._('Putting files in this folder is not allowed!')
                 ).setIcon(Ext.MessageBox.ERROR);
 
index 56f905a..9084195 100644 (file)
@@ -80,7 +80,7 @@ Tine.Expressomail.AccountEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog,
     onUploadSuccess : function(dialog, filename, resp_data, record) {
         if (resp_data.size > 16384) {
             // exceeded maximum image size for the signature
-            dialog.showMessage( _('Error'), _('Signature image size cannot exceed 16384 bytes.') );
+            dialog.showMessage( i18n._('Error'), i18n._('Signature image size cannot exceed 16384 bytes.') );
         }
         else {
             var cmp = dialog.cmp;
index 738f822..f44a477 100644 (file)
@@ -79,7 +79,7 @@ Tine.Expressomail.AclsEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
      * on dialog show
      */
     onShow: function() {
-        this.aclsLoadMask = new Ext.LoadMask(this.ownerCt.container, {msg: _('Loading ...')});
+        this.aclsLoadMask = new Ext.LoadMask(this.ownerCt.container, {msg: i18n._('Loading ...')});
         this.aclStore.load();
     },
 
@@ -106,7 +106,7 @@ Tine.Expressomail.AclsEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
      * @private
      */
     onApplyChanges: function(button, event, closeWindow) {
-        Ext.MessageBox.wait(_('Please wait'), _('Updating Grants'));
+        Ext.MessageBox.wait(i18n._('Please wait'), i18n._('Updating Grants'));
 
         var acls = [];
         this.aclStore.each(function(_record){
@@ -138,8 +138,8 @@ Tine.Expressomail.AclsEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
 
                 if (responseText.data.code == 505) {
                     Ext.Msg.show({
-                       title:   _('Error'),
-                       msg:     _('You are not allowed to remove all admins for this container!'),
+                       title:   i18n._('Error'),
+                       msg:     i18n._('You are not allowed to remove all admins for this container!'),
                        icon:    Ext.MessageBox.ERROR,
                        buttons: Ext.Msg.OK
                     });
index a92c998..29bda6a 100644 (file)
@@ -50,20 +50,20 @@ Tine.Expressomail.AclsGrid = Ext.extend(Tine.widgets.account.PickerGridPanel, {
     initColumns: function() {
         this.configColumns = [
             new Ext.ux.grid.CheckColumn({
-                header: _('Read'),
-                tooltip: _('Read messages from folders'),
+                header: i18n._('Read'),
+                tooltip: i18n._('Read messages from folders'),
                 dataIndex: 'readacl',
                 width: 55
             }),
             new Ext.ux.grid.CheckColumn({
-                header: _('Write'),
-                tooltip: _('Write and delete messages from folders'),
+                header: i18n._('Write'),
+                tooltip: i18n._('Write and delete messages from folders'),
                 dataIndex: 'writeacl',
                 width: 55
             }),
             new Ext.ux.grid.CheckColumn({
-                header: _('Send as'),
-                tooltip: _('Send as folder owner'),
+                header: i18n._('Send as'),
+                tooltip: i18n._('Send as folder owner'),
                 dataIndex: 'sendacl',
                 width: 55
             })            
index 0387673..46ebe1a 100644 (file)
@@ -133,7 +133,7 @@ Ext.apply(Tine.Expressomail.AddressbookGridPanelHook.prototype, {
             mailAddresses = [];
             Ext.MessageBox.show({
                 title: '',
-                msg: _('Number of contacts exceeds the maximum of 50 permitted.'),
+                msg: i18n._('Number of contacts exceeds the maximum of 50 permitted.'),
                 buttons: Ext.MessageBox.OK,
                 scope: this,
                 icon: Ext.MessageBox.ERROR
index 5e8138b..803990c 100644 (file)
@@ -121,7 +121,7 @@ Tine.Expressomail.ContactGridPanel = Ext.extend(Tine.Addressbook.ContactGridPane
             ' {checked}',
         '>');
         
-        Ext.each(['To', 'Cc', 'Bcc', 'None'], function(type) { // _('None')
+        Ext.each(['To', 'Cc', 'Bcc', 'None'], function(type) { // i18n._('None')
             columns.push({
                 header: this.expressomailApp.i18n._(type),
                 dataIndex: Ext.util.Format.lowercase(type),
index 1a3c9f7..5556d0a 100644 (file)
@@ -30,7 +30,7 @@ Ext.ns('Tine.Expressomail');
 Tine.Expressomail.Application = Ext.extend(Tine.Tinebase.Application, {
 
     /**
-     * auto hook text _('New Mail')
+     * auto hook text i18n._('New Mail')
      */
     addButtonText: 'New Mail',
 
@@ -104,7 +104,7 @@ Tine.Expressomail.Application = Ext.extend(Tine.Tinebase.Application, {
     verifyTrashToClean: function(account_id) {
         if(!account_id) return;
         if(!Tine.Expressomail.registry.get('preferences').get('deleteFromTrash')) return;
-        Ext.MessageBox.wait(_('Please wait'), _('Verifying trash folder'));
+        Ext.MessageBox.wait(i18n._('Please wait'), i18n._('Verifying trash folder'));
         var params = {
           method: 'Expressomail.deleteMsgsBeforeDate'
         };
@@ -1219,7 +1219,7 @@ Tine.Expressomail.addSecurityApplet = function (id, panel, region) {
     
     if (panel && typeof(panel.securityApplet) === 'undefined') {
         Tine.Expressomail.AppletLoadaded = false;
-        Ext.MessageBox.wait(app.i18n._('Loading Criptography Components...'), _('Please wait!'));
+        Ext.MessageBox.wait(app.i18n._('Loading Criptography Components...'), i18n._('Please wait!'));
         
         Tine.Expressomail.afterAppletLoad = function(){
             Tine.Expressomail.AppletLoadaded = true;
index 0993cda..720ff11 100644 (file)
@@ -72,7 +72,7 @@ Tine.Expressomail.FolderSelectPanel = Ext.extend(Ext.Panel, {
      */
     initActions: function() {
         this.action_cancel = new Ext.Action({
-            text: _('Cancel'),
+            text: i18n._('Cancel'),
             minWidth: 70,
             scope: this,
             handler: this.onCancel,
@@ -81,7 +81,7 @@ Tine.Expressomail.FolderSelectPanel = Ext.extend(Ext.Panel, {
         
         this.action_ok = new Ext.Action({
             disabled: true,
-            text: _('Ok'),
+            text: i18n._('Ok'),
             iconCls: 'action_saveAndClose',
             minWidth: 70,
             handler: this.onOk,
index e526a44..80cbfed 100644 (file)
@@ -438,7 +438,7 @@ Tine.Expressomail.GridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
             allowMultiple: true,
             singularText: this.app.i18n._('Delete'),
             pluralText: this.app.i18n._('Delete'),
-            translationObject: this.i18nDeleteActionText ? this.app.i18n : Tine.Tinebase.translation,
+            translationObject: this.i18nDeleteActionText ? this.app.i18n : i18n,
             text: this.app.i18n._('Delete'),
             handler: this.onDeleteRecords,
             disabled: true,
@@ -884,23 +884,23 @@ Tine.Expressomail.GridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
 
         if (value && value.match(/1/))  
         {
-            icons.push({src: 'images/oxygen/16x16/mimetypes/application-pkcs7-signature.png', qtip: _('Assinado')});  // _('Signed')
+            icons.push({src: 'images/oxygen/16x16/mimetypes/application-pkcs7-signature.png', qtip: i18n._('Assinado')});  // i18n._('Signed')
         }
         if (value && value.match(/2/))
         { 
-            icons.push({src: 'images/oxygen/16x16/actions/encrypted.png', qtip: _('Criptografado')});   //_('Encrypted')
+            icons.push({src: 'images/oxygen/16x16/actions/encrypted.png', qtip: i18n._('Criptografado')});   //_('Encrypted')
         }
         if (value && value.match(/3/))
         {
-            icons.push({src: 'images/oxygen/16x16/mimetypes/application-zip.png', qtip: _('Compactado')});  //_('Compressed')
+            icons.push({src: 'images/oxygen/16x16/mimetypes/application-zip.png', qtip: i18n._('Compactado')});  //_('Compressed')
         }
         if (value && value.match(/4/))
         {
-            icons.push({src: 'images/oxygen/16x16/mimetypes/application-pkcs7-mime.png', qtip: _('Apenas Certificados')});   //_('Certs Only')
+            icons.push({src: 'images/oxygen/16x16/mimetypes/application-pkcs7-mime.png', qtip: i18n._('Apenas Certificados')});   //_('Certs Only')
         }
         if (value && value.match(/5/))
         {
-            icons.push({src: 'images/oxygen/16x16/mimetypes/application-pkcs7-mime.png', qtip: _('pkcs7-mime')});
+            icons.push({src: 'images/oxygen/16x16/mimetypes/application-pkcs7-mime.png', qtip: i18n._('pkcs7-mime')});
         }
 
         Ext.each(icons, function(icon) {
@@ -941,17 +941,17 @@ Tine.Expressomail.GridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
             result = '';
        
         if (record.get('reading_conf')) {
-            icons.push({src: 'images/oxygen/16x16/actions/mail-mark-task.png', qtip: Ext.util.Format.htmlEncode(_('Confirmação de Leitura'))});  //_('Reading Confirmation')
+            icons.push({src: 'images/oxygen/16x16/actions/mail-mark-task.png', qtip: Ext.util.Format.htmlEncode(i18n._('Confirmação de Leitura'))});  //_('Reading Confirmation')
         }
 
         if (record.hasFlag('\\Answered')) {
-            icons.push({src: 'images/oxygen/16x16/actions/mail-reply-sender.png', qtip: Ext.util.Format.htmlEncode(_('Respondida'))}); //_('Answered')
+            icons.push({src: 'images/oxygen/16x16/actions/mail-reply-sender.png', qtip: Ext.util.Format.htmlEncode(i18n._('Respondida'))}); //_('Answered')
         }
         if (record.hasFlag('Passed')) {
-            icons.push({src: 'images/oxygen/16x16/actions/mail-forward.png', qtip: Ext.util.Format.htmlEncode(_('Encaminhada'))}); //_('Forwarded')
+            icons.push({src: 'images/oxygen/16x16/actions/mail-forward.png', qtip: Ext.util.Format.htmlEncode(i18n._('Encaminhada'))}); //_('Forwarded')
         }
 //        if (record.hasFlag('\\Recent')) {
-//            icons.push({src: 'images/oxygen/16x16/actions/knewstuff.png', qtip: _('Recent')});
+//            icons.push({src: 'images/oxygen/16x16/actions/knewstuff.png', qtip: i18n._('Recent')});
 //        }
 
         Ext.each(icons, function(icon) {
@@ -2369,7 +2369,7 @@ Tine.Expressomail.GridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
                     (! onlyImportant || header == 'from' || header == 'to' || header == 'cc' || header == 'subject' || header == 'date'))
             {
                 if (header == 'date') headers[header] = new Date(headers[header]).toLocaleString();
-                result += '<b>' + _(header) + ':</b> '
+                result += '<b>' + i18n._(header) + ':</b> '
                     + Ext.util.Format.htmlEncode(
                         (ellipsis)
                             ? Ext.util.Format.ellipsis(headers[header], 40)
index 1673509..6f7e526 100644 (file)
@@ -119,8 +119,8 @@ Tine.Expressomail.ImportEmlDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
                     var responseText = Ext.util.JSON.decode(response.responseText);
                     if (responseText.data.code == 505) {
                         Ext.Msg.show({
-                            title: _('Error'),
-                            msg: _('Error import message eml!'),
+                            title: i18n._('Error'),
+                            msg: i18n._('Error import message eml!'),
                             icon: Ext.MessageBox.ERROR,
                             buttons: Ext.Msg.OK
                         });
@@ -134,7 +134,7 @@ Tine.Expressomail.ImportEmlDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
             });
         }, this);
 
-        Ext.MessageBox.wait(_('Please wait'), _('Loading'));
+        Ext.MessageBox.wait(i18n._('Please wait'), i18n._('Loading'));
         var files = fileSelector.getFileList();
         Ext.each(files, function(file) {
             var fileRecord = uploader.upload(file);
index 60ef718..0324fc7 100644 (file)
@@ -697,7 +697,7 @@ Tine.Expressomail.MessageEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog,
                 }, this);
 
                 if(notFound.length > 0){
-                    Ext.MessageBox.alert(_('Error'), this.app.i18n._("No valid certificate found for one or more of these email address.") 
+                    Ext.MessageBox.alert(i18n._('Error'), this.app.i18n._("No valid certificate found for one or more of these email address.")
                         + '\n' + notFound.join(',\n'), function(){
                         this.loadMask.hide();
                     },
@@ -1489,7 +1489,7 @@ Tine.Expressomail.MessageEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog,
                 });
             }
         } else {
-            Ext.MessageBox.alert(_('Errors'), _('Please fix the errors noted.'));
+            Ext.MessageBox.alert(i18n._('Errors'), i18n._('Please fix the errors noted.'));
         }
     },
 
@@ -2015,7 +2015,7 @@ Tine.Expressomail.MessageEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog,
 
         if (this.record.get('add_contacts') && record.get('added_contacts')!=0) {
             if (record.get('added_contacts')==-1) {
-                Ext.Msg.alert( _('Add Contacts'),
+                Ext.Msg.alert( i18n._('Add Contacts'),
                                 this.app.i18n._('Error saving unknown contacts.') + ' ' +
                                 this.app.i18n._('One or more contacts have not been added to the folder ') + this.getUnknownContactsFolderName(), this.closePendingMessages, this);
             }
@@ -2159,7 +2159,7 @@ Tine.Expressomail.MessageEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog,
             }
         } else {
             this.loadMask.hide();
-            Ext.MessageBox.alert(_('Errors'), this.getValidationErrorMessage());
+            Ext.MessageBox.alert(i18n._('Errors'), this.getValidationErrorMessage());
             this.sending = false;
         }
     },
index ce32b32..350b3bf 100644 (file)
@@ -684,7 +684,7 @@ Tine.Expressomail.Model.Folder = Tine.Tinebase.data.Record.create([
       { name: 'unread_children', type: 'Array', defaultValue: [] } // client only / array of unread child ids
 ], {
     // translations for system folders:
-    // _('INBOX') _('Drafts') _('Sent') _('Templates') _('Junk') _('Trash')
+    // i18n._('INBOX') i18n._('Drafts') i18n._('Sent') i18n._('Templates') i18n._('Junk') i18n._('Trash')
 
     appName: 'Expressomail',
     modelName: 'Folder',
index e777669..b6531f1 100644 (file)
@@ -446,7 +446,7 @@ Tine.Expressomail.RecipientGrid = Ext.extend(Ext.grid.EditorGridPanel, {
      */
     initActions: function() {
         this.action_remove = new Ext.Action({
-            text: _('Remove'),
+            text: i18n._('Remove'),
             handler: this.onDelete,
             iconCls: 'action_delete',
             scope: this
index 9b357b7..016a51c 100644 (file)
@@ -79,13 +79,13 @@ Tine.Expressomail.setTreeContextMenus = function() {
         scope: this,
         disabled: true,
         handler: function() {
-            Ext.MessageBox.prompt(String.format(_('New {0}'), this.app.i18n._('Folder')), String.format(_('Please enter the name of the new {0}:'), this.app.i18n._('Folder')), function(_btn, _text) {
+            Ext.MessageBox.prompt(String.format(i18n._('New {0}'), this.app.i18n._('Folder')), String.format(i18n._('Please enter the name of the new {0}:'), this.app.i18n._('Folder')), function(_btn, _text) {
                 if( this.ctxNode && _btn == 'ok') {
                     if (! _text) {
-                        Ext.Msg.alert(String.format(_('No {0} added'), this.app.i18n._('Folder')), String.format(_('You have to supply a {0} name!'), this.app.i18n._('Folder')));
+                        Ext.Msg.alert(String.format(i18n._('No {0} added'), this.app.i18n._('Folder')), String.format(i18n._('You have to supply a {0} name!'), this.app.i18n._('Folder')));
                         return;
                     }
-                    Ext.MessageBox.wait(_('Please wait'), String.format(_('Creating {0}...' ), this.app.i18n._('Folder')));
+                    Ext.MessageBox.wait(i18n._('Please wait'), String.format(i18n._('Creating {0}...' ), this.app.i18n._('Folder')));
                     var parentNode = this.ctxNode;
 
                     var params = {
@@ -296,7 +296,7 @@ Tine.Expressomail.setTreeContextMenus = function() {
 
     // mutual config options
     var config = {
-        nodeName: _('Folder'),
+        nodeName: i18n._('Folder'),
         scope: this,
         backend: 'Expressomail',
         backendModel: 'Folder'
index e9ba2e8..928ad31 100644 (file)
@@ -70,10 +70,10 @@ Ext.ux.form.HtmlEditor.SpellChecker = Ext.extend(Ext.util.Observable, {
             },\r
             scope: this,\r
             tooltip: {\r
-                title: _(this.langTitle),\r
-                text: _(this.langText)\r
+                title: i18n._(this.langTitle),\r
+                text: i18n._(this.langText)\r
             },\r
-            overflowText: _(this.langTitle)\r
+            overflowText: i18n._(this.langTitle)\r
         });\r
         this.spellchecker = new Ext.GoogieSpell("Expressomail/images/editorplugins/", "Expressomail.CheckSpelling",this);\r
 \r
@@ -119,11 +119,11 @@ function GoogieSpell(img_dir, server_url, parentObj) {
     this.edit_layer_dbl_click = true;\r
 \r
     this.lang_chck_spell = "Check spelling";\r
-    this.lang_revert = _("Reverter para"); //_("Revert to")\r
-    this.lang_close = _("Close");\r
-    this.lang_rsm_edt = _("Continuar editando"); //_("Resume editing")\r
-    this.lang_no_error_found = _("Nenhum erro ortográfico encontrado"); //_("No spelling errors found")\r
-    this.lang_no_suggestions = _("Sem sugestões"); //_("No suggestions")\r
+    this.lang_revert = i18n._("Reverter para"); //_("Revert to")\r
+    this.lang_close = i18n._("Close");\r
+    this.lang_rsm_edt = i18n._("Continuar editando"); //_("Resume editing")\r
+    this.lang_no_error_found = i18n._("Nenhum erro ortográfico encontrado"); //_("No spelling errors found")\r
+    this.lang_no_suggestions = i18n._("Sem sugestões"); //_("No suggestions")\r
     \r
     //Counters\r
     this.cnt_errors = 0;\r
@@ -625,7 +625,7 @@ GoogieSpell.prototype.flashNoSpellingErrorState = function() {
     Ext.getCmp('spellchecker_button').toggle();\r
     this.parentObj.cmp.disableItems(false);\r
     this.resumeEditing();\r
-    Ext.MessageBox.alert(_('Spell Checker'), _('Nenhum erro ortográfico encontrado')); //_("No spelling errors found")\r
+    Ext.MessageBox.alert(i18n._('Spell Checker'), i18n._('Nenhum erro ortográfico encontrado')); //_("No spelling errors found")\r
 }\r
 \r
 GoogieSpell.prototype.resumeEditingState = function() {\r
@@ -897,7 +897,7 @@ Ext.GoogieSpell = Ext.extend(GoogieSpell, {
             this.checkSpellingState();\r
         }\r
         else {\r
-            Ext.MessageBox.alert(_('Errors'), _("Área de edição não encontrada."));\r
+            Ext.MessageBox.alert(i18n._('Errors'), i18n._("Área de edição não encontrada."));\r
         }\r
     },\r
     getEditAreaValue: function(ta){\r
@@ -968,14 +968,14 @@ Ext.GoogieSpell = Ext.extend(GoogieSpell, {
                     }\r
                 }\r
                 else {\r
-                    var err_desc = r_text.description ? r_text.description : _("Erro inesperado na verificação ortográfica. Tente novamente mais tarde.");\r
-                    Ext.MessageBox.alert(_('Spell Checker'), err_desc);\r
+                    var err_desc = r_text.description ? r_text.description : i18n._("Erro inesperado na verificação ortográfica. Tente novamente mais tarde.");\r
+                    Ext.MessageBox.alert(i18n._('Spell Checker'), err_desc);\r
                 }\r
                 this.btnEl.dom.style.backgroundImage = '';\r
             },\r
             failure: function(res_txt, req) {\r
                 this.btnEl.removeClass("loading-indicator");\r
-                Ext.MessageBox.alert(_('Spell Checker'), _("Um erro ocorreu no servidor. Tente novamente mais tarde."));\r
+                Ext.MessageBox.alert(i18n._('Spell Checker'), i18n._("Um erro ocorreu no servidor. Tente novamente mais tarde."));\r
 \r
                 me.checkSpellingState();\r
                 this.btnEl.dom.style['background-image'] = btn_image;\r
index f1b3254..aaa44bd 100644 (file)
@@ -41,7 +41,7 @@ Ext.ux.form.HtmlEditor.Table = Ext.extend(Ext.util.Observable, {
     init: function(cmp){\r
         this.cmp = cmp;\r
         this.cmp.on('render', this.onRender, this);\r
-        this.tableBorderOptions = [['none', _('None')], ['1px solid #000', _('Solid Thin')], ['2px solid #000', _('Solid Thick')], ['1px dashed #000', _('Dashed')], ['1px dotted #000', _('Dotted')]];\r
+        this.tableBorderOptions = [['none', i18n._('None')], ['1px solid #000', i18n._('Solid Thin')], ['2px solid #000', i18n._('Solid Thick')], ['1px dashed #000', i18n._('Dashed')], ['1px dotted #000', i18n._('Dotted')]];\r
     },\r
     // private\r
     onRender: function(){\r
@@ -50,7 +50,7 @@ Ext.ux.form.HtmlEditor.Table = Ext.extend(Ext.util.Observable, {
             handler: function(){\r
                 if (!this.tableWindow){\r
                     this.tableWindow = new Ext.Window({\r
-                        title: _(this.langTitle),\r
+                        title: i18n._(this.langTitle),\r
                         closeAction: 'hide',\r
                         width: 235,\r
                         items: [{\r
@@ -65,19 +65,19 @@ Ext.ux.form.HtmlEditor.Table = Ext.extend(Ext.util.Observable, {
                                 xtype: 'numberfield',\r
                                 allowBlank: false,\r
                                 allowDecimals: false,\r
-                                fieldLabel: _(this.langRows),\r
+                                fieldLabel: i18n._(this.langRows),\r
                                 name: 'row',\r
                                 width: 60\r
                             }, {\r
                                 xtype: 'numberfield',\r
                                 allowBlank: false,\r
                                 allowDecimals: false,\r
-                                fieldLabel: _(this.langColumns),\r
+                                fieldLabel: i18n._(this.langColumns),\r
                                 name: 'col',\r
                                 width: 60\r
                             }, {\r
                                 xtype: 'combo',\r
-                                fieldLabel: _(this.langBorder),\r
+                                fieldLabel: i18n._(this.langBorder),\r
                                 name: 'border',\r
                                 forceSelection: true,\r
                                 mode: 'local',\r
@@ -93,7 +93,7 @@ Ext.ux.form.HtmlEditor.Table = Ext.extend(Ext.util.Observable, {
                                 anchor: '-15'\r
                             }, {\r
                                xtype: 'checkbox',\r
-                               fieldLabel: _(this.langCellLabel),\r
+                               fieldLabel: i18n._(this.langCellLabel),\r
                                checked: this.showCellLocationText,\r
                                listeners: {\r
                                        check: function(){\r
@@ -103,7 +103,7 @@ Ext.ux.form.HtmlEditor.Table = Ext.extend(Ext.util.Observable, {
                                }\r
                             }, {\r
                                xtype: 'checkbox',\r
-                               fieldLabel: _(this.lang100PcWidth),\r
+                               fieldLabel: i18n._(this.lang100PcWidth),\r
                                checked: this.set100PcWidth,\r
                                listeners: {\r
                                        check: function(){\r
@@ -114,7 +114,7 @@ Ext.ux.form.HtmlEditor.Table = Ext.extend(Ext.util.Observable, {
                             }]\r
                         }],\r
                         buttons: [{\r
-                            text: _(this.langInsert),\r
+                            text: i18n._(this.langInsert),\r
                             handler: function(){\r
                                 var frm = this.tableWindow.getComponent('insert-table').getForm();\r
                                 if (frm.isValid()) {\r
@@ -152,7 +152,7 @@ Ext.ux.form.HtmlEditor.Table = Ext.extend(Ext.util.Observable, {
                             },\r
                             scope: this\r
                         }, {\r
-                            text: _(this.langCancel),\r
+                            text: i18n._(this.langCancel),\r
                             handler: function(){\r
                                 this.tableWindow.hide();\r
                             },\r
@@ -167,9 +167,9 @@ Ext.ux.form.HtmlEditor.Table = Ext.extend(Ext.util.Observable, {
             },\r
             scope: this,\r
             tooltip: {\r
-                title: _(this.langTitle)\r
+                title: i18n._(this.langTitle)\r
             },\r
-            overflowText: _(this.langTitle)\r
+            overflowText: i18n._(this.langTitle)\r
         });\r
     }\r
 });\r
index 1e7b191..f44aac2 100644 (file)
@@ -66,8 +66,8 @@ Ext.ux.form.HtmlEditor.UploadImage = Ext.extend(Ext.util.Observable, {
             handler: this.onFileSelected,
             scope: this,
             url: this.url,
-            tooltip: {title: _(this.text_title)},
-            overflowText: _(this.text_title)
+            tooltip: {title: i18n._(this.text_title)},
+            overflowText: i18n._(this.text_title)
         }));
 
         this.body = Ext.getBody();
@@ -229,7 +229,7 @@ Ext.ux.form.HtmlEditor.UploadImage = Ext.extend(Ext.util.Observable, {
             result = true;
         }
         else {
-            this.showMessage(_(this.text_error_msgbox_title),String.format(_(this.text_error_file_type_not_permitted),filename,this.permitted_extensions.join(', ')));
+            this.showMessage(i18n._(this.text_error_msgbox_title),String.format(i18n._(this.text_error_file_type_not_permitted),filename,this.permitted_extensions.join(', ')));
             result = false;
         }
 
@@ -237,7 +237,7 @@ Ext.ux.form.HtmlEditor.UploadImage = Ext.extend(Ext.util.Observable, {
     },
 
     fireUploadStartEvent : function() {
-        this.wait = Ext.MessageBox.wait(_(this.text_note_uploading), _('Please wait!'));
+        this.wait = Ext.MessageBox.wait(i18n._(this.text_note_uploading), i18n._('Please wait!'));
         this.fireEvent('uploadstart', this);
     },
 
@@ -263,7 +263,7 @@ Ext.ux.form.HtmlEditor.UploadImage = Ext.extend(Ext.util.Observable, {
     onAjaxSuccess : function(response, options) {
         var json_response = {
             'success' : false,
-            'error' : _(this.text_note_upload_failed)
+            'error' : i18n._(this.text_note_upload_failed)
         }
         try {
             var rt = response.responseText;
@@ -323,7 +323,7 @@ Ext.ux.form.HtmlEditor.UploadImage = Ext.extend(Ext.util.Observable, {
             record : options.record,
             response : {
                 'success' : false,
-                'error' : _(this.text_note_upload_failed)
+                'error' : i18n._(this.text_note_upload_failed)
             }
         }
 
@@ -357,12 +357,12 @@ Ext.ux.form.HtmlEditor.UploadImage = Ext.extend(Ext.util.Observable, {
 
     onUploadError : function(dialog, filename, resp_data, record) {
         var fileName = filename.replace(/[a-zA-Z]:[\\\/]fakepath[\\\/]/, '');
-        this.showMessage(_(this.text_error_msgbox_title),String.format(_(this.text_note_upload_error),resp_data.maxsize));
+        this.showMessage(i18n._(this.text_error_msgbox_title),String.format(i18n._(this.text_note_upload_error),resp_data.maxsize));
     },
 
     onUploadFailed : function(dialog, filename, resp_data, record) {
         var fileName = filename.replace(/[a-zA-Z]:[\\\/]fakepath[\\\/]/, '');
-        this.showMessage(_(this.text_error_msgbox_title),String.format(_(this.text_note_upload_failed),resp_data.maxsize));
+        this.showMessage(i18n._(this.text_error_msgbox_title),String.format(i18n._(this.text_note_upload_failed),resp_data.maxsize));
     },
 
     showMessage : function(title, message) {
index f87865d..d633873 100644 (file)
@@ -136,7 +136,7 @@ Tine.Expressomail.sieve.RuleEditDialog = Ext.extend(Tine.widgets.dialog.EditDial
             return this.validationMessage;
         }
         else {
-            return _('Please fix the errors noted.');
+            return i18n._('Please fix the errors noted.');
         }
     },
     
index 26251ed..7eb7e66 100644 (file)
@@ -309,9 +309,9 @@ Tine.Expressomail.sieve.RulesGridPanel = Ext.extend(Tine.widgets.grid.GridPanel,
                 if (condition.header == filterModel.field || (condition.header === 'From' && filterModel.field == 'fromheader')) {
                     header = filterModel.label;
                     if (condition.header == 'size') {
-                        comperator = (condition.comperator == 'over') ? _('is greater than') : _('is less than');
+                        comperator = (condition.comperator == 'over') ? i18n._('is greater than') : i18n._('is less than');
                     } else {
-                        comperator = _(condition.comperator);
+                        comperator = i18n._(condition.comperator);
                     }
                     found = true;
                 }
index 90a234b..f5a9854 100644 (file)
@@ -116,7 +116,7 @@ Tine.Felamimail.ContactGridPanel = Ext.extend(Tine.Addressbook.ContactGridPanel,
             ' {checked}',
         '>');
         
-        Ext.each(['To', 'Cc', 'Bcc', 'None'], function(type) { // _('None')
+        Ext.each(['To', 'Cc', 'Bcc', 'None'], function(type) { // i18n._('None')
             columns.push({
                 header: this.felamimailApp.i18n._(type),
                 dataIndex: Ext.util.Format.lowercase(type),
index e27d148..8e73c77 100644 (file)
@@ -30,7 +30,7 @@ Ext.ns('Tine.Felamimail');
 Tine.Felamimail.Application = Ext.extend(Tine.Tinebase.Application, {
     
     /**
-     * auto hook text _('New Mail')
+     * auto hook text i18n._('New Mail')
      */
     addButtonText: 'New Mail',
     
@@ -170,7 +170,7 @@ Tine.Felamimail.Application = Ext.extend(Tine.Tinebase.Application, {
     },
 
     registerProtocolHandler: function() {
-        var text = String.format(_('{0} as default mailer'), Tine.title),
+        var text = String.format(i18n._('{0} as default mailer'), Tine.title),
             enabled = true; //Tine.Tinebase.configManager.get('registerMailToHandler', 'Felamimail');
         Tine.Felamimail.registerProtocolHandlerAction.setText(text);
 
index fdfc8f8..b856363 100755 (executable)
@@ -72,7 +72,7 @@ Tine.Felamimail.FolderSelectPanel = Ext.extend(Ext.Panel, {
      */
     initActions: function() {
         this.action_cancel = new Ext.Action({
-            text: _('Cancel'),
+            text: i18n._('Cancel'),
             minWidth: 70,
             scope: this,
             handler: this.onCancel,
@@ -81,7 +81,7 @@ Tine.Felamimail.FolderSelectPanel = Ext.extend(Ext.Panel, {
         
         this.action_ok = new Ext.Action({
             disabled: true,
-            text: _('Ok'),
+            text: i18n._('Ok'),
             iconCls: 'action_saveAndClose',
             minWidth: 70,
             handler: this.onOk,
index 8310f95..f0cc23b 100644 (file)
@@ -293,7 +293,7 @@ Tine.Felamimail.GridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
             allowMultiple: true,
             singularText: this.app.i18n._('Delete'),
             pluralText: this.app.i18n._('Delete'),
-            translationObject: this.i18nDeleteActionText ? this.app.i18n : Tine.Tinebase.translation,
+            translationObject: this.i18nDeleteActionText ? this.app.i18n : i18n,
             text: this.app.i18n._('Delete'),
             handler: this.onDeleteRecords,
             disabled: true,
@@ -574,16 +574,16 @@ Tine.Felamimail.GridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
             result = '';
             
         if (record.hasFlag('\\Answered')) {
-            icons.push({src: 'images/oxygen/16x16/actions/mail-reply-sender.png', qtip: Ext.util.Format.htmlEncode(_('Answered'))});
+            icons.push({src: 'images/oxygen/16x16/actions/mail-reply-sender.png', qtip: Ext.util.Format.htmlEncode(i18n._('Answered'))});
         }   
         if (record.hasFlag('Passed')) {
-            icons.push({src: 'images/oxygen/16x16/actions/mail-forward.png', qtip: Ext.util.Format.htmlEncode(_('Forwarded'))});
+            icons.push({src: 'images/oxygen/16x16/actions/mail-forward.png', qtip: Ext.util.Format.htmlEncode(i18n._('Forwarded'))});
         }   
         if (record.hasFlag('Tine20')) {
-            icons.push({src: 'images/favicon.png', qtip: Ext.util.Format.htmlEncode(_('Tine20'))});
+            icons.push({src: 'images/favicon.png', qtip: Ext.util.Format.htmlEncode(i18n._('Tine20'))});
         }
 //        if (record.hasFlag('\\Recent')) {
-//            icons.push({src: 'images/oxygen/16x16/actions/knewstuff.png', qtip: _('Recent')});
+//            icons.push({src: 'images/oxygen/16x16/actions/knewstuff.png', qtip: i18n._('Recent')});
 //        }   
         
         Ext.each(icons, function(icon) {
index da3ccaf..82c9d36 100644 (file)
@@ -756,12 +756,12 @@ Tine.Felamimail.MessageEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
             
         if (! folderName || folderName == '') {
             Ext.MessageBox.alert(
-                _('Failed'),
+                i18n._('Failed'),
                 String.format(this.app.i18n._('{0} account setting empty.'), folderField)
             );
         } else if (this.attachmentGrid.isUploading()) {
             Ext.MessageBox.alert(
-                _('Failed'),
+                i18n._('Failed'),
                 this.app.i18n._('Files are still uploading.')
             );
         } else {
index 31c529b..9867d7f 100644 (file)
@@ -529,7 +529,7 @@ Tine.Felamimail.Model.Folder = Tine.Tinebase.data.Record.create([
       { name: 'unread_children', type: 'Array', defaultValue: [] } // client only / array of unread child ids
 ], {
     // translations for system folders:
-    // _('INBOX') _('Drafts') _('Sent') _('Templates') _('Junk') _('Trash')
+    // i18n._('INBOX') i18n._('Drafts') i18n._('Sent') i18n._('Templates') i18n._('Junk') i18n._('Trash')
 
     appName: 'Felamimail',
     modelName: 'Folder',
index e14649d..1792188 100644 (file)
@@ -387,7 +387,7 @@ Tine.Felamimail.RecipientGrid = Ext.extend(Ext.grid.EditorGridPanel, {
      */
     initActions: function() {
         this.action_remove = new Ext.Action({
-            text: _('Remove'),
+            text: i18n._('Remove'),
             handler: this.onDelete,
             iconCls: 'action_delete',
             scope: this
index 659908f..b142acf 100644 (file)
@@ -61,13 +61,13 @@ Tine.Felamimail.setTreeContextMenus = function() {
         scope: this,
         disabled: true,
         handler: function() {
-            Ext.MessageBox.prompt(String.format(_('New {0}'), this.app.i18n._('Folder')), String.format(_('Please enter the name of the new {0}:'), this.app.i18n._('Folder')), function(_btn, _text) {
+            Ext.MessageBox.prompt(String.format(i18n._('New {0}'), this.app.i18n._('Folder')), String.format(i18n._('Please enter the name of the new {0}:'), this.app.i18n._('Folder')), function(_btn, _text) {
                 if( this.ctxNode && _btn == 'ok') {
                     if (! _text) {
-                        Ext.Msg.alert(String.format(_('No {0} added'), this.app.i18n._('Folder')), String.format(_('You have to supply a {0} name!'), this.app.i18n._('Folder')));
+                        Ext.Msg.alert(String.format(i18n._('No {0} added'), this.app.i18n._('Folder')), String.format(i18n._('You have to supply a {0} name!'), this.app.i18n._('Folder')));
                         return;
                     }
-                    Ext.MessageBox.wait(_('Please wait'), String.format(_('Creating {0}...' ), this.app.i18n._('Folder')));
+                    Ext.MessageBox.wait(i18n._('Please wait'), String.format(i18n._('Creating {0}...' ), this.app.i18n._('Folder')));
                     var parentNode = this.ctxNode;
                     
                     var params = {
index 4792930..ba8d18e 100644 (file)
@@ -305,9 +305,9 @@ Tine.Felamimail.sieve.RulesGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
                 if (condition.header == filterModel.field) {
                     header = filterModel.label;
                     if (condition.header == 'size') {
-                        comperator = (condition.comperator == 'over') ? _('is greater than') : _('is less than');
+                        comperator = (condition.comperator == 'over') ? i18n._('is greater than') : i18n._('is less than');
                     } else {
-                        comperator = _(condition.comperator);
+                        comperator = i18n._(condition.comperator);
                     }
                     found = true;
                 }
index 79d0297..ca2fcff 100644 (file)
@@ -68,7 +68,7 @@ Tine.Filemanager.DownloadLinkGridPanel = Ext.extend(Ext.grid.EditorGridPanel, {
         });
         
         this.actionRemove = new Ext.Action({
-            text: _('Remove record'),
+            text: i18n._('Remove record'),
             disabled: true,
             scope: this,
             handler: this.onRemove,
index 620d259..5952727 100644 (file)
@@ -29,7 +29,7 @@ Tine.Filemanager.handleRequestException = function(exception, request) {
             Ext.MessageBox.show({
                 buttons: Ext.Msg.OK,
                 icon: Ext.MessageBox.WARNING,
-                title: _('Service Unavailable'),
+                title: i18n._('Service Unavailable'),
                 msg: String.format(app.i18n._('The Filemanager is not configured correctly. Please refer to the {0}Tine 2.0 Admin FAQ{1} for configuration advice or contact your administrator.'),
                     '<a href="http://www.tine20.org/wiki/index.php/Admin_FAQ#The_message_.22filesdir_config_value_not_set.22_appears_in_the_logfile_and_I_can.27t_open_the_Filemanager" target="_blank">',
                     '</a>')
index 76870e6..832ee81 100644 (file)
@@ -29,7 +29,7 @@ Tine.Filemanager.Application = Ext.extend(Tine.Tinebase.Application, {
  * register additional action for genericpickergridpanel
  */
 Tine.widgets.relation.MenuItemManager.register('Filemanager', 'Node', {
-    text: 'Save locally',   // _('Save locally')
+    text: 'Save locally',   // i18n._('Save locally')
     iconCls: 'action_filemanager_save_all',
     requiredGrant: 'readGrant',
     actionType: 'download',
index a231148..2ad4cc1 100644 (file)
@@ -31,13 +31,13 @@ Tine.Filemanager.GridContextMenu = {
             
             Ext.MessageBox.show({
                 title: 'Rename ' + this.nodeName,
-                msg: String.format(_('Please enter the new name of the {0}:'), this.nodeName),
+                msg: String.format(i18n._('Please enter the new name of the {0}:'), this.nodeName),
                 buttons: Ext.MessageBox.OKCANCEL,
                 value: nodeText,
                 fn: function(_btn, _text){
                     if (_btn == 'ok') {
                         if (! _text) {
-                            Ext.Msg.alert(String.format(_('Not renamed {0}'), this.nodeName), String.format(_('You have to supply a {0} name!'), this.nodeName));
+                            Ext.Msg.alert(String.format(i18n._('Not renamed {0}'), this.nodeName), String.format(i18n._('You have to supply a {0} name!'), this.nodeName));
                             return;
                         }
                         
index d685bbd..651392d 100644 (file)
@@ -298,7 +298,7 @@ Tine.Filemanager.fileRecordBackend =  new Tine.Tinebase.data.RecordProxy({
             }
         }
         
-        this.loadMask = new Ext.LoadMask(app.getMainScreen().getCenterPanel().getEl(), {msg: String.format(_('Please wait')) + '. ' + String.format(message, '' )});
+        this.loadMask = new Ext.LoadMask(app.getMainScreen().getCenterPanel().getEl(), {msg: String.format(i18n._('Please wait')) + '. ' + String.format(message, '' )});
         app.getMainScreen().getWestPanel().setDisabled(true);
         app.getMainScreen().getNorthPanel().setDisabled(true);
         this.loadMask.show();
@@ -523,7 +523,7 @@ Tine.Filemanager.Model.Node.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Filemanager');
        
     return [
-        {label : _('Quick Search'), field : 'query', operators : [ 'contains' ]}, 
+        {label : i18n._('Quick Search'), field : 'query', operators : [ 'contains' ]},
 //        {label: app.i18n._('Type'), field: 'type'}, // -> should be a combo
         {label: app.i18n._('Contenttype'), field: 'contenttype'},
         {label: app.i18n._('Creation Time'), field: 'creation_time', valueType: 'date'},
index 06444a8..095688f 100644 (file)
@@ -348,7 +348,7 @@ Tine.Filemanager.NodeGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
             allowMultiple: true,
             singularText: this.app.i18n._('Delete'),
             pluralText: this.app.i18n._('Delete'),
-            translationObject: this.i18nDeleteActionText ? this.app.i18n : Tine.Tinebase.translation,
+            translationObject: this.i18nDeleteActionText ? this.app.i18n : i18n,
             text: this.app.i18n._('Delete'),
             handler: this.onDeleteRecords,
             disabled: true,
@@ -360,7 +360,7 @@ Tine.Filemanager.NodeGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
             allowMultiple: false,
             singularText: this.app.i18n._('Publish'),
             folderText: this.app.i18n._('Publish'),
-            translationObject: this.i18nDeleteActionText ? this.app.i18n : Tine.Tinebase.translation,
+            translationObject: this.i18nDeleteActionText ? this.app.i18n : i18n,
             text: this.app.i18n._('Publish'),
             handler: this.onPublishFile,
             disabled: true,
@@ -693,8 +693,8 @@ Tine.Filemanager.NodeGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
      */
     onUploadFail: function () {
         Ext.MessageBox.alert(
-            _('Upload Failed'), 
-            _('Could not upload file. Filesize could be too big. Please notify your Administrator.') 
+            i18n._('Upload Failed'),
+            i18n._('Could not upload file. Filesize could be too big. Please notify your Administrator.')
         ).setIcon(Ext.MessageBox.ERROR);
         
         var app = Tine.Tinebase.appMgr.get('Filemanager'),
@@ -844,7 +844,7 @@ Tine.Filemanager.NodeGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
         
         if(!nodeRecord.isDropFilesAllowed()) {
             Ext.MessageBox.alert(
-                    _('Upload Failed'), 
+                    i18n._('Upload Failed'),
                     app.i18n._('Putting files in this folder is not allowed!')
             ).setIcon(Ext.MessageBox.ERROR);
             
index 6774f17..4f16d82 100644 (file)
@@ -689,8 +689,8 @@ Ext.extend(Tine.Filemanager.NodeTreePanel, Tine.widgets.container.TreePanel, {
      */
     onUploadFail: function () {
         Ext.MessageBox.alert(
-            _('Upload Failed'), 
-            _('Could not upload file. Filesize could be too big. Please notify your Administrator.')
+            i18n._('Upload Failed'),
+            i18n._('Could not upload file. Filesize could be too big. Please notify your Administrator.')
         ).setIcon(Ext.MessageBox.ERROR);
     },
     
@@ -799,7 +799,7 @@ Ext.extend(Tine.Filemanager.NodeTreePanel, Tine.widgets.container.TreePanel, {
         
         if(!targetNode.attributes.nodeRecord.isDropFilesAllowed()) {
             Ext.MessageBox.alert(
-                    _('Upload Failed'), 
+                    i18n._('Upload Failed'),
                     app.i18n._('Putting files in this folder is not allowed!')
                 ).setIcon(Ext.MessageBox.ERROR);
             
index 138dc1e..b6d009a 100644 (file)
@@ -49,7 +49,7 @@ Tine.HumanResources.ContractDetailsPanel = Ext.extend(Tine.widgets.grid.DetailsP
                     items.push({
                         xtype: 'ux.displayfield',
                         name: fieldConfig.key,
-                        fieldLabel: fieldConfig.hasOwnProperty('useGlobalTranslation') ? _(fieldConfig.label) : this.app.i18n._(fieldConfig.label),
+                        fieldLabel: fieldConfig.hasOwnProperty('useGlobalTranslation') ? i18n._(fieldConfig.label) : this.app.i18n._(fieldConfig.label),
                         renderer: Tine.widgets.grid.RendererManager.get(mc.appName, mc.modelName, fieldConfig.key),
                         htmlEncode: false
                     });
index 51547d5..3591386 100644 (file)
@@ -85,7 +85,7 @@ Tine.HumanResources.ContractEditDialog = Ext.extend(Tine.widgets.dialog.EditDial
         if (! this.record.id) {
             this.getForm().findField('feast_calendar_id').setValue(Tine.HumanResources.registry.get('defaultFeastCalendar'));
         } else {
-            this.window.setTitle(String.format(_('Edit {0}'), this.i18nRecordName));
+            this.window.setTitle(String.format(i18n._('Edit {0}'), this.i18nRecordName));
             this.getForm().findField('workingtime_template').setValue(null);
         }
         
@@ -277,25 +277,25 @@ Tine.HumanResources.ContractEditDialog = Ext.extend(Tine.widgets.dialog.EditDial
                             ],
                             
                             [Ext.apply({
-                                fieldLabel: _('Mon.'),
+                                fieldLabel: i18n._('Mon.'),
                                 name: 'weekdays_0'
                             }, weekdayFieldDefaults), Ext.apply({
-                                fieldLabel: _('Tue.'),
+                                fieldLabel: i18n._('Tue.'),
                                 name: 'weekdays_1'
                             }, weekdayFieldDefaults), Ext.apply({
-                                fieldLabel: _('Wed.'),
+                                fieldLabel: i18n._('Wed.'),
                                 name: 'weekdays_2'
                             }, weekdayFieldDefaults), Ext.apply({
-                                fieldLabel: _('Thu.'),
+                                fieldLabel: i18n._('Thu.'),
                                 name: 'weekdays_3'
                             }, weekdayFieldDefaults), Ext.apply({
-                                fieldLabel: _('Fri.'),
+                                fieldLabel: i18n._('Fri.'),
                                 name: 'weekdays_4'
                             }, weekdayFieldDefaults), Ext.apply({
-                                fieldLabel: _('Sat.'),
+                                fieldLabel: i18n._('Sat.'),
                                 name: 'weekdays_5'
                             }, weekdayFieldDefaults), Ext.apply({
-                                fieldLabel: _('Sun.'),
+                                fieldLabel: i18n._('Sun.'),
                                 name: 'weekdays_6'
                             }, weekdayFieldDefaults)]
                         ]
index d6684c7..b3d13a6 100644 (file)
@@ -60,7 +60,7 @@ Tine.HumanResources.ExtraFreeTimeDetailsPanel = Ext.extend(Tine.widgets.grid.Det
                     items.push({
                         xtype: 'ux.displayfield',
                         name: fieldConfig.key,
-                        fieldLabel: fieldConfig.hasOwnProperty('useGlobalTranslation') ? _(fieldConfig.label) : this.app.i18n._(fieldConfig.label),
+                        fieldLabel: fieldConfig.hasOwnProperty('useGlobalTranslation') ? i18n._(fieldConfig.label) : this.app.i18n._(fieldConfig.label),
                         renderer: Tine.widgets.grid.RendererManager.get(mc.appName, mc.modelName, fieldConfig.key)
                     });
                 }
index 3b509ff..cec4ef4 100644 (file)
@@ -152,7 +152,7 @@ Tine.HumanResources.FreeTimeEditDialog = Ext.extend(Tine.widgets.dialog.EditDial
         this.record.set('employee_id', this.fixedFields.get('employee_id'));
         
         if (this.record.get('employee_id')) {
-            this.window.setTitle(String.format(_('Edit {0} "{1}"'), this.i18nRecordName, this.record.getTitle()));
+            this.window.setTitle(String.format(i18n._('Edit {0} "{1}"'), this.i18nRecordName, this.record.getTitle()));
         }
         
         Tine.HumanResources.FreeTimeEditDialog.superclass.onRecordLoad.call(this);
index 1c96614..3556a8f 100644 (file)
@@ -55,7 +55,7 @@ Tine.HumanResources.Model.WorkingTime.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('HumanResources');
     
     return [
-        {label: _('Quick Search'), field: 'query', operators: ['contains']}
+        {label: i18n._('Quick Search'), field: 'query', operators: ['contains']}
     ];
 };
 
index 834e065..951803f 100644 (file)
@@ -39,7 +39,7 @@ Tine.Projects.Model.Project = Tine.Tinebase.data.Record.create(Tine.Tinebase.Mod
     // ngettext('Project list', 'Project lists', n);
     containerName: 'Project list',
     containersName: 'Project lists'
-    // _('Project lists')
+    // i18n._('Project lists')
 });
 
 /**
@@ -70,7 +70,7 @@ Tine.Projects.Model.Project.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Projects');
     
     return [ 
-        {label: _('Quick Search'),    field: 'query',       operators: ['contains']},
+        {label: i18n._('Quick Search'),    field: 'query',       operators: ['contains']},
         {label: app.i18n._('Title'),    field: 'title'},
         {label: app.i18n._('Number'),    field: 'number'},
         {label: app.i18n._('Description'),    field: 'description'},
@@ -84,10 +84,10 @@ Tine.Projects.Model.Project.getFilterModel = function() {
         {filtertype: 'tinebase.tag', app: app},
         {filtertype: 'tine.widget.container.filtermodel', app: app, recordClass: Tine.Projects.Model.Project},
         {filtertype: 'tine.projects.attendee', app: app},
-        {label: _('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
-        {label: _('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
-        {label: _('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
-        {label: _('Created By'),                                                        field: 'created_by',         valueType: 'user'}
+        {label: i18n._('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
+        {label: i18n._('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
+        {label: i18n._('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
+        {label: i18n._('Created By'),                                                        field: 'created_by',         valueType: 'user'}
     ];
 };
 
index 26b6b2f..24aee66 100644 (file)
@@ -83,7 +83,7 @@ Tine.Sales.AddressEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
         if ((! this.copyRecord) && this.record.id) {
             var c = this.record.get('customer_id');
             var l = this.record.get('locality') ? ' (' + this.record.get('locality') + ')' : '';
-            this.window.setTitle(String.format(_('Edit {0} "{1}"'), this.i18nRecordName, c.name + l));
+            this.window.setTitle(String.format(i18n._('Edit {0} "{1}"'), this.i18nRecordName, c.name + l));
         } else if (! this.record.id) {
             if (this.fixedFields.get('type').toLowerCase() == 'billing') {
                 this.window.setTitle(this.app.i18n._('Add new Billing Address'));
index 1f8a9d4..43bd7a6 100644 (file)
@@ -87,7 +87,7 @@ Tine.Sales.AdminPanel = Ext.extend(Ext.FormPanel, {
      * @param {} position
      */
     onRender : function(ct, position) {
-        this.loadMask = new Ext.LoadMask(ct, {msg: _('Loading...')});
+        this.loadMask = new Ext.LoadMask(ct, {msg: i18n._('Loading...')});
         Tine.Sales.AdminPanel.superclass.onRender.call(this, ct, position);
 
         // generalized keybord map for edit dlgs
index 902d3c3..2c4007f 100644 (file)
@@ -124,7 +124,7 @@ Tine.Sales.BillingDateDialog = Ext.extend(Ext.FormPanel, {
      */
     initActions: function() {
         this.action_cancel = new Ext.Action({
-            text: _('Cancel'),
+            text: i18n._('Cancel'),
             minWidth: 70,
             scope: this,
             handler: this.onCancel,
@@ -132,7 +132,7 @@ Tine.Sales.BillingDateDialog = Ext.extend(Ext.FormPanel, {
         });
         
         this.action_update = new Ext.Action({
-            text : _('Ok'),
+            text : i18n._('Ok'),
             minWidth : 70,
             scope : this,
             handler: this.onOk,
index 2995c30..2ff112c 100644 (file)
@@ -118,7 +118,7 @@ Tine.Sales.CopyAddressDialog = Ext.extend(Ext.FormPanel, {
      */
     initActions: function() {
         this.action_update = new Ext.Action({
-            text : _('Ok'),
+            text : i18n._('Ok'),
             minWidth : 70,
             scope : this,
             handler: this.onOk,
index 7be75ea..3a48da9 100644 (file)
@@ -154,7 +154,7 @@ Tine.Sales.CustomerDetailsPanel = Ext.extend(Tine.widgets.grid.DetailsPanel, {
                     '<div class="bordercorner_gray_2"></div>',
                     '<div class="bordercorner_gray_3"></div>',
                     '<div class="bordercorner_gray_4"></div>',
-                    '<div class="preview-panel-declaration">' + _('Description') + '</div>',
+                    '<div class="preview-panel-declaration">' + i18n._('Description') + '</div>',
                     '{[this.encode(values.description)]}',
                 '</div>',
             '</tpl>',
index 0a8562b..9cecc98 100644 (file)
@@ -41,7 +41,7 @@ Tine.Sales.CustomerGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
      */
     getActionToolbarItems: function() {
         this.actions_export = new Ext.Action({
-            // _('Export Customers')
+            // i18n._('Export Customers')
             text: this.app.i18n._hidden('Export Customers'),
             iconCls: 'action_export',
             scope: this,
index 94a6971..11844f1 100644 (file)
@@ -51,7 +51,7 @@ Tine.Sales.InvoiceGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
      */
     getActionToolbarItems: function() {
         this.actions_export = new Ext.Action({
-            // _('Export Invoices')
+            // i18n._('Export Invoices')
             text: this.app.i18n._hidden('Export Invoices'),
             iconCls: 'action_export',
             scope: this,
index ce8adde..159fc24 100644 (file)
@@ -108,7 +108,7 @@ Tine.Sales.InvoicePositionGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
         this.action_export = new Ext.Action({
             requiredGrant: 'addGrant',
             actionType: 'export',
-            text: String.format(_('Export Records from these Positions') + ' ({0})', this.i18nModelsName),
+            text: String.format(i18n._('Export Records from these Positions') + ' ({0})', this.i18nModelsName),
             handler: this.onExport.createDelegate(this),
             iconCls: 'action_export',
             scope: this
index eee0e3a..ed9b587 100644 (file)
@@ -231,10 +231,10 @@ Tine.Sales.ProductAggregateGridPanel = Ext.extend(Tine.widgets.grid.QuickaddGrid
             {id: 'start_date', renderer: Tine.Tinebase.common.dateRenderer, editor: new Ext.ux.form.ClearableDateField(), quickaddField: new Ext.ux.form.ClearableDateField(), dataIndex: 'start_date', header: this.app.i18n._('Start Date'),  scope: this, width: 110},
             {id: 'end_date', renderer: Tine.Tinebase.common.dateRenderer, editor: new Ext.ux.form.ClearableDateField(), quickaddField: new Ext.ux.form.ClearableDateField(), dataIndex: 'end_date', header: this.app.i18n._('End Date'),  scope: this, width: 110},
             {id: 'last_autobill', renderer: Tine.Tinebase.common.dateRenderer, editor: new Ext.ux.form.ClearableDateField(), hidden: true, dataIndex: 'last_autobill', header: this.app.i18n._('Last Autobill'),  scope: this, width: 110},
-            {id: 'creation_time',      header: _('Creation Time'),         dataIndex: 'creation_time',         renderer: Tine.Tinebase.common.dateRenderer,        hidden: true, sortable: true },
-            {id: 'created_by',         header: _('Created By'),            dataIndex: 'created_by',            renderer: Tine.Tinebase.common.usernameRenderer,    hidden: true, sortable: true },
-            {id: 'last_modified_time', header: _('Last Modified Time'),    dataIndex: 'last_modified_time',    renderer: Tine.Tinebase.common.dateRenderer,        hidden: true, sortable: true },
-            {id: 'last_modified_by',   header: _('Last Modified By'),      dataIndex: 'last_modified_by',      renderer: Tine.Tinebase.common.usernameRenderer,    hidden: true, sortable: true }
+            {id: 'creation_time',      header: i18n._('Creation Time'),         dataIndex: 'creation_time',         renderer: Tine.Tinebase.common.dateRenderer,        hidden: true, sortable: true },
+            {id: 'created_by',         header: i18n._('Created By'),            dataIndex: 'created_by',            renderer: Tine.Tinebase.common.usernameRenderer,    hidden: true, sortable: true },
+            {id: 'last_modified_time', header: i18n._('Last Modified Time'),    dataIndex: 'last_modified_time',    renderer: Tine.Tinebase.common.dateRenderer,        hidden: true, sortable: true },
+            {id: 'last_modified_by',   header: i18n._('Last Modified By'),      dataIndex: 'last_modified_by',      renderer: Tine.Tinebase.common.usernameRenderer,    hidden: true, sortable: true }
         ];
 
         return new Ext.grid.ColumnModel({
index 01ae78a..2291d50 100644 (file)
@@ -41,7 +41,7 @@ Tine.Sales.PurchaseInvoiceGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
      */
     getActionToolbarItems: function() {
         this.actions_export = new Ext.Action({
-            // _('Export Invoices')
+            // i18n._('Export Invoices')
             text: this.app.i18n._hidden('Export Invoices'),
             iconCls: 'action_export',
             scope: this,
index 0af0a7e..7e98818 100644 (file)
@@ -154,7 +154,7 @@ Tine.Sales.SupplierDetailsPanel = Ext.extend(Tine.widgets.grid.DetailsPanel, {
                     '<div class="bordercorner_gray_2"></div>',
                     '<div class="bordercorner_gray_3"></div>',
                     '<div class="bordercorner_gray_4"></div>',
-                    '<div class="preview-panel-declaration">' + _('Description') + '</div>',
+                    '<div class="preview-panel-declaration">' + i18n._('Description') + '</div>',
                     '{[this.encode(values.description)]}',
                 '</div>',
             '</tpl>',
index 27e0da0..025e0a0 100644 (file)
@@ -41,7 +41,7 @@ Tine.Sales.SupplierGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
      */
     getActionToolbarItems: function() {
         this.actions_export = new Ext.Action({
-            // _('Export Suppliers')
+            // i18n._('Export Suppliers')
             text: this.app.i18n._hidden('Export Suppliers'),
             iconCls: 'action_export',
             scope: this,
index dc13b6b..6985ad7 100644 (file)
@@ -127,7 +127,7 @@ Ext.ns('Tine', 'Tine.Setup');
             autoFill: true,
             forceFit:true,
             ignoreAdd: true
-            //emptyText: String.format(Tine.Tinebase.translation._("There could not be found any {0}. Please try to change your filter-criteria, view-options or the {1} you search in."), this.i18nRecordsName, this.i18nContainersName),
+            //emptyText: String.format(i18n._("There could not be found any {0}. Please try to change your filter-criteria, view-options or the {1} you search in."), this.i18nRecordsName, this.i18nContainersName),
             /*
             onLoad: Ext.emptyFn,
             listeners: {
index 92d7a64..397923c 100644 (file)
@@ -71,7 +71,7 @@ Tine.SimpleFAQ.Model.Faq.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get("SimpleFAQ");
     
     return [
-        {label: _('Quick Search'), field: 'query', operators: ['contains']},
+        {label: i18n._('Quick Search'), field: 'query', operators: ['contains']},
         {filtertype: 'tine.widget.container.filtermodel', app: app, recordClass: Tine.SimpleFAQ.Model.Faq},
         {filtertype: 'simplefaq.faqstatus', app: app},
         {filtertype: 'simplefaq.faqtype', app: app},
index 247602e..7588546 100644 (file)
@@ -125,7 +125,7 @@ Tine.Sipgate.AccountEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
             this.onRecordUpdate();
             this.recordProxy.validateAccount(this.record, this.onValidateSuccess, this.onRequestFailed, this);
         } else {
-            Ext.MessageBox.alert(_('Errors'), this.getValidationErrorMessage());
+            Ext.MessageBox.alert(i18n._('Errors'), this.getValidationErrorMessage());
         }
         
     },
@@ -338,7 +338,7 @@ Tine.Sipgate.AccountEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
         }
         if(!calledFromOnValidate && isValid) {
             if(!this.getForm().findField('is_valid').getValue()) {
-                Ext.MessageBox.alert(_('Errors'), this.app.i18n._('Please validate the account settings before saving!'));
+                Ext.MessageBox.alert(i18n._('Errors'), this.app.i18n._('Please validate the account settings before saving!'));
                 isValid = false;
             }
         }
index 878b6d4..fe6df7d 100644 (file)
@@ -103,7 +103,7 @@ Tine.Sipgate.CallStateWindow = Ext.extend(Ext.FormPanel, {
     
     initActions : function() {
         this.action_cancel = new Ext.Action({
-            text : this.app.i18n._(this.cancelButtonText) ? this.app.i18n._(this.cancelButtonText) : _('Cancel'),
+            text : this.app.i18n._(this.cancelButtonText) ? this.app.i18n._(this.cancelButtonText) : i18n._('Cancel'),
             minWidth : 70,
             scope : this,
             handler : this.onCancel,
index ed1d462..10921c3 100644 (file)
@@ -86,7 +86,7 @@ Tine.Sipgate.DialNumberDialog = Ext.extend(Ext.FormPanel, {
      */
     initActions: function() {
         this.action_cancel = new Ext.Action({
-            text : _('Cancel'),
+            text : i18n._('Cancel'),
             minWidth : 70,
             scope : this,
             handler : this.onCancel,
@@ -94,7 +94,7 @@ Tine.Sipgate.DialNumberDialog = Ext.extend(Ext.FormPanel, {
         });
         
         this.action_update = new Ext.Action({
-            text : _('Ok'),
+            text : i18n._('Ok'),
             minWidth : 70,
             scope : this,
             handler : this.onUpdate,
@@ -163,7 +163,7 @@ Tine.Sipgate.DialNumberDialog = Ext.extend(Ext.FormPanel, {
                         ref: '../../../../linePicker'
                     })],[
                     {
-                        fieldLabel:this.app.i18n. _('Number to call'),
+                        fieldLabel:this.app.i18n. i18n._('Number to call'),
                         name: 'number',
                         value: this.number ? this.number : Tine.Sipgate.registry.get('preferences').get('internationalPrefix'),
                         regex: /^\+?\d{5,}$/i,
index 7f0f877..61d7543 100644 (file)
@@ -226,7 +226,7 @@ Tine.Sipgate.LineGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
     
     onSyncLine: function() {
         this.loadMask = new Ext.LoadMask(this.grid.getEl(), {
-                        msg: _('Synchronizing...')
+                        msg: i18n._('Synchronizing...')
                     });
         this.loadMask.show();    
         var sel = this.grid.getSelectionModel().getSelections();
index c4a8407..038d098 100644 (file)
@@ -94,8 +94,8 @@ Tine.Sipgate.Model.Account.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Sipgate');
     
     return [ 
-        { label: _('Quick Search'), field: 'query', operators: ['contains'] },
-        { label: _('Created By'), field: 'created_by', valueType: 'user'},
+        { label: i18n._('Quick Search'), field: 'query', operators: ['contains'] },
+        { label: i18n._('Created By'), field: 'created_by', valueType: 'user'},
         {
             label: app.i18n._('Account-Type'),
             field: 'accounttype',
@@ -141,7 +141,7 @@ Tine.Sipgate.Model.Line.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Sipgate');
     
     return [ 
-        { label: _('Quick Search'), field: 'query', operators: ['contains'] },
+        { label: i18n._('Quick Search'), field: 'query', operators: ['contains'] },
         { filtertype: 'sipgate.account' },
         { label: app.i18n._('Assigned to'), field: 'user_id', valueType: 'user'}
     ];
@@ -318,7 +318,7 @@ Tine.Sipgate.connectionBackend = new Tine.Tinebase.data.RecordProxy({
 Tine.Sipgate.Model.Connection.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Sipgate');
     return [ 
-        { label: _('Quick Search'), field: 'query', operators: ['contains'] },
+        { label: i18n._('Quick Search'), field: 'query', operators: ['contains'] },
         { filtertype: 'sipgate.line' },
         { filtertype: 'addressbook.contact' },
         {
index f9862a2..b2d9c0e 100644 (file)
@@ -60,7 +60,7 @@ Tine.Sipgate.SearchAddressDialog = Ext.extend(Ext.FormPanel, {
             iconCls : 'action_AddNumber'
         });
         this.action_cancel = new Ext.Action({
-            text : this.app.i18n._(this.cancelButtonText) ? this.app.i18n._(this.cancelButtonText) : _('Cancel'),
+            text : this.app.i18n._(this.cancelButtonText) ? this.app.i18n._(this.cancelButtonText) : i18n._('Cancel'),
             minWidth : 70,
             scope : this,
             handler : this.onCancel,
@@ -68,7 +68,7 @@ Tine.Sipgate.SearchAddressDialog = Ext.extend(Ext.FormPanel, {
             iconCls : 'action_cancel'
         });
         this.action_close = new Ext.Action({
-            text : this.app.i18n._(this.cancelButtonText) ? this.app.i18n._(this.cancelButtonText) : _('Close'),
+            text : this.app.i18n._(this.cancelButtonText) ? this.app.i18n._(this.cancelButtonText) : i18n._('Close'),
             minWidth : 70,
             scope : this,
             handler : this.onCancel,
index 4e1c552..3fcbd3e 100644 (file)
@@ -71,14 +71,14 @@ Tine.Sipgate.SmsEditDialog = Ext.extend(Ext.FormPanel, {
             iconCls : 'SmsIconCls'
         });
         this.action_cancel = new Ext.Action({
-            text : this.app.i18n._(this.cancelButtonText) ? this.app.i18n._(this.cancelButtonText) : _('Cancel'),
+            text : this.app.i18n._(this.cancelButtonText) ? this.app.i18n._(this.cancelButtonText) : i18n._('Cancel'),
             minWidth : 70,
             scope : this,
             handler : this.onCancel,
             iconCls : 'action_cancel'
         });
         this.action_close = new Ext.Action({
-            text : this.app.i18n._(this.cancelButtonText) ? this.app.i18n._(this.cancelButtonText) : _('Close'),
+            text : this.app.i18n._(this.cancelButtonText) ? this.app.i18n._(this.cancelButtonText) : i18n._('Close'),
             minWidth : 70,
             scope : this,
             handler : this.onCancel,
index 65f4ac2..2b4d0b9 100644 (file)
@@ -102,7 +102,7 @@ Tine.Tasks.Model.Task.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Tasks');
 
     return [
-        {label: _('Quick Search'),                  field: 'query',    operators: ['contains']},
+        {label: i18n._('Quick Search'),                  field: 'query',    operators: ['contains']},
         {filtertype: 'tine.widget.container.filtermodel', app: app, recordClass: Tine.Tasks.Model.Task},
         {label: app.i18n._('Summary'),         field: 'summary' },
         {label: app.i18n._('Due Date'),        field: 'due', valueType: 'date', operators: ['within', 'before', 'after']},
@@ -117,10 +117,10 @@ Tine.Tasks.Model.Task.getFilterModel = function() {
         },
         {label: app.i18n._('Responsible'),     field: 'organizer', valueType: 'user'},
         {filtertype: 'tinebase.tag', app: app},
-        {label: _('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
-        {label: _('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
-        {label: _('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
-        {label: _('Created By'),                                                        field: 'created_by',         valueType: 'user'}
+        {label: i18n._('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
+        {label: i18n._('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
+        {label: i18n._('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
+        {label: i18n._('Created By'),                                                        field: 'created_by',         valueType: 'user'}
     ];
 };
 
index 5508792..50be5f2 100644 (file)
@@ -202,7 +202,7 @@ Ext.namespace('Tine.Tasks');
                         Tine.widgets.form.RecordPickerManager.get('Addressbook', 'Contact', {
                             userOnly: true,
                             fieldLabel: this.app.i18n._('Organizer'),
-                            emptyText: _('Add Responsible ...'),
+                            emptyText: i18n._('Add Responsible ...'),
                             useAccountRecord: true,
                             name: 'organizer',
                             allowEmpty: true
index d919323..b95ea73 100644 (file)
@@ -36,7 +36,7 @@ Tine.widgets.grid.RendererManager.register(
 Tine.Tasks.Application = Ext.extend(Tine.Tinebase.Application, {
     
     /**
-     * auto hook text _('New Task')
+     * auto hook text i18n._('New Task')
      */
     addButtonText: 'New Task'
 });
index 3ff9ccc..a1a09e0 100644 (file)
@@ -91,7 +91,7 @@ Tine.Timetracker.DurationField = Ext.extend(Ext.form.Field,  {
             /*
                 new Ext.ux.SliderTip({
                     getText: function(slider){
-                        return String.format(_('{0}'),  slider.getValue()/10).replace(/\ /, '&nbsp;');
+                        return String.format(i18n._('{0}'),  slider.getValue()/10).replace(/\ /, '&nbsp;');
                     }
                 })
             */
index c820ce2..c25e95a 100644 (file)
@@ -92,7 +92,7 @@ Tine.Timetracker.DurationSpinner = Ext.extend(Ext.ux.form.Spinner,  {
             } else if (value > 0) {
                     value = value * 60;
             } else {
-                this.markInvalid(_('Not a valid time'));
+                this.markInvalid(i18n._('Not a valid time'));
                 return;
             }
         }
index 18c08ce..606346f 100644 (file)
@@ -94,10 +94,10 @@ Tine.Timetracker.Model.Timesheet.getFilterModel = function() {
         {label: app.i18n._('Description'),  field: 'description', defaultOperator: 'contains'},
         {label: app.i18n._('Billable'),     field: 'is_billable_combined', valueType: 'bool', defaultValue: true },
         {label: app.i18n._('Cleared'),      field: 'is_cleared_combined',  valueType: 'bool', defaultValue: false },
-        {label: _('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
-        {label: _('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
-        {label: _('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
-        {label: _('Created By'),                                                        field: 'created_by',         valueType: 'user'},
+        {label: i18n._('Last Modified Time'),                                                field: 'last_modified_time', valueType: 'date'},
+        {label: i18n._('Last Modified By'),                                                  field: 'last_modified_by',   valueType: 'user'},
+        {label: i18n._('Creation Time'),                                                     field: 'creation_time',      valueType: 'date'},
+        {label: i18n._('Created By'),                                                        field: 'created_by',         valueType: 'user'},
         {filtertype: 'tinebase.tag', app: app},
         {filtertype: 'timetracker.timeaccount'}
     ];
@@ -175,17 +175,17 @@ Tine.Timetracker.Model.Timeaccount.getFilterModel = function() {
     var app = Tine.Tinebase.appMgr.get('Timetracker');
 
     var filters = [
-        {label: _('Quick Search'),              field: 'query',       operators: ['contains']},
+        {label: i18n._('Quick Search'),              field: 'query',       operators: ['contains']},
         {label: app.i18n._('Number'),           field: 'number'       },
         {label: app.i18n._('Title'),            field: 'title'        },
         {label: app.i18n._('Description'),      field: 'description', operators: ['contains']},
         {label: app.i18n._('Billed'),           field: 'status',      filtertype: 'timetracker.timeaccountbilled'},
         {label: app.i18n._('Status'),           field: 'is_open',     filtertype: 'timetracker.timeaccountstatus'},
         {label: app.i18n._('Cleared at'),       field: 'cleared_at',  valueType: 'date'},
-        {label: _('Last Modified Time'),        field: 'last_modified_time', valueType: 'date'},
-        {label: _('Last Modified By'),          field: 'last_modified_by',   valueType: 'user'},
-        {label: _('Creation Time'),             field: 'creation_time',      valueType: 'date'},
-        {label: _('Created By'),                field: 'created_by',         valueType: 'user'},
+        {label: i18n._('Last Modified Time'),        field: 'last_modified_time', valueType: 'date'},
+        {label: i18n._('Last Modified By'),          field: 'last_modified_by',   valueType: 'user'},
+        {label: i18n._('Creation Time'),             field: 'creation_time',      valueType: 'date'},
+        {label: i18n._('Created By'),                field: 'created_by',         valueType: 'user'},
         {label: app.i18n._('Booking deadline'), field: 'deadline'},
         {filtertype: 'tinebase.tag', app: app}
     ];
index 3fb3a43..14f3854 100644 (file)
@@ -269,36 +269,36 @@ Tine.Timetracker.TimeaccountEditDialog = Ext.extend(Tine.widgets.dialog.EditDial
                 new Ext.ux.grid.CheckColumn({
                     header: this.app.i18n._('Book Own'),
                     dataIndex: 'bookOwnGrant',
-                    tooltip: _('The grant to add Timesheets to this Timeaccount'),
+                    tooltip: i18n._('The grant to add Timesheets to this Timeaccount'),
                     width: 55
                 }),
                 new Ext.ux.grid.CheckColumn({
                     header: this.app.i18n._('View All'),
-                    tooltip: _('The grant to view Timesheets of other users'),
+                    tooltip: i18n._('The grant to view Timesheets of other users'),
                     dataIndex: 'viewAllGrant',
                     width: 55
                 }),
                 new Ext.ux.grid.CheckColumn({
                     header: this.app.i18n._('Book All'),
-                    tooltip: _('The grant to add Timesheets for other users'),
+                    tooltip: i18n._('The grant to add Timesheets for other users'),
                     dataIndex: 'bookAllGrant',
                     width: 55
                 }),
                 new Ext.ux.grid.CheckColumn({
-                    header:this.app.i18n. _('Manage Clearing'),
-                    tooltip: _('The grant to manage clearing of Timesheets'),
+                    header:this.app.i18n. i18n._('Manage Clearing'),
+                    tooltip: i18n._('The grant to manage clearing of Timesheets'),
                     dataIndex: 'manageBillableGrant',
                     width: 55
                 }),
                 new Ext.ux.grid.CheckColumn({
-                    header:this.app.i18n. _('Export'),
-                    tooltip: _('The grant to export Timesheets of Timeaccount'),
+                    header:this.app.i18n. i18n._('Export'),
+                    tooltip: i18n._('The grant to export Timesheets of Timeaccount'),
                     dataIndex: 'exportGrant',
                     width: 55
                 }),
                 new Ext.ux.grid.CheckColumn({
                     header: this.app.i18n._('Manage All'),
-                    tooltip: _('Includes all other grants'),
+                    tooltip: i18n._('Includes all other grants'),
                     dataIndex: 'adminGrant',
                     width: 55
                 })
index 2784e4b..3cdf6b3 100644 (file)
@@ -157,7 +157,7 @@ Tine.Timetracker.TimeaccountGridPanel = Ext.extend(Tine.widgets.grid.GridPanel,
      */
     getToolbarItems: function(){
         this.exportButton = new Ext.Action({
-            text: _('Export'),
+            text: i18n._('Export'),
             iconCls: 'action_export',
             scope: this,
             requiredGrant: 'readGrant',
index 50106fe..80ae674 100644 (file)
@@ -374,13 +374,13 @@ Tine.Timetracker.TimesheetGridPanel = Ext.extend(Tine.widgets.grid.GridPanel, {
             '-',
             this.actions_exportTimesheet
 //            '-', {
-//            text: _('Mass Update'),
+//            text: i18n._('Mass Update'),
 //            iconCls: 'action_edit',
 //            disabled: !Tine.Tinebase.common.hasRight('manage', 'Timetracker', 'timeaccounts'),
 //            scope: this,
 //            menu: {
 //                items: [
-//                    '<b class="x-ux-menu-title">' + _('Update field:') + '</b>',
+//                    '<b class="x-ux-menu-title">' + i18n._('Update field:') + '</b>',
 //                    {
 //                        text: this.app.i18n._('Billable'),
 //                        field: 'is_billable',
index 602a348..aaefd00 100644 (file)
@@ -38,7 +38,7 @@ Tine.Tinebase.AboutDialog = Ext.extend(Ext.Window, {
     },
     
     initComponent: function() {
-        this.title = String.format(_('About {0}'), Tine.title);
+        this.title = String.format(i18n._('About {0}'), Tine.title);
         
         this.initAboutTpl();
         
@@ -53,12 +53,12 @@ Tine.Tinebase.AboutDialog = Ext.extend(Ext.Window, {
             html: this.aboutTpl.applyTemplate({
                 logo: Tine.Tinebase.LoginPanel.prototype.loginLogo,
                 logoLink: Tine.weburl,
-                linkText: String.format(_('Learn more about {0}'), Tine.title),
+                linkText: String.format(i18n._('Learn more about {0}'), Tine.title),
                 codeName: version.codeName,
                 packageString: version.packageString
             }),
             buttons: [{
-                text: _('Ok'),
+                text: i18n._('Ok'),
                 iconCls: 'action_saveAndClose',
                 handler: this.close,
                 scope: this
@@ -68,16 +68,16 @@ Tine.Tinebase.AboutDialog = Ext.extend(Ext.Window, {
         // create links
         this.on('afterrender', function() {
             var el = this.getEl().select('div.tb-about-dlg div.tb-about-credits-license a.license');
-            el.insertHtml('beforeBegin', ' ' + _('Released under different') + ' ');
-            el.insertHtml('beforeEnd', _('Open Source Licenses'));
+            el.insertHtml('beforeBegin', ' ' + i18n._('Released under different') + ' ');
+            el.insertHtml('beforeEnd', i18n._('Open Source Licenses'));
             el.on('click', function(){
                 var ls = new Tine.Tinebase.LicenseScreen();
                 ls.show();
             });
             
             var el = this.getEl().select('div.tb-about-dlg div.tb-about-credits-license a.credits');
-            el.insertHtml('beforeBegin', ' ' + _('with the help of our') + ' ');
-            el.insertHtml('beforeEnd', _('Contributors'));
+            el.insertHtml('beforeBegin', ' ' + i18n._('with the help of our') + ' ');
+            el.insertHtml('beforeEnd', i18n._('Contributors'));
             el.on('click', function() {
                 var cs = new Tine.Tinebase.CreditsScreen();
                 cs.show();
index 976e514..a1e236f 100644 (file)
@@ -72,11 +72,11 @@ Tine.Tinebase.Admin.UserProfileConfigPanel = Ext.extend(Ext.Panel, { // TODO: ex
      * @private
      */
     initComponent: function () {
-        this.title = _('Profile Information');
+        this.title = i18n._('Profile Information');
         this.items = [];
         
         this.applyAction = new Ext.Action({
-            text: _('Apply'),
+            text: i18n._('Apply'),
             disabled: true,
             iconCls: 'action_applyChanges',
             handler: this.applyConfig.createDelegate(this)
@@ -91,7 +91,7 @@ Tine.Tinebase.Admin.UserProfileConfigPanel = Ext.extend(Ext.Panel, { // TODO: ex
     afterRender: function () {
         this.supr().afterRender.apply(this, arguments);
         
-        this.loadMask = new Ext.LoadMask(this.getEl(), {msg: _('Please Wait')});
+        this.loadMask = new Ext.LoadMask(this.getEl(), {msg: i18n._('Please Wait')});
         if (! this.store) {
             (function () {
                 this.loadMask.show();
@@ -153,13 +153,13 @@ Tine.Tinebase.Admin.UserProfileConfigPanel = Ext.extend(Ext.Panel, { // TODO: ex
         
         var cbs = [
             new Ext.ux.grid.CheckColumn({
-                header: _('Read'),
-                tooltip: _('The field is readable part of the profile'),
+                header: i18n._('Read'),
+                tooltip: i18n._('The field is readable part of the profile'),
                 dataIndex: 'readGrant',
                 width: 55
             }), new Ext.ux.grid.CheckColumn({
-                header: _('Edit'),
-                tooltip: _('The field is editable part of the profile'),
+                header: i18n._('Edit'),
+                tooltip: i18n._('The field is editable part of the profile'),
                 dataIndex: 'editGrant',
                 width: 55
             })
@@ -172,7 +172,7 @@ Tine.Tinebase.Admin.UserProfileConfigPanel = Ext.extend(Ext.Panel, { // TODO: ex
             plugins: cbs,
             columns: [{
                 id: 'fieldName',
-                header: _('Field Name'),
+                header: i18n._('Field Name'),
                 dataIndex: 'fieldLabel'
             }].concat(cbs)
         });
index 7b85da2..caa57eb 100644 (file)
@@ -205,8 +205,8 @@ Ext.extend(Tine.Tinebase.AppManager, Ext.util.Observable, {
                 // no global exception concept yet...
                 //throw Ext.Error('no apps enabled', 620);
                 Ext.MessageBox.show({
-                    title: _('Missing Applications'), 
-                    msg: _('There are no applications enabled for you. Please contact your administrator.'),
+                    title: i18n._('Missing Applications'),
+                    msg: i18n._('There are no applications enabled for you. Please contact your administrator.'),
                     buttons: Ext.Msg.OK,
                     icon: Ext.MessageBox.WARNING
                 });
index efde0c3..205a5fb 100644 (file)
@@ -178,8 +178,8 @@ Ext.extend(Tine.Tinebase.Application, Ext.util.Observable , {
         }
 
         Ext.MessageBox.show(Ext.apply(defaults, {
-            title: _('Not Supported'),
-            msg: _('Your request is not supported by this version.'),
+            title: i18n._('Not Supported'),
+            msg: i18n._('Your request is not supported by this version.'),
             fn: function() {
                 Tine.Tinebase.common.reload();
             }
index 822dfe4..c1f88a9 100644 (file)
@@ -307,7 +307,7 @@ Tine.Tinebase.ApplicationStarter = {
         }
         // prepare filter
         var filter = {
-            label: globalI18n ? _(label) : app.i18n._(label),
+            label: globalI18n ? i18n._(label) : app.i18n._(label),
             field: fieldKey
         };
         
index b8c5570..a338c5e 100644 (file)
@@ -120,14 +120,14 @@ Tine.Tinebase.container = {
      */
     path2name: function(path, containerName, containersName) {
         switch (path) {
-            case '/':           return String.format(_('All {0}'), containersName);
-            case '/shared':     return String.format(_('Shared {0}'), containersName);
-            case '/personal':   return String.format(_('Other Users {0}'), containersName);
+            case '/':           return String.format(i18n._('All {0}'), containersName);
+            case '/shared':     return String.format(i18n._('Shared {0}'), containersName);
+            case '/personal':   return String.format(i18n._('Other Users {0}'), containersName);
         }
         
         if (path === Tine.Tinebase.container.getMyNodePath()
                 || path === Tine.Tinebase.container.getMyFileNodePath()) {
-            return String.format(_('My {0}'), containersName);
+            return String.format(i18n._('My {0}'), containersName);
         }
         
         return path;
index 3833709..6e78013 100644 (file)
@@ -33,7 +33,7 @@ Tine.Tinebase.CreditsScreen = Ext.extend(Ext.Window, {
      */
     initComponent: function() {
 
-        this.title = _('Credits');
+        this.title = i18n._('Credits');
         
         this.items = {
             layout: 'fit',
@@ -50,7 +50,7 @@ Tine.Tinebase.CreditsScreen = Ext.extend(Ext.Window, {
                 }
             },
             buttons: [{
-                text: _('Ok'),
+                text: i18n._('Ok'),
                 iconCls: 'action_saveAndClose',
                 handler: this.close,
                 scope: this
index fba03ba..7bf1750 100644 (file)
@@ -59,7 +59,7 @@ Tine.Tinebase.ExceptionDialog = Ext.extend(Ext.Window, {
             this.exception.traceHTML = trace;
         }
         
-        this.title = _('Abnormal End');
+        this.title = i18n._('Abnormal End');
         this.items = this.getReportForm();
         
         Tine.Tinebase.ExceptionDialog.superclass.initComponent.call(this);
@@ -100,13 +100,13 @@ Tine.Tinebase.ExceptionDialog = Ext.extend(Ext.Window, {
     initButtons: function () {
         if (Tine.Tinebase.registry && Tine.Tinebase.registry.get('preferences') && Tine.Tinebase.registry.get('preferences').get('dialogButtonsOrderStyle') === 'Windows') {
             this.reportButtons = [{
-                text: _('Send Report'),
+                text: i18n._('Send Report'),
                 iconCls: 'action_saveAndClose',
                 enabled: Tine.Tinebase.common.hasRight('report_bugs', 'Tinebase'),
                 scope: this,
                 handler: this.onSendReport
             }, {
-                text: _('Cancel'),
+                text: i18n._('Cancel'),
                 iconCls: 'action_cancel',
                 scope: this,
                 handler: function() {
@@ -116,14 +116,14 @@ Tine.Tinebase.ExceptionDialog = Ext.extend(Ext.Window, {
         }
         else {
             this.reportButtons = [{
-                text: _('Cancel'),
+                text: i18n._('Cancel'),
                 iconCls: 'action_cancel',
                 scope: this,
                 handler: function() {
                     this.close();
                 }
             }, {
-                text: _('Send Report'),
+                text: i18n._('Send Report'),
                 iconCls: 'action_saveAndClose',
                 enabled: Tine.Tinebase.common.hasRight('report_bugs', 'Tinebase'),
                 scope: this,
@@ -151,15 +151,15 @@ Tine.Tinebase.ExceptionDialog = Ext.extend(Ext.Window, {
                 xtype: 'panel',
                 border: false,
                 html: '<div class="tb-exceptiondialog-text">' + 
-                        '<p>' + _('An error occurred, the program ended abnormal.') + '</p>' +
-                        '<p>' + _('The last action you made was potentially not performed correctly.') + '</p>' +
-                        '<p>' + _('Please help improving this software and notify the vendor. Include a brief description of what you where doing when the error occurred.') + '</p>' + 
+                        '<p>' + i18n._('An error occurred, the program ended abnormal.') + '</p>' +
+                        '<p>' + i18n._('The last action you made was potentially not performed correctly.') + '</p>' +
+                        '<p>' + i18n._('Please help improving this software and notify the vendor. Include a brief description of what you where doing when the error occurred.') + '</p>' +
                     '</div>'
             }, {
                 id: 'tb-exceptiondialog-description',
                 height: 60,
                 xtype: 'textarea',
-                fieldLabel: _('Description'),
+                fieldLabel: i18n._('Description'),
                 name: 'description',
                 anchor: '95%',
                 readOnly: false
@@ -167,7 +167,7 @@ Tine.Tinebase.ExceptionDialog = Ext.extend(Ext.Window, {
                 xtype: 'fieldset',
                 id: 'tb-exceptiondialog-send-contact',
                 anchor: '95%',
-                title: _('Send Contact Information'),
+                title: i18n._('Send Contact Information'),
                 autoHeight: true,
                 checkboxToggle: true,
                 items: [{
@@ -184,7 +184,7 @@ Tine.Tinebase.ExceptionDialog = Ext.extend(Ext.Window, {
                 layout: 'form',
                 collapsible: true,
                 collapsed: this.releaseMode,
-                title: _('Details:'),
+                title: i18n._('Details:'),
                 defaults: {
                     xtype: 'textfield',
                     readOnly: true,
@@ -207,7 +207,7 @@ Tine.Tinebase.ExceptionDialog = Ext.extend(Ext.Window, {
      */
     onSendReport: function () {
         if (! this.nonInteractive) {
-            Ext.MessageBox.wait(_('Sending report...'), _('Please wait a moment'));
+            Ext.MessageBox.wait(i18n._('Sending report...'), i18n._('Please wait a moment'));
         }
         var baseUrl = Tine.bugreportUrl;
         var hash = this.generateHash();
@@ -279,8 +279,8 @@ Tine.Tinebase.ExceptionDialog = Ext.extend(Ext.Window, {
      */
     showTransmissionCompleted: function () {
         Ext.MessageBox.show({
-            title: _('Transmission Completed'),
-            msg: _('Your report has been sent. Thanks for your contribution') + '<br /><b>' + _('Please restart your browser now!') + '</b>',
+            title: i18n._('Transmission Completed'),
+            msg: i18n._('Your report has been sent. Thanks for your contribution') + '<br /><b>' + i18n._('Please restart your browser now!') + '</b>',
             buttons: Ext.MessageBox.OK,
             icon: Ext.MessageBox.INFO
         });
index e65bab9..9a4d660 100644 (file)
@@ -161,8 +161,8 @@ Tine.Tinebase.ExceptionHandler = function() {
                 Tine.Tinebase.registry.remove('currentAccount');
 
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('Authorisation Required'), 
-                    msg: _('Your session timed out. You need to login again.'),
+                    title: i18n._('Authorisation Required'),
+                    msg: i18n._('Your session timed out. You need to login again.'),
                     fn: function() {
 
                         /*
@@ -194,8 +194,8 @@ Tine.Tinebase.ExceptionHandler = function() {
             // insufficient rights
             case 403:
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('Insufficient Rights'), 
-                    msg: _('Sorry, you are not permitted to perform this action'),
+                    title: i18n._('Insufficient Rights'),
+                    msg: i18n._('Sorry, you are not permitted to perform this action'),
                     icon: Ext.MessageBox.ERROR
                 }));
                 break;
@@ -203,8 +203,8 @@ Tine.Tinebase.ExceptionHandler = function() {
             // not found
             case 404:
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('Not Found'), 
-                    msg: _('Sorry, your request could not be completed because the required data could not be found. In most cases this means that someone already deleted the data. Please refresh your current view.'),
+                    title: i18n._('Not Found'),
+                    msg: i18n._('Sorry, your request could not be completed because the required data could not be found. In most cases this means that someone already deleted the data. Please refresh your current view.'),
                     icon: Ext.MessageBox.ERROR
                 }));
                 break;
@@ -212,8 +212,8 @@ Tine.Tinebase.ExceptionHandler = function() {
             // concurrency conflict
             case 409:
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('Concurrent Updates'),
-                    msg: _('Someone else saved this record while you where editing the data. You need to reload and make your changes again.')
+                    title: i18n._('Concurrent Updates'),
+                    msg: i18n._('Someone else saved this record while you where editing the data. You need to reload and make your changes again.')
                 }));
                 break;
             
@@ -221,17 +221,17 @@ Tine.Tinebase.ExceptionHandler = function() {
             // Use this error code for generic problems like misconfig we don't want to see bugreports for
             case 503:
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('Service Unavailable'), 
-                    msg: _('The server is currently unable to handle the request due to a temporary overloading, maintenance or misconfiguration of the server. Please try again or contact your administrator.')
+                    title: i18n._('Service Unavailable'),
+                    msg: i18n._('The server is currently unable to handle the request due to a temporary overloading, maintenance or misconfiguration of the server. Please try again or contact your administrator.')
                 }));
                 break;
                 
             // invalid record exception
             case 505:
-                var message = exception.message ? '<br /><b>' + _('Server Message:') + '</b><br />' + exception.message : '';
+                var message = exception.message ? '<br /><b>' + i18n._('Server Message:') + '</b><br />' + exception.message : '';
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('Invalid Data'),
-                    msg: _('Your input data is not valid. Please provide valid data.') + message
+                    title: i18n._('Invalid Data'),
+                    msg: i18n._('Your input data is not valid. Please provide valid data.') + message
                 }));
                 break;
             // server communication loss
@@ -243,14 +243,14 @@ Tine.Tinebase.ExceptionHandler = function() {
                 //       - so we defer the alert. In case of reload/redirect the deferd fn dosn't get executed
                 //         if the new contet/html arrives before the defer time is over.
                 //       - this might not always be the case due to network, service or session problems
-                (function() {alert(_('Connection lost, please check your network!'))}).defer(1000);
+                (function() {alert(i18n._('Connection lost, please check your network!'))}).defer(1000);
                 break;
                 
             // transaction aborted / timeout
             case 520:
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('Timeout'), 
-                    msg: _('Sorry, some timeout occured while processing your request. Please reload your browser, try again or contact your administrator.')
+                    title: i18n._('Timeout'),
+                    msg: i18n._('Sorry, some timeout occured while processing your request. Please reload your browser, try again or contact your administrator.')
                 }));
                 
                 break;
@@ -258,16 +258,16 @@ Tine.Tinebase.ExceptionHandler = function() {
             // empty response
             case 540:
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('No Response'), 
-                    msg: _('Sorry, the Server did not respond any data. Please reload your browser, try again or contact your administrator.')
+                    title: i18n._('No Response'),
+                    msg: i18n._('Sorry, the Server did not respond any data. Please reload your browser, try again or contact your administrator.')
                 }));
                 break;
             
             // memory exhausted
             case 550: 
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('Out of Resources'), 
-                    msg: _('Sorry, the Server stated a "memory exhausted" condition. Please contact your administrator.')
+                    title: i18n._('Out of Resources'),
+                    msg: i18n._('Sorry, the Server stated a "memory exhausted" condition. Please contact your administrator.')
                 }));
                 break;
                 
@@ -275,32 +275,32 @@ Tine.Tinebase.ExceptionHandler = function() {
                 
             case 600:
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _(exception.title), 
-                    msg: _(exception.message)
+                    title: i18n._(exception.title),
+                    msg: i18n._(exception.message)
                 }));
                 break;
                 
             // user in no role
             case 610:
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('No Role Memberships'), 
-                    msg: _('Your user account has no role memberships. Please contact your administrator.')
+                    title: i18n._('No Role Memberships'),
+                    msg: i18n._('Your user account has no role memberships. Please contact your administrator.')
                 }));
                 break;
                 
             // Tinebase_Exception_InvalidRelationConstraints
             case 912: 
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _(exception.title),
-                    msg: _(exception.message)
+                    title: i18n._(exception.title),
+                    msg: i18n._(exception.message)
                 }));
                 break;
                 
             // lost/insufficent permissions for api call or bad api call
             case -32601:
                 Ext.MessageBox.show(Ext.apply(defaults, {
-                    title: _('Method Not Found / Insufficent Permissions'), 
-                    msg: _('You tried to access a function that is not available. Please reload your browser, try again or contact your administrator.')
+                    title: i18n._('Method Not Found / Insufficent Permissions'),
+                    msg: i18n._('You tried to access a function that is not available. Please reload your browser, try again or contact your administrator.')
                 }));
                 break;
             
index 11a9113..f99c542 100644 (file)
@@ -32,7 +32,7 @@ Tine.Tinebase.LicenseScreen = Ext.extend(Ext.Window, {
      */
     initComponent: function() {
 
-        this.title = _('License');
+        this.title = i18n._('License');
         
         this.items = {
             layout: 'fit',
@@ -48,7 +48,7 @@ Tine.Tinebase.LicenseScreen = Ext.extend(Ext.Window, {
                 }
             },
             buttons: [{
-                text: _('Ok'),
+                text: i18n._('Ok'),
                 iconCls: 'action_saveAndClose',
                 handler: this.close,
                 scope: this
index f32d3f7..4970ea3 100644 (file)
@@ -80,7 +80,7 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                 }, {
                     xtype: 'label',
                     cls: 'tb-login-big-label',
-                    text: _('Login')
+                    text: i18n._('Login')
                 }, {
                     xtype: 'tinelangchooser',
                     name: 'locale',
@@ -90,7 +90,7 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                     xtype: 'textfield',
                     tabindex: 2,
                     width: 170,
-                    fieldLabel: _('Username'),
+                    fieldLabel: i18n._('Username'),
                     id: 'username',
                     name: 'username',
                     allowBlank: modSsl ? false : true,
@@ -108,7 +108,7 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                     tabindex: 3,
                     width: 170,
                     inputType: 'password',
-                    fieldLabel: _('Password'),
+                    fieldLabel: i18n._('Password'),
                     id: 'password',
                     name: 'password',
                     //allowBlank: false,
@@ -125,7 +125,7 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                         align: 'center',
                         marginTop: '10px'
                     },
-                    value: _('Certificate detected. Please, press Login button to proceed.'),
+                    value: i18n._('Certificate detected. Please, press Login button to proceed.'),
                     hidden: modSsl ? false : true
                 }, {
                     xtype: 'container',
@@ -156,7 +156,7 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                 buttons: [{
                     xtype: 'button',
                     width: 120,
-                    text: _('Login'),
+                    text: i18n._('Login'),
                     scope: this,
                     handler: this.onLoginPress
                 }]
@@ -182,7 +182,7 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                 packageString: 'unknown'
             };
             
-            var versionHtml = '<label class="tb-version-label">' + _('Version') + ':</label> ' +
+            var versionHtml = '<label class="tb-version-label">' + i18n._('Version') + ':</label> ' +
                               '<label class="tb-version-codename">' + version.codeName + '</label> ' +
                               '<label class="tb-version-packagestring">(' + version.packageString + ')</label>';
             this.versionPanel = new Ext.Container({
@@ -214,28 +214,28 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                 defaults: {xtype: 'label'},
                 items: [{
                     cls: 'tb-login-big-label',
-                    html: String.format(_('{0} is made for you'), Tine.title)
+                    html: String.format(i18n._('{0} is made for you'), Tine.title)
                 }, {
-                    html: '<p>' + String.format(_('{0} wants to make business collaboration easier and more enjoyable - for your needs! So you are warmly welcome to discuss with us, bring in ideas and get help.'), Tine.title) + '</p>'
+                    html: '<p>' + String.format(i18n._('{0} wants to make business collaboration easier and more enjoyable - for your needs! So you are warmly welcome to discuss with us, bring in ideas and get help.'), Tine.title) + '</p>'
                 }, {
                     cls: 'tb-login-big-label-spacer',
                     html: '&nbsp;'
                 }, {
                     html: '<ul>' + 
-                        '<li><a target="_blank" href="' + Tine.weburl + '" border="0">' + String.format(_('{0} Homepage'), Tine.title) + '</a></li>' +
-                        '<li><a target="_blank" href="http://www.tine20.org/forum/" border="0">' + String.format(_('{0} Forum'), Tine.title) + '</a></li>' +
+                        '<li><a target="_blank" href="' + Tine.weburl + '" border="0">' + String.format(i18n._('{0} Homepage'), Tine.title) + '</a></li>' +
+                        '<li><a target="_blank" href="http://www.tine20.org/forum/" border="0">' + String.format(i18n._('{0} Forum'), Tine.title) + '</a></li>' +
                     '</ul><br/>'
                 }, {
                     cls: 'tb-login-big-label',
-                    html: _('Translations')
+                    html: i18n._('Translations')
                 }, {
-                    html: Ext.isDefined(percentageCompleted) ? ('<p>' + String.format(_('Translation state of {0}: {1}%.'), language, percentageCompleted) + '</p>') : ''
+                    html: Ext.isDefined(percentageCompleted) ? ('<p>' + String.format(i18n._('Translation state of {0}: {1}%.'), language, percentageCompleted) + '</p>') : ''
                 }, {
-                    html: '<p>' + String.format(_('If the state of your language is not satisfying, or if you miss a language, please consider becoming a {0} translator.'), Tine.title) + '</p>'
+                    html: '<p>' + String.format(i18n._('If the state of your language is not satisfying, or if you miss a language, please consider becoming a {0} translator.'), Tine.title) + '</p>'
                 }, {
                     html: '<br/><ul>' +
-                        '<li><a target="_blank" href="http://www.tine20.org/wiki/index.php/Contributors/Howtos/Translations" border="0">' + String.format(_('{0} Translation Howto'), Tine.title) + '</a></li>' +
-                        '<li><a target="_blank" href="https://www.transifex.com/projects/p/tine20/" border="0">' + _('Detailed Language Statistics') + '</a></li>'
+                        '<li><a target="_blank" href="http://www.tine20.org/wiki/index.php/Contributors/Howtos/Translations" border="0">' + String.format(i18n._('{0} Translation Howto'), Tine.title) + '</a></li>' +
+                        '<li><a target="_blank" href="https://www.transifex.com/projects/p/tine20/" border="0">' + i18n._('Detailed Language Statistics') + '</a></li>'
                     + '</ul>'
                 }]
             });
@@ -255,7 +255,7 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                 defaults: {xtype: 'label'},
                 items: [{
                     html: "<div class='tine-viewport-poweredby' style='position: absolute; bottom: 10px; right: 10px; font:normal 12px arial, helvetica,tahoma,sans-serif;'>" + 
-                        _("Powered by:") + " <a target='_blank' href='" + Tine.weburl + "' title='" + _("online open source groupware and crm") + "'>" + Tine.title + "</a>"
+                        i18n._("Powered by:") + " <a target='_blank' href='" + Tine.weburl + "' title='" + i18n._("online open source groupware and crm") + "'>" + Tine.title + "</a>"
                 }]
             });
         }
@@ -305,20 +305,20 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                         if (Ext.isDate(enddate) && enddate.getTime() > new Date().getTime() && 
                             Tine.clientVersion.packageString.indexOf(version) === 0) {
                             Tine.log.debug('Show survey panel');
-                            survey.data.lang_duration = String.format(_('about {0} minutes'), survey.data.duration);
+                            survey.data.lang_duration = String.format(i18n._('about {0} minutes'), survey.data.duration);
                             survey.data.link = 'https://versioncheck.tine20.net/surveyCheck/surveyCheck.php?participate';
                             
                             this.surveyPanel.add([{
                                 cls: 'tb-login-big-label',
-                                html: _('Tine 2.0 needs your help')
+                                html: i18n._('Tine 2.0 needs your help')
                             }, {
-                                html: '<p>' + _('We regularly need your feedback to make the next Tine 2.0 releases fit your needs even better. Help us and yourself by participating:') + '</p>'
+                                html: '<p>' + i18n._('We regularly need your feedback to make the next Tine 2.0 releases fit your needs even better. Help us and yourself by participating:') + '</p>'
                             }, {
                                 html: this.getSurveyTemplate().apply(survey.data)
                             }, {
                                 xtype: 'button',
                                 width: 120,
-                                text: _('participate!'),
+                                text: i18n._('participate!'),
                                 handler: function () {
                                     window.open(survey.data.link);
                                 }
@@ -340,8 +340,8 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                 '<p><b>{title}</b></p>',
                 '<p><a target="_blank" href="{link}" border="0">{subtitle}</a></p>',
                 '<br/>',
-                '<p>', _('Languages'), ': {langs}</p>',
-                '<p>', _('Duration'), ': {lang_duration}</p>',
+                '<p>', i18n._('Languages'), ': {langs}</p>',
+                '<p>', i18n._('Duration'), ': {lang_duration}</p>',
                 '<br/>').compile();
         }
         
@@ -382,22 +382,22 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
             if (browserSupport == 'incompatible') {
                 items = [{
                     cls: 'tb-login-big-label',
-                    html: _('Browser incompatible')
+                    html: i18n._('Browser incompatible')
                 }, {
-                    html: '<p>' + _('Your browser is not supported by Tine 2.0.') + '<br/><br/></p>'
+                    html: '<p>' + i18n._('Your browser is not supported by Tine 2.0.') + '<br/><br/></p>'
                 }];
             } else if (browserSupport == 'unknown') {
                 items = [{
                     cls: 'tb-login-big-label',
-                    html: _('Browser incompatible?')
+                    html: i18n._('Browser incompatible?')
                 }, {
-                    html: '<p>' + _('You are using an unrecognized browser. This could result in unexpected behaviour.') + '<br/><br/></p>'
+                    html: '<p>' + i18n._('You are using an unrecognized browser. This could result in unexpected behaviour.') + '<br/><br/></p>'
                 }];
             }
             
             if (browserSupport != 'compatible') {
                 this.browserIncompatiblePanel.add(items.concat([{
-                    html: '<p>' + _('You might try one of these browsers:') + '<br/>'
+                    html: '<p>' + i18n._('You might try one of these browsers:') + '<br/>'
                         + '<a href="http://www.google.com/chrome" target="_blank">Google Chrome</a><br/>'
                         + '<a href="http://www.mozilla.com/firefox/" target="_blank">Mozilla Firefox</a><br/>'
                         + '<a href="http://www.apple.com/safari/download/" target="_blank">Apple Safari</a><br/>'    
@@ -457,7 +457,7 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
             values = form.getValues();
             
         if (form.isValid()) {
-            Ext.MessageBox.wait(_('Logging you in...'), _('Please wait'));
+            Ext.MessageBox.wait(i18n._('Logging you in...'), i18n._('Please wait'));
 
             Ext.Ajax.request({
                 scope: this,
@@ -471,15 +471,15 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                 success:function(response) {
                     var responseData = Ext.util.JSON.decode(response.responseText);
                     if (responseData.success === true) {
-                        Ext.MessageBox.wait(String.format(_('Login successful. Loading {0}...'), Tine.title), _('Please wait!'));
+                        Ext.MessageBox.wait(String.format(i18n._('Login successful. Loading {0}...'), Tine.title), i18n._('Please wait!'));
                         window.document.title = this.originalTitle;
                         this.onLogin.call(this.scope, response);
                     } else {
                         var modSsl = Tine.Tinebase.registry.get('modSsl');
-                        var resultMsg = modSsl ? _('There was an error verifying your certificate!!!') :
-                            _('Your username and/or your password are wrong!!!');
+                        var resultMsg = modSsl ? i18n._('There was an error verifying your certificate!!!') :
+                            i18n._('Your username and/or your password are wrong!!!');
                         Ext.MessageBox.show({
-                            title: _('Login failure'),
+                            title: i18n._('Login failure'),
                             msg: resultMsg,
                             buttons: Ext.MessageBox.OK,
                             icon: Ext.MessageBox.ERROR,
@@ -497,7 +497,7 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
                 }
             });
         } else {
-            Ext.MessageBox.alert(_('Errors'), _('Please fix the errors noted.'));
+            Ext.MessageBox.alert(i18n._('Errors'), i18n._('Please fix the errors noted.'));
         }
     },
     
@@ -512,7 +512,7 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
         
         this.originalTitle = window.document.title;
         var postfix = (Tine.Tinebase.registry.get('titlePostfix')) ? Tine.Tinebase.registry.get('titlePostfix') : '';
-        window.document.title = Ext.util.Format.stripTags(Tine.title + postfix + ' - ' + _('Please enter your login data'));
+        window.document.title = Ext.util.Format.stripTags(Tine.title + postfix + ' - ' + i18n._('Please enter your login data'));
     },
     
     onResize: function () {
@@ -540,9 +540,9 @@ Tine.Tinebase.LoginPanel = Ext.extend(Ext.Panel, {
     renderSurveyPanel: function (survey) {
         var items = [{
             cls: 'tb-login-big-label',
-            html: _('Tine 2.0 needs your help')
+            html: i18n._('Tine 2.0 needs your help')
         }, {
-            html: '<p>' + _('We regularly need your feedback to make the next Tine 2.0 releases fit your needs even better. Help us and yourself by participating:') + '</p>'
+            html: '<p>' + i18n._('We regularly need your feedback to make the next Tine 2.0 releases fit your needs even better. Help us and yourself by participating:') + '</p>'
         }];
     }
 });
index 6b3ffa2..f02b982 100644 (file)
@@ -63,7 +63,7 @@ Tine.Tinebase.MainMenu = Ext.extend(Ext.Toolbar, {
         // TODO add a bigger spacer here?
         { xtype: 'spacer' },
         {
-            text: String.format(_('User: {0}'), Tine.Tinebase.registry.get('currentAccount').accountDisplayName),
+            text: String.format(i18n._('User: {0}'), Tine.Tinebase.registry.get('currentAccount').accountDisplayName),
             menu: this.getUserActions(),
             menuAlign: 'tr-br',
             iconCls: Tine.Tinebase.registry.get('userAccountChanged') ? 'renderer_accountUserChangedIcon' : 'renderer_accountUserIcon'
@@ -109,7 +109,7 @@ Tine.Tinebase.MainMenu = Ext.extend(Ext.Toolbar, {
             if (Tine.Tinebase.registry.get('userAccountChanged')) {
                 this.action_returnToOriginalUser = new Tine.widgets.account.ChangeAccountAction({
                     returnToOriginalUser: true,
-                    text: _('Return to original user account')
+                    text: i18n._('Return to original user account')
                 });
                 this.userActions = this.userActions.concat(this.action_returnToOriginalUser);
                 
@@ -143,55 +143,55 @@ Tine.Tinebase.MainMenu = Ext.extend(Ext.Toolbar, {
      */
     initActions: function() {
         this.action_aboutTine = new Ext.Action({
-            text: String.format(_('About {0}'), Tine.title),
+            text: String.format(i18n._('About {0}'), Tine.title),
             handler: this.onAboutTine20,
             iconCls: 'action_about'
         });
         
         this.action_loadTutorial = new Ext.Action({
-            text: String.format(_('Help')),
+            text: String.format(i18n._('Help')),
             iconCls: 'action_loadTutorial',
             handler: this.onLoadTutorial,
             scope: this
         });
 
         this.action_showDebugConsole = new Ext.Action({
-            text: _('Debug Console (Ctrl + F11)'),
+            text: i18n._('Debug Console (Ctrl + F11)'),
             handler: Tine.Tinebase.common.showDebugConsole,
             iconCls: 'tinebase-action-debug-console'
         });
         
         this.action_showPreferencesDialog = new Ext.Action({
-            text: _('Preferences'),
+            text: i18n._('Preferences'),
             disabled: false,
             handler: this.onEditPreferences,
             iconCls: 'action_adminMode'
         });
 
         this.action_editProfile = new Ext.Action({
-            text: _('Edit Profile'),
+            text: i18n._('Edit Profile'),
             disabled: false,
             handler: this.onEditProfile,
             iconCls: 'tinebase-accounttype-user'
         });
         
         this.action_changePassword = new Ext.Action({
-            text: _('Change password'),
+            text: i18n._('Change password'),
             handler: this.onChangePassword,
             disabled: (! Tine.Tinebase.configManager.get('changepw')),
             iconCls: 'action_password'
         });
         
         this.action_logout = new Ext.Action({
-            text: _('Logout'),
-            tooltip:  String.format(_('Logout from {0}'), Tine.title),
+            text: i18n._('Logout'),
+            tooltip:  String.format(i18n._('Logout from {0}'), Tine.title),
             iconCls: 'action_logOut',
             handler: this.onLogout,
             scope: this
         });
         
         this.actionLearnMore = new Ext.Action({
-            text: String.format(_('Learn more about {0}'), Tine.title),
+            text: String.format(i18n._('Learn more about {0}'), Tine.title),
             tooltip: Tine.weburl,
             iconCls: 'tine-favicon',
             handler: function() {
@@ -201,8 +201,8 @@ Tine.Tinebase.MainMenu = Ext.extend(Ext.Toolbar, {
         });
         
         this.action_notificationPermissions = new Ext.Action({
-            text: _('Allow desktop notifications'),
-            tooltip:  _('Request permissions for webkit desktop notifications.'),
+            text: i18n._('Allow desktop notifications'),
+            tooltip:  i18n._('Request permissions for webkit desktop notifications.'),
             iconCls: 'action_edit',
             disabled: ! (window.webkitNotifications && window.webkitNotifications.checkPermission() != 0),
             handler: function() {
@@ -257,7 +257,7 @@ Tine.Tinebase.MainMenu = Ext.extend(Ext.Toolbar, {
      */
     onLogout: function() {
         if (Tine.Tinebase.registry.get('confirmLogout') != '0') {
-            Ext.MessageBox.confirm(_('Confirm'), _('Are you sure you want to logout?'), function(btn, text) {
+            Ext.MessageBox.confirm(i18n._('Confirm'), i18n._('Are you sure you want to logout?'), function(btn, text) {
                 if (btn == 'yes') {
                     this._doLogout();
                 }
@@ -271,7 +271,7 @@ Tine.Tinebase.MainMenu = Ext.extend(Ext.Toolbar, {
      * logout user & redirect
      */
     _doLogout: function() {
-        Ext.MessageBox.wait(_('Logging you out...'), _('Please wait!'));
+        Ext.MessageBox.wait(i18n._('Logging you out...'), i18n._('Please wait!'));
         Ext.Ajax.request( {
             params : {
                 method : Ext.isObject(Tine.Setup) ? 'Setup.logout' : 'Tinebase.logout'
index 5ff604c..50b6297 100644 (file)
@@ -136,7 +136,7 @@ Tine.Tinebase.MainScreenPanel = Ext.extend(Ext.Panel, {
         
         if (Tine.Tinebase.registry.get('mustchangepw')) {
             var passwordDialog = new Tine.Tinebase.PasswordChangeDialog({
-                title: _('Your password expired. Please enter a new user password:')
+                title: i18n._('Your password expired. Please enter a new user password:')
             });
             passwordDialog.show();
         }
index 18addca..fd33fb1 100644 (file)
@@ -444,7 +444,7 @@ Tine.Tinebase.Model.Department = Tine.Tinebase.data.Record.create([
 
 Tine.Tinebase.Model.Department.getFilterModel = function() {
     return [
-        {label: _('Name'),          field: 'name',       operators: ['contains']}
+        {label: i18n._('Name'),          field: 'name',       operators: ['contains']}
     ];
 };
 
index 6a110c8..97380d2 100644 (file)
@@ -29,7 +29,7 @@ Tine.Tinebase.PasswordChangeDialog = Ext.extend(Ext.Window, {
 
     initComponent: function() {
         this.currentAccount = Tine.Tinebase.registry.get('currentAccount');
-        this.title = (this.title !== null) ? this.title : String.format(_('Change Password For "{0}"'), this.currentAccount.accountDisplayName);
+        this.title = (this.title !== null) ? this.title : String.format(i18n._('Change Password For "{0}"'), this.currentAccount.accountDisplayName);
         
         this.items = new Ext.FormPanel({
             bodyStyle: 'padding:5px;',
@@ -44,25 +44,25 @@ Tine.Tinebase.PasswordChangeDialog = Ext.extend(Ext.Window, {
             },
             items: [{
                 id: 'oldPassword',
-                fieldLabel: _('Old Password'), 
+                fieldLabel: i18n._('Old Password'),
                 name:'oldPassword'
             },{
                 id: 'newPassword',
-                fieldLabel: _('New Password'), 
+                fieldLabel: i18n._('New Password'),
                 name:'newPassword'
             },{
                 id: 'newPasswordSecondTime',
-                fieldLabel: _('Repeat new Password'), 
+                fieldLabel: i18n._('Repeat new Password'),
                 name:'newPasswordSecondTime'
             }],
             buttons: [{
-                text: _('Cancel'),
+                text: i18n._('Cancel'),
                 iconCls: 'action_cancel',
                 handler: function() {
                     Ext.getCmp('changePassword_window').close();
                 }
             }, {
-                text: _('Ok'),
+                text: i18n._('Ok'),
                 iconCls: 'action_saveAndClose',
                 handler: function() {
                     var form = Ext.getCmp('changePasswordPanel').getForm();
@@ -71,8 +71,8 @@ Tine.Tinebase.PasswordChangeDialog = Ext.extend(Ext.Window, {
                         values = form.getValues();
                         if (values.newPassword == values.newPasswordSecondTime) {
                             Ext.Ajax.request({
-                                waitTitle: _('Please Wait!'),
-                                waitMsg: _('changing password...'),
+                                waitTitle: i18n._('Please Wait!'),
+                                waitMsg: i18n._('changing password...'),
                                 params: {
                                     method: 'Tinebase.changePassword',
                                     oldPassword: values.oldPassword,
@@ -83,8 +83,8 @@ Tine.Tinebase.PasswordChangeDialog = Ext.extend(Ext.Window, {
                                     if (response.success) {
                                         Ext.getCmp('changePassword_window').close();
                                         Ext.MessageBox.show({
-                                            title: _('Success'),
-                                            msg: _('Your password has been changed.'),
+                                            title: i18n._('Success'),
+                                            msg: i18n._('Your password has been changed.'),
                                             buttons: Ext.MessageBox.OK,
                                             icon: Ext.MessageBox.INFO
                                         });
@@ -96,7 +96,7 @@ Tine.Tinebase.PasswordChangeDialog = Ext.extend(Ext.Window, {
                                         });
                                     } else {
                                         Ext.MessageBox.show({
-                                            title: _('Failure'),
+                                            title: i18n._('Failure'),
                                             msg: response.errorMessage,
                                             buttons: Ext.MessageBox.OK,
                                             icon: Ext.MessageBox.ERROR  
@@ -106,8 +106,8 @@ Tine.Tinebase.PasswordChangeDialog = Ext.extend(Ext.Window, {
                             });
                         } else {
                             Ext.MessageBox.show({
-                                title: _('Failure'),
-                                msg: _('The new passwords mismatch, please correct them.'),
+                                title: i18n._('Failure'),
+                                msg: i18n._('The new passwords mismatch, please correct them.'),
                                 buttons: Ext.MessageBox.OK,
                                 icon: Ext.MessageBox.ERROR 
                             });
index 1367646..e34c771 100644 (file)
@@ -307,7 +307,7 @@ Tine.Tinebase.common = {
                         qtipText += ' | ' + Tine.Tinebase.common.doubleEncode(tags[i].description);
                     }
                     if (tags[i].occurrence) {
-                        qtipText += ' (' + _('Usage:&#160;') + tags[i].occurrence + ')';
+                        qtipText += ' (' + i18n._('Usage:&#160;') + tags[i].occurrence + ')';
                     }
                     result += '<div ext:qtip="' + qtipText + '" class="tb-grid-tags" style="background-color:' + (tags[i].color ? tags[i].color : '#fff') + ';">&#160;</div>';
                 }
@@ -328,12 +328,12 @@ Tine.Tinebase.common = {
                 '<div class="tb-grid-tags" style="background-color:{values.color};">&#160;</div>',
                 '<div class="x-widget-tag-tagitem-text" ext:qtip="', 
                     '{[this.encode(values.name)]}', 
-                    '<tpl if="type == \'personal\' ">&nbsp;<i>(' + _('personal') + ')</i></tpl>',
+                    '<tpl if="type == \'personal\' ">&nbsp;<i>(' + i18n._('personal') + ')</i></tpl>',
                     '</i>&nbsp;[{occurrence}]',
                     '<tpl if="description != null && description.length &gt; 1"><hr>{[this.encode(values.description)]}</tpl>" >',
                     
                     '&nbsp;{[this.encode(values.name)]}',
-                    '<tpl if="type == \'personal\' ">&nbsp;<i>(' + _('personal') + ')</i></tpl>',
+                    '<tpl if="type == \'personal\' ">&nbsp;<i>(' + i18n._('personal') + ')</i></tpl>',
                 '</div>',
             {
                 encode: function(value) {
@@ -346,7 +346,7 @@ Tine.Tinebase.common = {
             }).compile();
         }
         
-        var result =  _('No Information');
+        var result =  i18n._('No Information');
         
         if (tag && Ext.isFunction(tag.beginEdit)) {
             // support records
@@ -384,7 +384,7 @@ Tine.Tinebase.common = {
             ).compile();
         }
         
-        var result =  _('No Information');
+        var result =  i18n._('No Information');
         
         // support container records
         if (container && Ext.isFunction(container.beginEdit)) {
@@ -454,9 +454,9 @@ Tine.Tinebase.common = {
         }
         
         if (! format || ! Ext.isString(format)) {
-            s = String.format(Tine.Tinebase.translation.ngettext('{0} minute', '{0} minutes', i), i);
-            Hs = String.format(Tine.Tinebase.translation.ngettext('{0} hour', '{0} hours', H), H);
-            //var ds = String.format(Tine.Tinebase.translation.ngettext('{0} workday', '{0} workdays', d), d);
+            s = String.format(i18n.ngettext('{0} minute', '{0} minutes', i), i);
+            Hs = String.format(i18n.ngettext('{0} hour', '{0} hours', H), H);
+            //var ds = String.format(i18n.ngettext('{0} workday', '{0} workdays', d), d);
             
             if (i === 0) {
                 s = Hs;
@@ -483,7 +483,7 @@ Tine.Tinebase.common = {
             m = Math.floor(seconds / 60),
             result = '';
         
-        var secondResult = String.format(Tine.Tinebase.translation.ngettext('{0} second', '{0} seconds', s), s);
+        var secondResult = String.format(i18n.ngettext('{0} second', '{0} seconds', s), s);
         
         if (m) {
             result = Tine.Tinebase.common.minutesRenderer(m);
@@ -546,7 +546,7 @@ Tine.Tinebase.common = {
         }
         
         if (displayName == 'Anyone') {
-            displayName = _(displayName);
+            displayName = i18n._(displayName);
             type = 'group';
         }
         
@@ -853,7 +853,7 @@ Tine.Tinebase.common = {
      * @param Boolean closewindow
      */
     confirmApplicationRestart: function (closewindow) {
-        Ext.Msg.confirm(_('Confirm'), _('Restart application to apply new configuration?'), function (btn) {
+        Ext.Msg.confirm(i18n._('Confirm'), i18n._('Restart application to apply new configuration?'), function (btn) {
             if (btn == 'yes') {
                 // reload mainscreen to make sure registry gets updated
                 Tine.Tinebase.common.reload();
index fded58e..5441911 100644 (file)
@@ -262,25 +262,25 @@ Tine.Tinebase.data.Record.create = function(o, meta) {
     };
     f.getRecordName = function() {
         var app = Tine.Tinebase.appMgr.get(p.appName),
-            i18n = app && app.i18n ? app.i18n :Tine.Tinebase.translation;
+            i18n = app && app.i18n ? app.i18n :i18n;
             
         return i18n.n_(p.recordName, p.recordsName, 1);
     };
     f.getRecordsName = function() {
         var app = Tine.Tinebase.appMgr.get(p.appName),
-            i18n = app && app.i18n ? app.i18n :Tine.Tinebase.translation;
+            i18n = app && app.i18n ? app.i18n :i18n;
             
         return i18n.n_(p.recordName, p.recordsName, 50);
     };
     f.getContainerName = function() {
         var app = Tine.Tinebase.appMgr.get(p.appName),
-            i18n = app && app.i18n ? app.i18n :Tine.Tinebase.translation;
+            i18n = app && app.i18n ? app.i18n :i18n;
             
         return i18n.n_(p.containerName, p.containersName, 1);
     };
     f.getContainersName = function() {
         var app = Tine.Tinebase.appMgr.get(p.appName),
-            i18n = app && app.i18n ? app.i18n :Tine.Tinebase.translation;
+            i18n = app && app.i18n ? app.i18n :i18n;
             
         return i18n.n_(p.containerName, p.containersName, 50);
     };
index 32b6fc9..d80cfdf 100644 (file)
@@ -17,10 +17,10 @@ Ext.namespace('Tine.Tinebase');
  */
 Tine.Tinebase.prototypeTranslation = function() {
     // html editor plugin translations
-    Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[1].tooltip.title = _('Outdent Text');
-    Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[1].overflowText = _('Outdent Text');
-    Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[2].tooltip.title = _('Indent Text');
-    Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[2].overflowText = _('Indent Text');
-    Ext.ux.form.HtmlEditor.RemoveFormat.prototype.midasBtns[1].tooltip.title = _('Remove Formatting');
-    Ext.ux.form.HtmlEditor.RemoveFormat.prototype.midasBtns[1].overflowText = _('Remove Formatting');
+    Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[1].tooltip.title = i18n._('Outdent Text');
+    Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[1].overflowText = i18n._('Outdent Text');
+    Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[2].tooltip.title = i18n._('Indent Text');
+    Ext.ux.form.HtmlEditor.IndentOutdent.prototype.midasBtns[2].overflowText = i18n._('Indent Text');
+    Ext.ux.form.HtmlEditor.RemoveFormat.prototype.midasBtns[1].tooltip.title = i18n._('Remove Formatting');
+    Ext.ux.form.HtmlEditor.RemoveFormat.prototype.midasBtns[1].overflowText = i18n._('Remove Formatting');
 }
index 4f391ef..64fd8c7 100644 (file)
@@ -769,11 +769,9 @@ Tine.Tinebase.tineInit = {
      */
     initLocale: function () {
         //Locale.setlocale(Locale.LC_ALL, '');
-        Tine.Tinebase.translation = new Locale.Gettext();
-        Tine.Tinebase.translation.textdomain('Tinebase');
-        window._ = function (msgid) {
-            return Tine.Tinebase.translation.dgettext('Tinebase', msgid);
-        };
+        window.i18n = new Locale.Gettext();
+        window.i18n.textdomain('Tinebase');
+
         Tine.Tinebase.prototypeTranslation();
     }
 };
index 57c772b..182697e 100644 (file)
@@ -53,9 +53,9 @@ Ext.extend(Ext.ux.ConnectionStatus, Ext.Button, {
     initComponent: function() {
         Ext.ux.ConnectionStatus.superclass.initComponent.call(this);
         
-        this.onlineText = '(' + _('online') + ')';
-        this.offlineText = '(' + _('offline') + ')';
-        this.unknownText = '(' + _('unknown') + ')';
+        this.onlineText = '(' + i18n._('online') + ')';
+        this.offlineText = '(' + i18n._('offline') + ')';
+        this.unknownText = '(' + i18n._('unknown') + ')';
         
         // M$ IE has not online/offline events yet
         if (Ext.isIE6 || Ext.isIE7 || ! window.navigator || window.navigator.onLine === undefined) {
index 8b8a1f2..e0e906b 100644 (file)
@@ -226,7 +226,7 @@ Ext.ux.PercentRendererWithName = function(value, metadata, record) {
 
     var additionalStyle = '';
     if(record.get('status') == 'paused' && percent < 100) {
-        fileName = _('(paused)') + '&#160;&#160;' + fileName;
+        fileName = i18n._('(paused)') + '&#160;&#160;' + fileName;
         additionalStyle = 'background-image: url(\'styles/images/tine20/progress/progress-bg-y.gif\') !important;';
     }
        
index 75ede21..83a3162 100644 (file)
@@ -241,8 +241,8 @@ Ext.ux.PopupWindow.close = function(win) {
     //        }
     //
     //        win.Ext.MessageBox.alert(
-    //            _('Window can be closed'),
-    //            String.format(_('This Window can be closed now. To avoid this message please deactivate your browsers popup blocker for {0}'), Tine.title),
+    //            i18n._('Window can be closed'),
+    //            String.format(i18n._('This Window can be closed now. To avoid this message please deactivate your browsers popup blocker for {0}'), Tine.title),
     //            function() {
     //                win.close();
     //            }
index dbffcca..3add228 100644 (file)
@@ -172,7 +172,7 @@ Ext.ux.PopupWindowGroup = function(config) {
 //                front = win;
                 // NOTE: we don't recognise the front window yet
 //                if (Ext.isOpera) {
-//                    Ext.Msg.alert(_("The window you want to work with is backgrounded. Your browser doesn't support to foreground the window for you, so you need to use your operating systems window switching features. Please send complaints to your browser vendor!"))
+//                    Ext.Msg.alert(i18n._("The window you want to work with is backgrounded. Your browser doesn't support to foreground the window for you, so you need to use your operating systems window switching features. Please send complaints to your browser vendor!"))
 //                }
                 //orderWindows();
                 return true;
index d6d0e9e..90b1792 100644 (file)
@@ -41,7 +41,7 @@ Ext.ux.SearchField = Ext.extend(Ext.form.TwinTriggerField, {
      * @private
      */
     initComponent : function(){
-        this.emptyText = _('enter searchfilter');
+        this.emptyText = i18n._('enter searchfilter');
         
         Ext.ux.SearchField.superclass.initComponent.call(this);
         this.on('specialkey', function(f, e){
index d3c632d..3cace29 100644 (file)
@@ -40,7 +40,7 @@ Ext.ux.form.ComboBoxRecentsPlugin.prototype = {
             if (recents) {
                 var other = {};
                 other[recordType.getMeta('idProperty')] = 'other';
-                other[recordType.getMeta('titleProperty')] = String.format(_('choose other {0}...'), recordType.getRecordsName());
+                other[recordType.getMeta('titleProperty')] = String.format(i18n._('choose other {0}...'), recordType.getRecordsName());
                 recents.push(new recordClass(other));
                 
                 this.cmp.store.loadRecords(recents, {add: false}, true);
index 2aea874..79bed4a 100644 (file)
@@ -73,9 +73,9 @@ Ext.ux.form.ImageField = Ext.extend(Ext.form.Field, {
             });
         }
         
-        this.loadMask = new Ext.LoadMask(this.buttonCt, {msg: _('Loading'), msgCls: 'x-mask-loading'});
+        this.loadMask = new Ext.LoadMask(this.buttonCt, {msg: i18n._('Loading'), msgCls: 'x-mask-loading'});
         this.textCt.setSize(this.width, this.height);
-        var clickToEditText = _('Click to edit');
+        var clickToEditText = i18n._('Click to edit');
         var tm = Ext.util.TextMetrics.createInstance(this.textCt);
         tm.setFixedWidth(this.width);
         this.textCt.applyStyles({
@@ -143,7 +143,7 @@ Ext.ux.form.ImageField = Ext.extend(Ext.form.Field, {
             this.loadMask.hide();
         }, this);
         img.on('error', function () {
-            Ext.MessageBox.alert(_('Image Failed'), _('Could not load image. Please notify your Administrator')).setIcon(Ext.MessageBox.ERROR);
+            Ext.MessageBox.alert(i18n._('Image Failed'), i18n._('Could not load image. Please notify your Administrator')).setIcon(Ext.MessageBox.ERROR);
             this.loadMask.hide();
         }, this);
     },
@@ -165,7 +165,7 @@ Ext.ux.form.ImageField = Ext.extend(Ext.form.Field, {
      */
     onFileSelect: function (fileSelector) {
         if (! fileSelector.isImage()) {
-            Ext.MessageBox.alert(_('Not An Image'), _('Please select an image file (gif/png/jpeg)')).setIcon(Ext.MessageBox.ERROR);
+            Ext.MessageBox.alert(i18n._('Not An Image'), i18n._('Please select an image file (gif/png/jpeg)')).setIcon(Ext.MessageBox.ERROR);
             return;
         }
         
@@ -208,7 +208,7 @@ Ext.ux.form.ImageField = Ext.extend(Ext.form.Field, {
         this.uploader.un('uploadcomplete', this.onUploadComplete, this);
         this.uploader.un('uploadfailure', this.onUploadFail, this);
         
-        Ext.MessageBox.alert(_('Upload Failed'), _('Could not upload image. Please notify your Administrator')).setIcon(Ext.MessageBox.ERROR);
+        Ext.MessageBox.alert(i18n._('Upload Failed'), i18n._('Could not upload image. Please notify your Administrator')).setIcon(Ext.MessageBox.ERROR);
     },
     /**
      * executed on image contextmenu
@@ -221,7 +221,7 @@ Ext.ux.form.ImageField = Ext.extend(Ext.form.Field, {
         }
         this.browsePlugin.hideLayer();
         var upload = new Ext.menu.Item({
-            text: _('Change Image'),
+            text: i18n._('Change Image'),
             iconCls: 'action_uploadImage',
             handler: this.onFileSelect,
             scope: this,
@@ -229,7 +229,7 @@ Ext.ux.form.ImageField = Ext.extend(Ext.form.Field, {
         });
         this.ctxMenu = new Ext.menu.Menu({
             items: [upload, {
-                text: _('Crop Image'),
+                text: i18n._('Crop Image'),
                 iconCls: 'action_cropImage',
                 scope: this,
                 disabled: true, 
@@ -247,13 +247,13 @@ Ext.ux.form.ImageField = Ext.extend(Ext.form.Field, {
                     var win = Tine.WindowFactory.getWindow({
                         width: 320,
                         height: 320,
-                        title: _('Crop Image'),
+                        title: i18n._('Crop Image'),
                         layout: 'fit',
                         items: dlg
                     });
                 }
             }, {
-                text: _('Delete Image'),
+                text: i18n._('Delete Image'),
                 iconCls: 'action_delete',
                 disabled: this.value === this.defaultImage,
                 scope: this,
@@ -262,7 +262,7 @@ Ext.ux.form.ImageField = Ext.extend(Ext.form.Field, {
                 }
                 
             }, {
-                text: _('Show Original Image'),
+                text: i18n._('Show Original Image'),
                 iconCls: 'action_originalImage',
                 disabled: this.value === this.defaultImage,
                 scope: this,
index b718a33..0c22bba 100644 (file)
@@ -187,14 +187,14 @@ Ext.extend(Ext.ux.form.LayerCombo, Ext.form.TriggerField, {
     getButtons: function () {
         if (! this.hideButtons) {
             this.action_ok = new Ext.Action({
-                text: _('Ok'),
+                text: i18n._('Ok'),
                 scope: this,
                 handler: this.onOk,
                 iconCls: 'action_saveAndClose'
             });
             
             this.action_cancel = new Ext.Action({
-                text: _('Cancel'),
+                text: i18n._('Cancel'),
                 scope: this,
                 handler: this.onCancel,
                 iconCls: 'action_cancel'
index d841f4c..4397b35 100644 (file)
@@ -92,7 +92,7 @@ summaryRenderer: function(v, params, data){
             if(cf.summaryType || cf.summaryRenderer){
                 p.value = (cf.summaryRenderer || c.renderer)(o.data[c.name], p, o);
             }else{
-                p.value = i == 0 ? '<div style="position:relative" ext:model="' + o.data.model + '" ext:qtip="' + _('Export Records from these Positions') + '" class="x-menu-item-icon action_export">&nbsp;</div>' : '';
+                p.value = i == 0 ? '<div style="position:relative" ext:model="' + o.data.model + '" ext:qtip="' + i18n._('Export Records from these Positions') + '" class="x-menu-item-icon action_export">&nbsp;</div>' : '';
             }
             if(p.value == undefined || p.value === "") p.value = "&#160;";
             buf[buf.length] = this.cellTpl.apply(p);
index 36e54b7..e9c80c9 100644 (file)
@@ -54,10 +54,10 @@ Ext.ux.grid.PagingToolbar = Ext.extend(Ext.PagingToolbar, {
     initComponent: function() {
         // initialise i18n
         this.selHelperText = {
-            'main'         : _('{0} selected'),
-            'deselect'     : _('Unselect all'),
-            'selectall'    : _('Select all pages ({0} records)'),
-            'toggle'       : _('Toggle selection')
+            'main'         : i18n._('{0} selected'),
+            'deselect'     : i18n._('Unselect all'),
+            'selectall'    : i18n._('Select all pages ({0} records)'),
+            'toggle'       : i18n._('Toggle selection')
         };
 
         Ext.ux.grid.PagingToolbar.superclass.initComponent.call(this);
index 3ac4621..50ddb30 100644 (file)
@@ -55,7 +55,7 @@ Tine.widgets.activities.ActivitiesGridPanel = Ext.extend(Ext.grid.GridPanel, {
     initComponent: function () {
         this.record = this.editDialog.record;
         this.app = this.editDialog.app;
-        this.title = this.i18nTitle = _('Notes');
+        this.title = this.i18nTitle = i18n._('Notes');
 
         this.id = this.id + Ext.id();
 
@@ -94,7 +94,7 @@ Tine.widgets.activities.ActivitiesGridPanel = Ext.extend(Ext.grid.GridPanel, {
         var columns = [
             {
                 id: 'note_type_id',
-                header: _('Type'),
+                header: i18n._('Type'),
                 dataIndex: 'note_type_id',
                 renderer: Tine.widgets.activities.getTypeIcon,
                 width: 30
@@ -103,18 +103,18 @@ Tine.widgets.activities.ActivitiesGridPanel = Ext.extend(Ext.grid.GridPanel, {
                 id: 'note',
                 dataIndex: 'note',
                 width: 500,
-                header: _('Note'),
+                header: i18n._('Note'),
                 sortable: true,
                 renderer: this.renderMultipleLines
             },
             {
                 id: 'created_by',
-                header: _('Created By'),
+                header: i18n._('Created By'),
                 dataIndex: 'created_by'
             },
             {
                 id: 'creation_time',
-                header: _('Creation time'),
+                header: i18n._('Creation time'),
                 dataIndex: 'creation_time',
                 width: 120,
                 renderer: Tine.Tinebase.common.dateTimeRenderer
@@ -238,14 +238,14 @@ Tine.widgets.activities.ActivitiesGridPanel = Ext.extend(Ext.grid.GridPanel, {
      */
     initToolbarAndContextMenu: function () {
         this.action_add = new Ext.Action({
-            text: String.format(_('Add {0}'), this.i18nTitle),
+            text: String.format(i18n._('Add {0}'), this.i18nTitle),
             iconCls: 'action_add',
             scope: this,
             handler: this.addNote
         });
 
         this.action_edit = new Ext.Action({
-            text: String.format(_('Edit {0}'), this.i18nTitle),
+            text: String.format(i18n._('Edit {0}'), this.i18nTitle),
             iconCls: 'action_edit',
             scope: this,
             disabled: true,
@@ -254,7 +254,7 @@ Tine.widgets.activities.ActivitiesGridPanel = Ext.extend(Ext.grid.GridPanel, {
         });
 
         this.action_remove = new Ext.Action({
-            text: String.format(_('Remove {0}'), this.i18nTitle),
+            text: String.format(i18n._('Remove {0}'), this.i18nTitle),
             iconCls: 'action_remove',
             scope: this,
             disabled: true,
@@ -340,7 +340,7 @@ Tine.widgets.activities.ActivitiesGridPanel = Ext.extend(Ext.grid.GridPanel, {
                 {
                     xtype: 'textarea',
                     name: 'notification',
-                    fieldLabel: _('Enter new note:'),
+                    fieldLabel: i18n._('Enter new note:'),
                     labelSeparator: '',
                     allowBlank: false,
                     value: note || '',
@@ -366,7 +366,7 @@ Tine.widgets.activities.ActivitiesGridPanel = Ext.extend(Ext.grid.GridPanel, {
         };
 
         this.cancelAction = new Ext.Action({
-            text: _('Cancel'),
+            text: i18n._('Cancel'),
             iconCls: 'action_cancel',
             minWidth: 70,
             handler: this.onCancel,
@@ -374,7 +374,7 @@ Tine.widgets.activities.ActivitiesGridPanel = Ext.extend(Ext.grid.GridPanel, {
         });
 
         this.okAction = new Ext.Action({
-            text: _('Ok'),
+            text: i18n._('Ok'),
             iconCls: 'action_s