* Fixed JS error when opening the TYPO3 image browser and proc.plainImageMode is...
authorStanislas Rolland <typo3@sjbr.ca>
Mon, 21 Jan 2008 16:20:41 +0000 (16:20 +0000)
committerStanislas Rolland <typo3@sjbr.ca>
Mon, 21 Jan 2008 16:20:41 +0000 (16:20 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@2943 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
typo3/sysext/rtehtmlarea/ChangeLog
typo3/sysext/rtehtmlarea/mod4/class.tx_rtehtmlarea_dam_browse_media.php
typo3/sysext/rtehtmlarea/mod4/class.tx_rtehtmlarea_select_image.php

index 99ad67d..f61a176 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2008-01-21  Stanislas Rolland  <stanislas.rolland@fructifor.ca>
+
+       * Fixed JS error when opening the TYPO3 image browser and proc.plainImageMode is not set
+
 2008-01-21  Ingo Renner  <ingo@typo3.org>
 
        * fixed tab borders in TCEforms
index 9caef6e..c23f2b9 100644 (file)
@@ -1,3 +1,7 @@
+2008-01-21  Stanislas Rolland  <stanislas.rolland@fructifor.ca>
+
+       * Fixed JS error when opening the TYPO3 image browser and proc.plainImageMode is not set
+
 2008-01-19  Stanislas Rolland  <stanislas.rolland@fructifor.ca>
 
        * Added feature: Various enhancements to image dialog in htmlArea RTE
index 56eaece..e4741f3 100644 (file)
@@ -53,8 +53,8 @@ class tx_rtehtmlarea_dam_browse_media extends tx_dam_browse_media {
        var $defaultClass;
        var $plainMaxWidth;
        var $plainMaxHeight;
-       var $lockPlainWidth;
-       var $lockPlainHeight;
+       var $lockPlainWidth = 'false';
+       var $lockPlainHeight = 'false';
        var $magicMaxWidth;
        var $magicMaxHeight;
        var $imgPath;
@@ -433,7 +433,7 @@ class tx_rtehtmlarea_dam_browse_media extends tx_dam_browse_media {
                                .(in_array('alt', $this->removedProperties)?'':'
                                sz+=\'<tr><td\'+bgColor+\'><label for="iAlt">'.$LANG->getLL('alt').': </label></td><td><input type="text" id="iAlt" name="iAlt"'.$GLOBALS['TBE_TEMPLATE']->formWidth(20).' /></td></tr>\';')
                                .((!$TYPO3_CONF_VARS['EXTCONF'][$this->extKey]['enableClickEnlarge'] || in_array('clickenlarge', $this->removedProperties))?'':'
-                               sz+=\'<tr><td\'+bgColor+\'><label for="iClickEnlarge">'.$LANG->sL('LLL:EXT:cms/locallang_ttc.php:image_zoom',1).' </label></td><td><input type="checkbox" name="iClickEnlarge" id="iClickEnlarge" value="1" /></td></tr>\';').'
+                               sz+=\'<tr><td\'+bgColor+\'><label for="iClickEnlarge">'.$LANG->sL('LLL:EXT:cms/locallang_ttc.php:image_zoom',1).' </label></td><td><input type="checkbox" name="iClickEnlarge" id="iClickEnlarge" value="0" /></td></tr>\';').'
                                sz+=\'<tr><td><input type="submit" value="'.$LANG->getLL('update').'" onClick="return setImageProperties();"></td></tr>\';
                                sz+=\'</form></table>\';
                                return sz;
@@ -535,7 +535,7 @@ class tx_rtehtmlarea_dam_browse_media extends tx_dam_browse_media {
                                                if (document.imageData.iClickEnlarge.checked) {
                                                        selectedImageRef.setAttribute("clickenlarge","1");
                                                } else {
-                                                       selectedImageRef.setAttribute("clickenlarge","0");
+                                                       selectedImageRef.removeAttribute("clickenlarge");
                                                }
                                        }
                                        dialog.close();
index 6792391..2401bf7 100644 (file)
@@ -140,8 +140,8 @@ class tx_rtehtmlarea_select_image extends browse_links {
        var $defaultClass;
        var $plainMaxWidth;
        var $plainMaxHeight;
-       var $lockPlainWidth;
-       var $lockPlainHeight;
+       var $lockPlainWidth = 'false';
+       var $lockPlainHeight = 'false';
        var $magicMaxWidth;
        var $magicMaxHeight;
        var $imgPath;
@@ -421,7 +421,7 @@ class tx_rtehtmlarea_select_image extends browse_links {
                                .(in_array('alt', $this->removedProperties)?'':'
                                sz+=\'<tr><td\'+bgColor+\'><label for="iAlt">'.$LANG->getLL('alt').': </label></td><td><input type="text" id="iAlt" name="iAlt"'.$GLOBALS['TBE_TEMPLATE']->formWidth(20).' /></td></tr>\';')
                                .((!$TYPO3_CONF_VARS['EXTCONF'][$this->extKey]['enableClickEnlarge'] || in_array('clickenlarge', $this->removedProperties))?'':'
-                               sz+=\'<tr><td\'+bgColor+\'><label for="iClickEnlarge">'.$LANG->sL('LLL:EXT:cms/locallang_ttc.php:image_zoom',1).' </label></td><td><input type="checkbox" name="iClickEnlarge" id="iClickEnlarge" value="1" /></td></tr>\';').'
+                               sz+=\'<tr><td\'+bgColor+\'><label for="iClickEnlarge">'.$LANG->sL('LLL:EXT:cms/locallang_ttc.php:image_zoom',1).' </label></td><td><input type="checkbox" name="iClickEnlarge" id="iClickEnlarge" value="0" /></td></tr>\';').'
                                sz+=\'<tr><td><input type="submit" value="'.$LANG->getLL('update').'" onClick="return setImageProperties();"></td></tr>\';
                                sz+=\'</form></table>\';
                                return sz;
@@ -523,7 +523,7 @@ class tx_rtehtmlarea_select_image extends browse_links {
                                                if (document.imageData.iClickEnlarge.checked) {
                                                        selectedImageRef.setAttribute("clickenlarge","1");
                                                } else {
-                                                       selectedImageRef.setAttribute("clickenlarge","0");
+                                                       selectedImageRef.removeAttribute("clickenlarge");
                                                }
                                        }
                                        dialog.close();