Prevent drag & drop of toolbar buttons in Firefox
authorAlexander Ebert <ebert@woltlab.com>
Tue, 26 Sep 2017 10:07:02 +0000 (12:07 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Tue, 26 Sep 2017 10:07:02 +0000 (12:07 +0200)
wcfsetup/install/files/js/3rdParty/redactor2/plugins/WoltLabButton.js

index ae4e9bf0e794f1a531fc898031df2950034c9276..a7d8a76f4fd6eb2a50c2bf36dcd257a36977c601 100644 (file)
@@ -152,6 +152,11 @@ $.Redactor.prototype.WoltLabButton = function() {
                                        setup: this.WoltLabButton._setupToggleButton.bind(this)
                                });
                        }).bind(this));
+                       
+                       // prevent drag & drop of toolbar buttons
+                       this.$toolbar[0].addEventListener('dragstart', function (event) {
+                               event.preventDefault();
+                       });
                },
                
                _handleCustomButton: function (bbcode) {