Index: typo3/sysext/rtehtmlarea/htmlarea/plugins/TableOperations/table-operations.js
===================================================================
--- typo3/sysext/rtehtmlarea/htmlarea/plugins/TableOperations/table-operations.js (révision 10133)
+++ typo3/sysext/rtehtmlarea/htmlarea/plugins/TableOperations/table-operations.js (copie de travail)
@@ -675,8 +675,18 @@
* This function gets called when the toolbar is being updated
*/
onUpdateToolbar: function (button, mode, selectionEmpty, ancestors) {
- if (mode === 'wysiwyg' && this.editor.isEditable() && button.itemId === 'TO-toggle-borders') {
- button.setInactive(!HTMLArea._hasClass(this.editor._doc.body, 'htmlarea-showtableborders'));
+ if (mode === 'wysiwyg' && this.editor.isEditable()) {
+ switch (button.itemId) {
+ case 'TO-toggle-borders':
+ button.setInactive(!HTMLArea._hasClass(this.editor._doc.body, 'htmlarea-showtableborders'));
+ break;
+ case 'TO-cell-merge':
+ if (Ext.isGecko) {
+ var selection = this.editor._getSelection();
+ button.setDisabled(button.disabled || selection.rangeCount < 2);
+ }
+ break;
+ }
}
},
/*