[DE PE SSE mobile] Fix Bug 54632
This commit is contained in:
parent
a44492926c
commit
d036f96171
|
@ -390,6 +390,9 @@
|
|||
"errorUpdateVersion": "The file version has been changed. The page will be reloaded.",
|
||||
"leavePageText": "You have unsaved changes. Click 'Stay on this Page' to wait for autosave. Click 'Leave this Page' to discard all the unsaved changes.",
|
||||
"notcriticalErrorTitle": "Warning",
|
||||
"textReplaceSuccess": "The search has been done. Occurrences replaced: {0}",
|
||||
"textReplaceSkipped": "The replacement has been made. {0} occurrences were skipped.",
|
||||
"textNoTextFound": "Text not found",
|
||||
"SDK": {
|
||||
" -Section ": " -Section ",
|
||||
"above": "above",
|
||||
|
|
|
@ -681,6 +681,18 @@ class MainController extends Component {
|
|||
if (this.props.users.isDisconnected) return;
|
||||
storeToolbarSettings.setCanRedo(can);
|
||||
});
|
||||
|
||||
this.api.asc_registerCallback('asc_onReplaceAll', this.onApiTextReplaced.bind(this));
|
||||
}
|
||||
|
||||
onApiTextReplaced(found, replaced) {
|
||||
const { t } = this.props;
|
||||
|
||||
if (found) {
|
||||
f7.dialog.alert(null, !(found - replaced > 0) ? Common.Utils.String.format(t('Main.textReplaceSuccess'), replaced) : Common.Utils.String.format(t('Main.textReplaceSkipped'), found - replaced));
|
||||
} else {
|
||||
f7.dialog.alert(null, t('Main.textNoTextFound'));
|
||||
}
|
||||
}
|
||||
|
||||
onShowListActions(obj, x, y) {
|
||||
|
|
|
@ -70,6 +70,9 @@
|
|||
"errorUpdateVersion": "The file version has been changed. The page will be reloaded.",
|
||||
"leavePageText": "You have unsaved changes in this document. Click 'Stay on this Page' to wait for autosave. Click 'Leave this Page' to discard all the unsaved changes.",
|
||||
"notcriticalErrorTitle": "Warning",
|
||||
"textReplaceSuccess": "The search has been done. Occurrences replaced: {0}",
|
||||
"textReplaceSkipped": "The replacement has been made. {0} occurrences were skipped.",
|
||||
"textNoTextFound": "Text not found",
|
||||
"SDK": {
|
||||
"Chart": "Chart",
|
||||
"Click to add first slide": "Click to add first slide",
|
||||
|
|
|
@ -414,6 +414,18 @@ class MainController extends Component {
|
|||
this.api.asc_registerCallback('asc_onCountPages', (count) => {
|
||||
storeToolbarSettings.setCountPages(count);
|
||||
});
|
||||
|
||||
this.api.asc_registerCallback('asc_onReplaceAll', this.onApiTextReplaced.bind(this));
|
||||
}
|
||||
|
||||
onApiTextReplaced(found, replaced) {
|
||||
const { t } = this.props;
|
||||
|
||||
if (found) {
|
||||
f7.dialog.alert(null, !(found - replaced > 0) ? Common.Utils.String.format(t('Controller.Main.textReplaceSuccess'), replaced) : Common.Utils.String.format(t('Controller.Main.textReplaceSkipped'), found - replaced));
|
||||
} else {
|
||||
f7.dialog.alert(null, t('Controller.Main.textNoTextFound'));
|
||||
}
|
||||
}
|
||||
|
||||
onDocumentContentReady () {
|
||||
|
|
|
@ -73,6 +73,9 @@
|
|||
"errorUpdateVersion": "The file version has been changed. The page will be reloaded.",
|
||||
"leavePageText": "You have unsaved changes in this document. Click 'Stay on this Page' to wait for autosave. Click 'Leave this Page' to discard all the unsaved changes.",
|
||||
"notcriticalErrorTitle": "Warning",
|
||||
"textReplaceSuccess": "The search has been done. Occurrences replaced: {0}",
|
||||
"textReplaceSkipped": "The replacement has been made. {0} occurrences were skipped.",
|
||||
"textNoTextFound": "Text not found",
|
||||
"SDK": {
|
||||
"txtAccent": "Accent",
|
||||
"txtAll": "(All)",
|
||||
|
|
|
@ -413,6 +413,15 @@ class MainController extends Component {
|
|||
|
||||
this.api.asc_registerCallback('asc_onChangeProtectWorksheet', this.onChangeProtectSheet.bind(this));
|
||||
this.api.asc_registerCallback('asc_onActiveSheetChanged', this.onChangeProtectSheet.bind(this));
|
||||
this.api.asc_registerCallback('asc_onRenameCellTextEnd', this.onRenameText.bind(this));
|
||||
}
|
||||
|
||||
onRenameText(found, replaced) {
|
||||
const { t } = this.props;
|
||||
|
||||
if (this.api.isReplaceAll) {
|
||||
f7.dialog.alert(null, (found) ? ((!found - replaced) ? Common.Utils.String.format(t('Controller.Main.textReplaceSuccess'), replaced) : Common.Utils.String.format(t('Controller.Main.textReplaceSkipped'), found - replaced)) : t('Controller.Main.textNoTextFound'));
|
||||
}
|
||||
}
|
||||
|
||||
onChangeProtectSheet() {
|
||||
|
|
Loading…
Reference in a new issue