Reverted bug #11087 from rev 5442: Selecting more than one item in a selector box...
authorOliver Hader <oliver.hader@typo3.org>
Fri, 22 May 2009 18:59:18 +0000 (18:59 +0000)
committerOliver Hader <oliver.hader@typo3.org>
Fri, 22 May 2009 18:59:18 +0000 (18:59 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/branches/TYPO3_4-2@5480 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
t3lib/class.t3lib_tceforms.php
typo3/jsfunc.tbe_editor.js

index 46b4e92..4cf7382 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2009-05-22  Oliver Hader  <oliver@typo3.org>
+
+       * Reverted bug #11087 from rev 5442: Selecting more than one item in a selector box is not possible anymore
+
 2009-05-20  Steffen Kamper  <info@sk-typo3.de>
 
        * Fixed bug #10861: Eval of double2 doesn't work
index 1015b0e..d1593ca 100755 (executable)
@@ -5240,17 +5240,7 @@ class t3lib_TCEforms     {
                                                        }
                                                }
                                        }
-
                                        if (setOK)      {
-                                                       // remove the existing option element if there is only one element allowed
-                                               var el = TBE_EDITOR.getElementFromFieldName(fName);
-                                               var range = String(el.range);
-                                               range = range.split(",");
-                                               if (range[1] == "1") {
-                                                       setFormValueManipulate(fName, "Remove");
-                                                       len = 0;
-                                               }
-                                               
                                                fObj.length++;
                                                fObj.options[len].value = value;
                                                fObj.options[len].text = unescape(label);
index bf7769c..03d3234 100755 (executable)
@@ -324,21 +324,16 @@ var TBE_EDITOR = {
                document[TBE_EDITOR.formname][theField].value = RTEcontent;
                alert(document[TBE_EDITOR.formname][theField].value);
        },
-       // strips the "table", the "field" and the "uid" from the fName
-       extractDataFromFieldName: function(fName) {
-               var idx   = 2 + TBE_EDITOR.prependFormFieldNamesCnt;
-               var table = TBE_EDITOR.split(fName, '[', idx);
-               var uid   = TBE_EDITOR.split(fName, '[', idx + 1);
-               var field = TBE_EDITOR.split(fName, '[', idx + 2);
-               return { table: table.substr(0, table.length-1), uid: uid.substr(0, uid.length-1), field: field.substr(0,field.length-1) };
-       },
-       getElementFromFieldName: function(fName) {
-               var data = TBE_EDITOR.extractDataFromFieldName(fName);
-               return TBE_EDITOR.getElement('data[' + data.table + '][' + data.uid + ']', data.field);
-       },
        fieldChanged_fName: function(fName,el) {
-               var data = TBE_EDITOR.extractDataFromFieldName(fName);
-               TBE_EDITOR.fieldChanged(data.table, data.uid, data.field, el);
+               var idx=2+TBE_EDITOR.prependFormFieldNamesCnt;
+               var table = TBE_EDITOR.split(fName, "[", idx);
+               var uid = TBE_EDITOR.split(fName, "[", idx+1);
+               var field = TBE_EDITOR.split(fName, "[", idx+2);
+
+               table = table.substr(0,table.length-1);
+               uid = uid.substr(0,uid.length-1);
+               field = field.substr(0,field.length-1);
+               TBE_EDITOR.fieldChanged(table,uid,field,el);
        },
        fieldChanged: function(table,uid,field,el) {
                var theField = TBE_EDITOR.prependFormFieldNames+'['+table+']['+uid+']['+field+']';