Ignore:
Timestamp:
Jan 8, 2011, 6:17:44 PM (13 years ago)
Author:
cljosse
Message:

[Autosize][beta] compatibility with theme simple


File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/Autosize/js/Affiche_script.js

    r8186 r8536  
    4242               }
    4343        info_pamoorama = jQuery("#pamoorama").infos();
    44          new_width= info_pamoorama.width ;
     44        new_width = info_pamoorama.width -( info_pamoorama.borderwidth.left + info_pamoorama.borderwidth.right);
    4545         if (  Math.abs(new_width - myPamoorama.options.width)>10  ) {
    4646                 setTimeout("Wait_pamoorama()", 500);
     
    9393             if (fade_in != 0) {
    9494                 if (msie)
    95                      jQuery("#theImage").css({ opacity: "0"  });
     95                     jQuery("#theImage").css({ opacity: "0" });
    9696                 else
    9797                     jQuery("#theImage").css({ opacity: "0" });
     
    235235                 if (n == 0) {
    236236                     n = winheight - old_window.height;
    237                      if (n == 0) return true;
     237                     if (n == 0)
     238                         return true;
    238239                 }
    239240                 old_window = jQuery(window).infos();
     
    264265                     if (info_ToolBar.width > 0)
    265266                         marge = (Zone_Affichage.width - info_ToolBar.width) / 2;
    266                      else if (info_the_page.width>0)
     267                     else if (info_the_page.width > 0)
    267268                         marge = (Zone_Affichage.width - info_the_page.width) / 2;
    268269
     
    272273                     if (info_content.width > 100) {
    273274
    274                          marge_left = 0;
     275                         marge_left = (info_imageInfoBar.margin.left);
    275276                         marge_right = (info_imageInfoBar.margin.left + info_imageInfoBar.margin.right);
    276277                         winwidth = info_content.width;
     
    676677                 jQuery("#standard").css("top", 0 + "px");
    677678                 jQuery("#comments").css("top", 0 + "px");
    678 
    679 
    680 
    681 
    682679                 //========== Image Remise à l'échelle =======================
    683680
    684681                 Image_height = img_finale.height;
    685682                 Image_width = img_finale.width;
    686 
    687 
    688 
    689683                 //=========================================================================
     684                 jQuery(Cadre).css({ marginLeft: marge_left + "px"
     685                 });
    690686                 jQuery(Cadre).width(Zone_Affichage.width);
    691687                 //   jQuery(Cadre).height(Zone_Affichage.height);
     
    749745
    750746                 } else if (Type_Img == "pamoorama") {
    751 
     747                     info_theImage.height = Zone_Affichage.height;
    752748                     img_height = myPamoorama.imageHeight
    753                      marge_left += 2;
    754 
    755749                     if (theme.match(RegExp("simple", "g"))) {
    756                          marge_right = 2;
     750                         //  marge_right = 2;
    757751                     }
    758752                     new_width = Zone_Affichage.width - marge_right - marge_left;
    759                      info_theImage.height = Zone_Affichage.height;
     753                     new_width = Zone_Affichage.width - (info_theImage.borderwidth.right + info_theImage.borderwidth.left);
     754
     755
    760756
    761757                     Zone_Affichage.height += info_pamoorama_footer.height;
    762 
    763 
    764758                     zoom = info_theImage.height / img_height;
    765759                     myPamoorama.options.width = new_width * zoom;
    766 
    767 
    768760                     //  if(msie || safari) jQuery("#pamoorama_inner ").css({ zoom: zoom });
    769761                     //====================================================
     
    771763                         marginLeft: "auto",
    772764                         marginRight: "auto",
    773                   //       height: Zone_Affichage.height + "px", sinon déclenchement panorama sur la hauteur;
     765                         //height: Zone_Affichage.height + "px", sinon déclenchement panorama sur la hauteur;
    774766                         width: new_width + "px"
    775767                     });
     
    782774
    783775                     jQuery("#pamoorama_outter").width(new_width);
     776
     777
    784778                     // commenter sinon outter augmente à chaque resize
    785                    //  jQuery("#pamoorama_outter").height(info_pamoorama.height - info_pamoorama_footer.height);
     779                     //  jQuery("#pamoorama_outter").height(info_pamoorama.height - info_pamoorama_footer.height);
    786780
    787781
    788782
    789783                     jQuery("#pamoorama_outter").css({ width: new_width + "px" });
     784                     jQuery("#pamoorama_footer").css({ width: new_width + "px" });
    790785                     //     
    791786                     //====================================================
     
    851846                     } else if (theme.match(RegExp("simple", "g"))) {
    852847
    853                          jQuery("#imageToolBar").css("position", "static");
     848                         jQuery("#imageToolBar").css({ position: "static" });
     849                         
    854850                         info_imageInfoBar = jQuery("#imageInfoBar").infos();
    855851                         if (info_imageInfoBar.bottom < info_img.bottom) {
    856                              jQuery("#imageInfoBar").height(info_img.bottom);
     852                          //   jQuery("#imageInfoBar").height(info_img.bottom);
    857853                         }
    858854
     
    892888                     }
    893889                     //   jQuery(Cadre).css("border", "solid green");
    894                      margins = jQuery(Cadre).css("margin");
     890                     margins = info_frame.margin.margin;
    895891                     jQuery("#Debug5").css({ background: "transparent",
    896892                         position: pos,
    897893                         border: "green solid 2px",
    898894                         textAlign: align_auto,
    899                          margin: "4px",
     895                         margin: margins,
    900896                         top: t1 + "px",
    901897                         left: l1 + "px",
Note: See TracChangeset for help on using the changeset viewer.