jenkins-bot has submitted this change and it was merged.
Change subject: (Bug 46567) Saving again discards the correction
......................................................................
(Bug 46567) Saving again discards the correction
Disable the save button till previous save is done.
Change-Id: If3e85bb64109ed2c2f577f2cc67cd3e4e03e59b4
---
M resources/js/ext.translate.editor.js
1 file changed, 3 insertions(+), 2 deletions(-)
Approvals:
Amire80: Looks good to me, approved
jenkins-bot: Verified
diff --git a/resources/js/ext.translate.editor.js
b/resources/js/ext.translate.editor.js
index 3837b0a..ed130fe 100644
--- a/resources/js/ext.translate.editor.js
+++ b/resources/js/ext.translate.editor.js
@@ -390,8 +390,9 @@
}
$saveButton.text( mw.msg(
'tux-editor-save-button-label' ) );
- // When there is content in the editor
- if ( $.trim( $textArea.val() ) ) {
+ // When there is content in the editor enable
the button.
+ // But do not enable when some saving is not
finished yet.
+ if ( $.trim( $textArea.val() ) &&
!translateEditor.saving ) {
$pasteSourceButton.addClass( 'hide' );
$saveButton.prop( 'disabled', false );
} else {
--
To view, visit https://gerrit.wikimedia.org/r/56579
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: If3e85bb64109ed2c2f577f2cc67cd3e4e03e59b4
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/Translate
Gerrit-Branch: master
Gerrit-Owner: Santhosh <[email protected]>
Gerrit-Reviewer: Amire80 <[email protected]>
Gerrit-Reviewer: jenkins-bot
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits