Changeset 7736 for extensions/Autosize/js/conflit.js
- Timestamp:
- Nov 10, 2010, 9:36:16 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/Autosize/js/conflit.js
r7726 r7736 21 21 if (retour.match(RegExp("jQuery", "gi"))) { 22 22 ret_element = jQuery(element); 23 } else if (retour.match(RegExp("GMaps", "gi"))) { 24 ret_element = jQuery(element); 23 25 } else if (retour.match(RegExp("pamooramics", "gi"))) { 24 26 ret_element = jQuery().$Pamoorama(element); … … 27 29 } else if (retour.match(RegExp("rv_gmaps", "gi"))) { 28 30 ret_element = jQuery().$Prototype(element); 29 }else if (retour.match(RegExp("GMaps", "gi"))) {30 ret_element = jQuery(element);31 31 }else if (retour.match(RegExp("jQuery", "gi"))) { 32 32 ret_element = jQuery(element); … … 36 36 return ret_element; 37 37 38 if (DEBUG== true)38 if (DEBUG=="true") 39 39 alert(retour); 40 40 return jQuery(element); … … 91 91 92 92 jQuery.fn.extend({ 93 //---------------- luciano ------------------------------- 94 $Luciano: function (el, nc) { 95 return document.id(el, nc, this.document); 96 }, 97 //=============== PaMOOramics =========================== 98 99 $Pamoorama: function (B) { 100 if (!B) { 101 if (typeof (B) == "boolean") return null; 102 return jQuery(); 103 } 104 if (B.htmlElement) { 105 return Garbage.collect(B); 106 107 } 108 if ([window, document].contains(B)) { return B; } 109 var A = $type(B); 110 if (A == "string") { B = document.getElementById(B); A = (B) ? "element" : false; } 111 if (A != "element") { 112 return null; 113 } 114 if (B.htmlElement) { return Garbage.collect(B); } 115 if (["object", "embed"].contains(B.tagName.toLowerCase())) { return B; } 116 $extend(B, Element.prototype); 117 B.htmlElement = function () { }; 118 try{ return Garbage.collect(B);}catch(e){ 119 return ; 120 } 121 122 }, 123 //=================================================== 124 $Prototype: function (element) { 125 //======== prototype.js ===================== 126 if (arguments.length > 1) { 127 for (var i = 0, elements = [], length = arguments.length; i < length; i++) 128 elements.push($(arguments[i])); 129 return elements; 130 } 131 if (typeof element == "string") 132 element = document.getElementById(element); 133 134 return Element.extend(element); 135 136 try { 137 new_element = Element.extend(element); 138 } catch (e) { 139 return new_element; 140 } 141 return new_element; 142 } 143 //========================================================= 144 }); // fin extend 93 //---------------- luciano ------------------------------- 94 $Luciano: function (el, nc) { 95 return document.id(el, nc, this.document); 96 }, 97 //=============== PaMOOramics =========================== 98 99 $Pamoorama: function (B) { 100 if (!B) { 101 if (typeof (B) == "boolean") return null; 102 103 } 104 105 try { 106 if (B.htmlElement) { 107 return Garbage.collect(B); 108 } 109 } catch (e) { 110 111 } 112 113 if ([window, document].contains(B)) { return B; } 114 var A = $type(B); 115 if (A == "string") { B = document.getElementById(B); A = (B) ? "element" : false; } 116 if (A != "element") { 117 return null; 118 } 119 if (B.htmlElement) { return Garbage.collect(B); } 120 if (["object", "embed"].contains(B.tagName.toLowerCase())) { return B; } 121 $extend(B, Element.prototype); 122 B.htmlElement = function () { }; 123 try { return Garbage.collect(B); } catch (e) { 124 return; 125 } 126 127 }, 128 //=================================================== 129 $Prototype: function (element) { 130 //======== prototype.js ===================== 131 if (arguments.length > 1) { 132 for (var i = 0, elements = [], length = arguments.length; i < length; i++) 133 elements.push($(arguments[i])); 134 return elements; 135 } 136 if (typeof element == "string") 137 element = document.getElementById(element); 138 139 return Element.extend(element); 140 141 try { 142 new_element = Element.extend(element); 143 } catch (e) { 144 return new_element; 145 } 146 return new_element; 147 } 148 //========================================================= 149 }); // fin extend 145 150 146 151 … … 177 182 callstack.push(Src_Match); 178 183 } 184 if (Src_Match.match("GMaps|applyMap|markupMaps|applyMarkers")) { 185 callstack.push("GMaps"); 186 isCallstackPopulated = true; 187 break; 188 } 179 189 if (Src_Match.match("rv_gmaps", "gi")) { 180 190 callstack.push("rv_gmaps"); … … 198 208 break; 199 209 } 200 if (Src_Match.match("GMaps|applyMap")) { 201 callstack.push("GMaps"); 202 isCallstackPopulated = true; 203 break; 204 } 210 205 211 if (Src_Match.match("jQuery")) { 206 212 callstack.push("jQuery"); … … 251 257 callstack.push(fn); 252 258 // if (fname != " $") callstack.push(fn); 253 if (fn.match(RegExp("jquery|switchmenu| gmaps|switchTabs|switchInterface|gally|initializeImageMode", "gi"))) {259 if (fn.match(RegExp("jquery|switchmenu|switchTabs|switchInterface|gally|initializeImageMode", "gi"))) { 254 260 callstack = []; 255 261 callstack.push('jQuery'); 256 262 break; 257 263 } 258 264 if (fn.match(RegExp("GMaps|applyMap|markupMaps|applyMarkers", "gi"))) { 265 callstack = []; 266 callstack.push('GMaps'); 267 break; 268 } 259 269 //====================== 260 270 if (fn.match(RegExp("_footer|ie_ready|makeDraggable", "gi"))) {
Note: See TracChangeset
for help on using the changeset viewer.