Skip to content

Commit

Permalink
Merge branch hotfix/v8.2.2 into master
Browse files Browse the repository at this point in the history
  • Loading branch information
papacarlo committed Nov 28, 2024
2 parents e6e56e8 + be49e66 commit f31ba63
Show file tree
Hide file tree
Showing 52 changed files with 162 additions and 184 deletions.
13 changes: 0 additions & 13 deletions apps/api/documents/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -400,19 +400,6 @@
};

var _onAppReady = function() {
if (_config.type === 'mobile') {
document.body.onfocus = function(e) {
setTimeout(function(){
iframe.contentWindow.focus();

_sendCommand({
command: 'resetFocus',
data: {}
})
}, 10);
};
}

_attachMouseEvents();

if (_config.editorConfig) {
Expand Down
5 changes: 5 additions & 0 deletions apps/common/forms/resources/less/common.less
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,11 @@
@import "../../../../common/main/resources/mods/less/utilities.less";
@import "../../../../common/main/resources/mods/less/responsive-utilities.less";

//
// Perfect scrollbar
// --------------------------------------------------
@import (inline) "../../../../../vendor/perfect-scrollbar/src/perfect-scrollbar.css";

@import "../../../../common/main/resources/less/buttons.less";
@import "../../../../common/main/resources/less/dropdown-menu.less";
@import "../../../../common/main/resources/less/dropdown-submenu.less";
Expand Down
5 changes: 5 additions & 0 deletions apps/common/main/lib/controller/Desktop.js
Original file line number Diff line number Diff line change
Expand Up @@ -663,6 +663,11 @@ define([
native.execCommand('editor:event', JSON.stringify({action:'file:close', url: config.customization.goback.url}));
}
},
removeRecent: function () {
if ( config.isDesktopApp && !!native ) {
native.execCommand('recent:forget');
}
},
isActive: function () {
return !!native;
},
Expand Down
17 changes: 13 additions & 4 deletions apps/common/main/lib/controller/Plugins.js
Original file line number Diff line number Diff line change
Expand Up @@ -111,6 +111,7 @@ define([

this._moveOffset = {x:0, y:0};
this.autostart = [];
this.startOnPostLoad = false;
this.customPluginsDlg = [];
this.macrosPlugin = {el: null, show: false};

Expand All @@ -124,6 +125,7 @@ define([
Common.NotificationCenter.on('app:ready', this.onAppReady.bind(this));
Common.NotificationCenter.on('doc:mode-changed', this.onChangeDocMode.bind(this));
Common.NotificationCenter.on('modal:close', this.onModalClose.bind(this));
Common.NotificationCenter.on('script:loaded', this.onPostLoadComplete.bind(this));
},

loadConfig: function(data) {
Expand All @@ -135,7 +137,7 @@ define([

loadPlugins: function() {
this.configPlugins.plugins =
this.serverPlugins.plugins = false;
this.serverPlugins.plugins = undefined;

if (this.configPlugins.config) {
this.getPlugins(this.configPlugins.config.pluginsData)
Expand All @@ -149,7 +151,8 @@ define([

if (this.configPlugins.config.options)
this.api.setPluginsOptions(this.configPlugins.config.options);
}
} else
this.configPlugins.plugins = false;

if ( !Common.Controllers.Desktop.isActive() || !Common.Controllers.Desktop.isOffline() ) {
var server_plugins_url = '../../../../plugins.json',
Expand All @@ -165,7 +168,8 @@ define([
.catch(function (err) {
me.serverPlugins.plugins = false;
});
}
} else
me.serverPlugins.plugins = false;
});
}
},
Expand Down Expand Up @@ -1007,7 +1011,8 @@ define([

if (this.appOptions.canPlugins) {
this.refreshPluginsList();
this.runAutoStartPlugins();
this.startOnPostLoad = !Common.Controllers.LaunchController.isScriptLoaded();
!this.startOnPostLoad && this.runAutoStartPlugins();
}
},

Expand Down Expand Up @@ -1378,6 +1383,10 @@ define([
}
},

onPostLoadComplete: function() {
this.startOnPostLoad && this.runAutoStartPlugins();
},

textRunPlugin: 'Run plugin',
textRunInstalledPlugins: 'Run installed plugins',
textPluginSuccessfullyInstalled: '<b>{0}</b> is successfully installed. You can access all background plugins here.',
Expand Down
92 changes: 3 additions & 89 deletions apps/documenteditor/forms/app/controller/ApplicationController.js
Original file line number Diff line number Diff line change
Expand Up @@ -694,6 +694,9 @@ define([
return;
}
me.api.asc_SendForm();
Common.Controllers.Desktop.removeRecent();
Common.Controllers.Desktop.process('goback');
Common.Controllers.Desktop.requestClose();
});
me.view.btnDownload.on('click', function(){
if (me.appOptions.canDownload) {
Expand Down Expand Up @@ -2126,93 +2129,4 @@ define([
savingText: 'Saving'

}, DE.Controllers.ApplicationController));

/* var Desktop = function () {
var features = {
version: '{{PRODUCT_VERSION}}',
// eventloading: true,
uitype: 'fillform',
uithemes: true
};
var api, nativevars;
var native = window.desktop || window.AscDesktopEditor;
!!native && native.execCommand('webapps:features', JSON.stringify(features));
if ( !!native ) {
$('#header-logo, .brand-logo').hide();
nativevars = window.RendererProcessVariable;
window.on_native_message = function (cmd, param) {
if (/theme:changed/.test(cmd)) {
if ( Common.UI.Themes && !!Common.UI.Themes.setTheme )
Common.UI.Themes.setTheme(param);
} else
if (/window:features/.test(cmd)) {
var obj = JSON.parse(param);
if ( obj.singlewindow !== undefined ) {
native.features.singlewindow = obj.singlewindow;
$("#title-doc-name")[obj.singlewindow ? 'hide' : 'show']();
}
}
};
if ( !!window.native_message_cmd ) {
for ( var c in window.native_message_cmd ) {
window.on_native_message(c, window.native_message_cmd[c]);
}
}
Common.NotificationCenter.on({
'uitheme:changed' : function (name) {
if (Common.localStorage.getBool('ui-theme-use-system', false)) {
native.execCommand("uitheme:changed", JSON.stringify({name:'theme-system'}));
} else {
const theme = Common.UI.Themes.get(name);
if ( theme )
native.execCommand("uitheme:changed", JSON.stringify({name:name, type:theme.type}));
}
},
});
Common.Gateway.on('opendocument', function () {
api = DE.getController('ApplicationController').api;
$("#title-doc-name")[native.features.singlewindow ? 'hide' : 'show']();
var is_win_xp = window.RendererProcessVariable && window.RendererProcessVariable.os === 'winxp';
Common.UI.Themes.setAvailable(!is_win_xp);
});
}
return {
isActive: function () {
return !!native;
},
isOffline: function () {
return api && api.asc_isOffline();
},
process: function (opts) {
if ( !!native && !!api ) {
if ( opts == 'goback' ) {
var config = DE.getController('ApplicationController').editorConfig;
native.execCommand('go:folder',
api.asc_isOffline() ? 'offline' : config.customization.goback.url);
return true;
}
}
return false;
},
systemThemeType: function () {
return nativevars.theme && !!nativevars.theme.system ? nativevars.theme.system :
window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light';
},
}
};
*/
// DE.Controllers.Desktop = new Desktop();
// Common.Controllers = Common.Controllers || {};
// Common.Controllers.Desktop = DE.Controllers.Desktop;
});
3 changes: 2 additions & 1 deletion apps/documenteditor/mobile/locale/ar.json
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,7 @@
"textOk": "موافق",
"textRenameFile": "إعادة تسمية الملف",
"textSwitchedMobileView": "تم التبديل إلى عرض المحمول",
"textSwitchedStandardView": "تم التبديل إلى العرض القياسي"
"textSwitchedStandardView": "تم التبديل إلى العرض القياسي",
"warnEmptyRequiredField": "قم بملء كل الحقول المطلوبة لارسال الاستمارة."
}
}
1 change: 1 addition & 0 deletions apps/documenteditor/mobile/locale/az.json
Original file line number Diff line number Diff line change
Expand Up @@ -809,6 +809,7 @@
"stayButtonText": "Bu səhifədə qalın",
"textCloseHistory": "Tarixçəni bağlayın",
"textOk": "OK",
"warnEmptyRequiredField": "Tələb olunan bütün sahələri doldurub formanı göndərin.",
"btnSend": "Send",
"textEnterNewFileName": "Enter a new file name",
"textRenameFile": "Rename File",
Expand Down
1 change: 1 addition & 0 deletions apps/documenteditor/mobile/locale/be.json
Original file line number Diff line number Diff line change
Expand Up @@ -808,6 +808,7 @@
"stayButtonText": "Застацца на старонцы",
"textCloseHistory": "Закрыць гісторыю",
"textOk": "Добра",
"warnEmptyRequiredField": "Запоўніце ўсе абавязковыя палі, патрэбныя для адпраўлення формы. ",
"btnSend": "Send",
"dlgLeaveMsgText": "You have unsaved changes. Click 'Stay on this Page' to wait for autosave. Click 'Leave this Page' to discard all the unsaved changes.",
"textEnterNewFileName": "Enter a new file name",
Expand Down
3 changes: 2 additions & 1 deletion apps/documenteditor/mobile/locale/bg.json
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,7 @@
"textOk": "OK",
"textRenameFile": "Rename File",
"textSwitchedMobileView": "Switched to Mobile view",
"textSwitchedStandardView": "Switched to Standard view"
"textSwitchedStandardView": "Switched to Standard view",
"warnEmptyRequiredField": "Fill all required fields to send form."
}
}
1 change: 1 addition & 0 deletions apps/documenteditor/mobile/locale/ca.json
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,7 @@
"textRenameFile": "Canvia el nom del fitxer",
"textSwitchedMobileView": "S'ha canviat a visualització mòbil",
"textSwitchedStandardView": "S'ha canviat a visualització estàndard",
"warnEmptyRequiredField": "Emplena tots els camps necessaris per enviar el formulari.",
"btnSend": "Send"
}
}
1 change: 1 addition & 0 deletions apps/documenteditor/mobile/locale/cs.json
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,7 @@
"textRenameFile": "Přejmenovat soubor",
"textSwitchedMobileView": "Přepnout na mobilní zobrazení",
"textSwitchedStandardView": "Přepnout na standartní zobrazení",
"warnEmptyRequiredField": "Pro odeslání formuláře vyplňte všechna požadovaná pole.",
"btnSend": "Send"
}
}
27 changes: 14 additions & 13 deletions apps/documenteditor/mobile/locale/da.json
Original file line number Diff line number Diff line change
Expand Up @@ -659,6 +659,20 @@
"txtOk": "Ok",
"txtProtected": "Once you enter the password and open the file, the current password will be reset"
},
"Toolbar": {
"warnEmptyRequiredField": "Udfyld alle obligatoriske felter for at sende formularen.",
"btnSend": "Send",
"dlgLeaveMsgText": "You have unsaved changes. Click 'Stay on this Page' to wait for autosave. Click 'Leave this Page' to discard all the unsaved changes.",
"dlgLeaveTitleText": "You leave the application",
"leaveButtonText": "Leave this Page",
"stayButtonText": "Stay on this page",
"textCloseHistory": "Close History",
"textEnterNewFileName": "Enter a new file name",
"textOk": "OK",
"textRenameFile": "Rename File",
"textSwitchedMobileView": "Switched to Mobile view",
"textSwitchedStandardView": "Switched to Standard view"
},
"About": {
"textAbout": "About",
"textAddress": "Address",
Expand Down Expand Up @@ -801,18 +815,5 @@
"uploadImageTextText": "Uploading image...",
"uploadImageTitleText": "Uploading Image",
"waitText": "Please, wait..."
},
"Toolbar": {
"btnSend": "Send",
"dlgLeaveMsgText": "You have unsaved changes. Click 'Stay on this Page' to wait for autosave. Click 'Leave this Page' to discard all the unsaved changes.",
"dlgLeaveTitleText": "You leave the application",
"leaveButtonText": "Leave this Page",
"stayButtonText": "Stay on this page",
"textCloseHistory": "Close History",
"textEnterNewFileName": "Enter a new file name",
"textOk": "OK",
"textRenameFile": "Rename File",
"textSwitchedMobileView": "Switched to Mobile view",
"textSwitchedStandardView": "Switched to Standard view"
}
}
3 changes: 2 additions & 1 deletion apps/documenteditor/mobile/locale/de.json
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,7 @@
"textOk": "OK",
"textRenameFile": "Datei umbenennen",
"textSwitchedMobileView": "Mobile Ansicht aktiviert",
"textSwitchedStandardView": "Standard-Ansicht aktiviert"
"textSwitchedStandardView": "Standard-Ansicht aktiviert",
"warnEmptyRequiredField": "Füllen Sie alle erforderlichen Felder aus, um das Formular zu senden."
}
}
3 changes: 2 additions & 1 deletion apps/documenteditor/mobile/locale/el.json
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,7 @@
"textOk": "Εντάξει",
"textRenameFile": "Μετονομασία αρχείου",
"textSwitchedMobileView": "Μετάβαση σε προβολή κινητού",
"textSwitchedStandardView": "Εναλλαγή σε τυπική προβολή"
"textSwitchedStandardView": "Εναλλαγή σε τυπική προβολή",
"warnEmptyRequiredField": "Συμπληρώστε όλα τα απαιτούμενα πεδία για την αποστολή της φόρμας."
}
}
3 changes: 2 additions & 1 deletion apps/documenteditor/mobile/locale/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,7 @@
"textOk": "OK",
"textRenameFile": "Rename File",
"textSwitchedMobileView": "Switched to Mobile view",
"textSwitchedStandardView": "Switched to Standard view"
"textSwitchedStandardView": "Switched to Standard view",
"warnEmptyRequiredField": "Fill all required fields to send form."
}
}
3 changes: 2 additions & 1 deletion apps/documenteditor/mobile/locale/es.json
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,7 @@
"textOk": "Aceptar",
"textRenameFile": "Renombrar archivo",
"textSwitchedMobileView": "Cambiado a vista móvil",
"textSwitchedStandardView": "Cambiado a vista estándar"
"textSwitchedStandardView": "Cambiado a vista estándar",
"warnEmptyRequiredField": "Rellene todos los campos obligatorios para enviar el formulario."
}
}
1 change: 1 addition & 0 deletions apps/documenteditor/mobile/locale/eu.json
Original file line number Diff line number Diff line change
Expand Up @@ -813,6 +813,7 @@
"textRenameFile": "Berrizendatu fitxategia",
"textSwitchedMobileView": "Mugikorreko ikuspegira aldatu da",
"textSwitchedStandardView": "Ikuspegi estandarrera aldatu da",
"warnEmptyRequiredField": "Bete derrigorrezko eremu guztiak formularioa bidaltzeko.",
"btnSend": "Send"
}
}
Loading

0 comments on commit f31ba63

Please sign in to comment.