Changeset 12683 for extensions/Autosize/js/Affiche_script.js
- Timestamp:
- Dec 2, 2011, 1:51:19 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/Autosize/js/Affiche_script.js
r12660 r12683 498 498 499 499 Bandeau_bas = Info_Description_f(Parent); 500 if (typeof Bandeau_bas == "undefined") {501 502 }503 500 if (typeof Bandeau_bas != "undefined") Bandeau = Bandeau_bas.top; 504 501 else Bandeau = 0; … … 564 561 } 565 562 563 if (typeof Bandeau_bas == "undefined") 564 return; 566 565 567 566 if (typeof cl_visible == "undefined") return true; … … 940 939 //========================================================================= 941 940 if (typeof (Bandeau_bas) != "undefined") { 942 if (Bandeau_bas.height < Zone_Affichage.height) Zone_Affichage.height -= (Bandeau_bas.height + Bandeau_bas.marge.top + Bandeau_bas.marge.bottom); 941 if (Bandeau_bas.height < Zone_Affichage.height) 942 Zone_Affichage.height -= (Bandeau_bas.height + Bandeau_bas.marge.top + Bandeau_bas.marge.bottom); 943 943 } else { 944 944 } … … 1121 1121 //=== cadre = theImage 1122 1122 jQuery(Cadre).css({ marginLeft: "auto" }); 1123 if (theme.match(RegExp("sobre", "gi")) || theme.match(RegExp("hr_", "gi")) || theme.match(RegExp("Mont", "gi"))) { 1123 if (theme.match(RegExp("simple", "gi"))) { 1124 jQuery(Cadre).width(Zone_Affichage.width); //centrer simple black 1125 } else if (theme.match(RegExp("sobre", "gi")) || theme.match(RegExp("hr_", "gi")) || theme.match(RegExp("Mont", "gi"))) { 1124 1126 jQuery(Cadre).css("width", "auto"); 1125 1127 } else { 1126 jQuery(Cadre).width(Zone_Affichage.width); //centrer simple black1128 jQuery(Cadre).css("width", "auto"); 1127 1129 1128 1130 } … … 1162 1164 1163 1165 jQuery("#charlie").css({ 1164 width: img_finale.width + pdf ,1165 height: img_finale.height ,1166 width: img_finale.width + pdf + "px", 1167 height: img_finale.height + "px", 1166 1168 marginLeft: "auto" 1167 1169 }); … … 1180 1182 } else { 1181 1183 jQuery("#player").css("width", img_finale.width + "px"); 1182 jQuery("#player").css("height", img_finale.height); 1183 jQuery("#embedplayer").css("width", img_finale.width); 1184 jQuery("#embedplayer").css("height", img_finale.height); 1185 jQuery("embed").css("height", img_finale.height); 1184 jQuery("#player").css("height", img_finale.height + "px"); 1185 1186 jQuery("#embedplayer").css("width", img_finale.width + "px"); 1187 jQuery("#embedplayer").css("height", img_finale.height + "px"); 1188 1189 jQuery("embed").css({ width: img_finale.width + "px", 1190 height: img_finale.height + "px" }); 1191 jQuery("object").css({ width: img_finale.width + "px", 1192 height: img_finale.height + "px" 1193 }); 1194 jQuery("video").css({ width: img_finale.width + "px", 1195 height: img_finale.height + "px" 1196 }); 1197 1198 1199 1186 1200 jQuery("video").height(img_finale.height); 1187 1201 jQuery("video").width(img_finale.width); 1188 jQuery("video").css({ height: img_finale.height + "px" }); 1189 jQuery("object").css({ height: img_finale.height + "px" }); 1202 1190 1203 jQuery("object").width(img_finale.width); 1191 1204 jQuery("object").height(img_finale.height); 1192 jQuery(Cadre).height(img_finale.height + Bandeau_bas.height); //?? 1205 //jQuery(Cadre).height(img_finale.height + Bandeau_bas.height); //?? 1206 1193 1207 jQuery(The_MainImage).height(img_finale.height); 1194 1208 jQuery(Cadre).css("height", "auto"); … … 1577 1591 * 1578 1592 */ 1579 1593 type_src = "div"; 1580 1594 //==================================================== 1581 1595 function Info_Description_f(Parent) { 1582 1596 jQuery(Parent).css({ display: "block" }); 1583 1597 //====== détection du type d'images ====== 1584 if (jQuery("#charlie").length > 0) { 1585 Type_Img = "charlie"; 1586 jQuery("#charlie").css({ 1587 paddingTop: "0px", 1588 marginTop: "0px", 1589 paddingBottom: "10px", 1590 marginBottom: "0px" 1591 }); 1592 1593 } else if (jQuery("#Panorama").length) { 1598 if (jQuery("#Panorama").length) { 1594 1599 Type_Img = "panorama"; 1595 1600 } else if (jQuery("#pamoorama").length) { 1596 1601 Type_Img = "pamoorama"; 1602 1603 } else if (jQuery(Parent + " object").length > 0) { 1604 Type_Img = "charlie"; 1605 if (jQuery(Parent + " div").length > 0) 1606 jQuery(Parent + " div").attr("id", "charlie"); 1607 else 1608 jQuery(Parent + " object").attr("id", "charlie"); 1609 type_src = "object"; 1610 1597 1611 } else if (jQuery(Parent + " embed").length > 0) { 1598 Type_Img = "embed"; 1612 Type_Img = "charlie"; 1613 if (jQuery(Parent + " div").length > 0) 1614 jQuery(Parent + " div").attr("id", "charlie"); 1615 else 1616 jQuery(Parent + "embed").attr("id", "charlie"); 1617 type_src = "embed"; 1618 1619 } else if (jQuery(Parent + " iframe").length > 0) { 1620 Type_Img = "charlie"; 1621 if (jQuery(Parent + " div").length > 0) 1622 jQuery(Parent + " div").attr("id", "charlie"); 1623 else 1624 jQuery(Parent + " iframe").attr("id", "charlie"); 1625 type_src = "iframe"; 1626 1599 1627 } else if (jQuery("#map").length) { 1600 1628 Type_Img = "map"; … … 1613 1641 return; 1614 1642 } 1643 //========================================================= 1644 if (jQuery("#charlie").length > 0) { 1645 jQuery("#charlie").css({ 1646 paddingTop: "0px", 1647 marginTop: "0px", 1648 paddingBottom: "0px", 1649 marginBottom: "0px" 1650 }); 1651 1652 } 1615 1653 // jQuery(Parent + " p:not(:contains(' ')) ").remove(); 1616 1654 // jQuery(Parent + " p:(:contains('')) ").remove(); … … 1699 1737 }); 1700 1738 } else { 1701 jQuery("#charlie").css({ 1702 paddingTop: "0px", 1703 marginTop: "0px", 1704 paddingBottom: "10px", 1705 marginBottom: "0px" 1706 }); 1739 1707 1740 } 1708 1741 … … 1728 1761 info_img = jQuery(The_MainImage).infos(); 1729 1762 Type_Img == "charlie" 1763 if (info_img.width == 0) { 1764 The_MainImage = jQuery("#theMainImage"); 1765 info_img = jQuery(The_MainImage).infos(); 1766 1767 } 1730 1768 } 1731 1769
Note: See TracChangeset
for help on using the changeset viewer.