[BUGFIX] RTE: Incorrect height of the RTE framework 54/35554/2
authorStanislas Rolland <typo3@sjbr.ca>
Wed, 17 Dec 2014 22:51:00 +0000 (17:51 -0500)
committerStanislas Rolland <typo3@sjbr.ca>
Wed, 17 Dec 2014 22:54:39 +0000 (23:54 +0100)
The calculated height of the toolbar is incorrect due to floating
elements.

Releases: master
Resolves: #63964
Change-Id: I771a0f3f31112777d6d2b8507c23d93f359c24b3
Reviewed-on: http://review.typo3.org/35554
Reviewed-by: Stanislas Rolland <typo3@sjbr.ca>
Tested-by: Stanislas Rolland <typo3@sjbr.ca>
typo3/sysext/rtehtmlarea/Resources/Public/JavaScript/HTMLArea/Editor/Framework.js
typo3/sysext/rtehtmlarea/Resources/Public/JavaScript/HTMLArea/Editor/Toolbar.js

index 50aa34c..2ff272a 100644 (file)
@@ -244,7 +244,7 @@ define('TYPO3/CMS/Rtehtmlarea/HTMLArea/Editor/Framework',
                 * Resize the framework to its initial size
                 */
                resizeFramework: function () {
-                       var frameworkHeight = this.fullScreen ? Typo3.getWindowSize().height - 20 : parseInt(this.textAreaInitialSize.height) + this.toolbar.getHeight() - this.statusBar.getHeight();
+                       var frameworkHeight = this.fullScreen ? Typo3.getWindowSize().height - 25 : parseInt(this.textAreaInitialSize.height) + this.toolbar.getHeight() - this.statusBar.getHeight();
                        if (this.textAreaInitialSize.width.indexOf('%') === -1) {
                                // Width is specified in pixels
                                // Initial framework sizing
index bf4d60f..5f843da 100644 (file)
@@ -174,14 +174,15 @@ define('TYPO3/CMS/Rtehtmlarea/HTMLArea/Editor/Toolbar',
                /**
                 * Add a spacer to the toolbar
                 *
-                * @param string cls: a class to be added on the spacer
+                * @param string cls: a class to be added on the spacer rather than 'space' (default)
                 * @return void
                 */
                addSpacer: function (cls) {
                        var spacer = document.createElement('div');
-                       Dom.addClass(spacer, 'space');
                        if (typeof cls === 'string') {
                                Dom.addClass(spacer, cls);
+                       } else {
+                               Dom.addClass(spacer, 'space');
                        }
                        this.el.appendChild(spacer);
                },