Changeset 7669 for extensions/Autosize/js/Affiche_script.js
- Timestamp:
- Nov 6, 2010, 4:43:08 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/Autosize/js/Affiche_script.js
r7644 r7669 1 2 1 function Toggle_bp() { 3 2 cl_visible = !cl_visible; … … 19 18 jQuery(window).resize(); 20 19 } 21 //========================================================= 22 /* 23 window.onresize = resize; 24 window.onload = load; 25 26 function resize() { 27 alert("resize event detected!"); 28 } 29 function load() { 30 alert("load event detected!"); 31 } 32 */ 20 33 21 jQuery(document).ready( 22 34 23 function (jQuery) { 35 36 37 24 38 25 … … 55 42 marges_llgbo = (ll1.width - ll2.width) + ll2.borderwidth.left + ll2.borderwidth.right; 56 43 } 44 45 46 //========================================================= 47 48 function wait_Timer() { 49 old_w = 0 50 jQuery(window).resize(); 51 info_pamoorama_outter = jQuery("#pamoorama_outter").info(); 52 if (info_pamoorama_outter.width == 0) 53 setTimeout("wait_Timer()", 100); 54 55 } 56 57 58 //============================================================= 59 function cl_Timer() { 60 // if (!jQuery.browser.msie) { jQuery(function () { alert(jQuery.browser.version); }); } 61 if (jQuery.browser.msie && parseInt(jQuery.browser.version) < 8) 62 alert(jQuery.browser.version); 63 panoramaContainer = jQuery(".panorama-container"); 64 n = document.scripts[6]; //12--14affiche_script ; 65 t = n.src; 66 67 currentPosition = 0 - parseInt(jQuery(panoramaContainer).css('margin-left')); 68 if (currentPosition == NaN) return; 69 70 71 if (currentPosition > 1000) 72 jQuery(panoramaContainer).css('margin-left', "0px") 73 setTimeout("cl_Timer()", 500); 74 } 75 //============================================================= 76 function onPropertyChange(e) { 77 var el = e.srcElement; 78 var new_class = el.className; 79 ID = el.id; 80 Prop = e.propertyName.split("."); 81 Property = Prop[1]; 82 if (Property == "display") { 83 Valeur = parseInt(el.currentStyle[Property]); 84 if (Valeur == "block") { 85 86 87 } 88 } 89 return; 90 } 91 92 /* ready 93 * 94 * 95 */ 96 //============================================================ 57 97 /* 58 98 * 59 99 */ 60 61 100 function Info_entete(Parent) { 101 102 var info_imageToolBar = jQuery("#imageToolBar").info(); 103 if (info_imageToolBar.position == "absolute") { 104 jQuery("#imageToolBar").css("position", "relative"); 105 jQuery("#imageToolBar").css("top", 0 + "px"); 106 } 107 108 var info_theImage = jQuery("#theImage").info(); 109 110 if (info_theImage.position == "relative") { 111 //--- passage relative ==> static ===/ 112 jQuery("#theImage").css("position", "static"); 113 info_theImage = jQuery("#theImage").info(); 114 115 } 116 if (info_theImage.position == "absolute") { 117 //--- passage absolute ==> static ===/ 118 jQuery("#theImage").css("position", "static"); 119 info_theImage = jQuery("#theImage").info(); 120 121 } 122 123 marge_top = Info_the_page.top + 124 Info_the_page.borderwidth.top + 125 info_theImage.borderwidth.top; 126 127 img_top = info_theImage.top + info_theImage.borderwidth.top; 128 return { marge_top: marge_top, img_top: img_top }; 129 130 } 131 132 /* Récupère les informations sur la description. 133 * 134 */ 135 function Info_description(Parent) { 136 // jQuery("#" + Parent + " p:not(:contains(' ')) ").remove(); 137 //============================================================================= 138 var info_description = { top: 0, bottom: 0, height: 0 }; 139 if (theme.match(RegExp("simple", "gi"))) { 140 jQuery("#" + Parent).css({ padding: "0px", 141 marginLeft: "0px", 142 marginRight: "auto", 143 marginTop: "0px", 144 marginBottom: "0px", position: "absolute", top: Bandeau + "px" 145 }); 146 } else { 147 148 jQuery("#" + Parent).css({ padding: "0px", 149 marginLeft: "auto", 150 marginRight: "auto", 151 marginTop: "0px", 152 marginBottom: "0px" 153 }); 154 155 156 } 157 158 159 // jQuery("#" + Parent + " p").css({ padding: "0px", margin: "0px " }); 160 161 162 if (theme.match(RegExp("luciano", "g"))) { 163 info_img = jQuery("#" + Parent + " #theImg img").info(); 164 165 } else { 166 167 info_img = jQuery("#" + Parent + " img").info(); 168 } 169 170 info_description.marge = { bottom: info_img.padding.bottom + info_img.margin.bottom + info_img.borderwidth.bottom, 171 top: info_img.padding.top + info_img.borderwidth.top 172 } 173 174 info_description.top = info_img.bottom + info_img.margin.bottom + info_img.borderwidth.bottom; 175 //============================================================================= 176 info_gbo = jQuery("#gbo").info(); 177 if (info_description.top < info_gbo.bottom) 178 info_description.top = info_gbo.bottom; 179 //============================================================================= 180 info_desc = jQuery("#" + Parent + " p:first").info(); 181 if (info_desc.bottom < info_img.bottom) 182 info_desc.bottom = info_img.bottom; 183 184 // if (info_desc.top > info_img.bottom) 185 // info_description.top = info_desc.top; 186 187 if (jQuery("#Panorama").length) { 188 Type_Img = "panorama"; 189 // cl_visible = false; 190 191 } 192 info_table = jQuery(".infoTable").info(); 193 194 if (info_table.top > info_description.bottom) 195 info_description.bottom = info_table.top; 196 //=========================================================================== 197 198 info_licencetag = jQuery(".licencetag").info(); 199 200 201 if (info_licencetag.bottom > 0) { 202 jQuery(".licencetag").css("border", "solid 5px transparent"); 203 if (info_licencetag.bottom > info_description.bottom) { 204 info_description.bottom = info_licencetag.bottom; 205 } 206 else 207 info_description.bottom += info_table.margin.top + info_table.padding.top; 208 209 } 210 //============================================================================= 211 if (theme.match(RegExp("gally", "gi"))) { 212 if (!theme.match(RegExp("lapis", "gi"))) { 213 info_description.bottom = info_description.bottom 214 } 215 } 216 217 218 219 220 221 if (info_description.top < 1) 222 info_description.top = info_description.bottom; 223 224 225 if (info_description.bottom < info_description.top) { 226 info_description.bottom = info_description.top; 227 228 info_desc = jQuery("#" + Parent + " p:last").info(); 229 230 if (info_desc.bottom > info_img.bottom) 231 info_description.bottom = info_desc.bottom; 232 } 233 234 235 if (theme.match(RegExp("gally", "g"))) { 236 if (!theme.match(RegExp("lapis", "gi"))) { 237 info_copyright = jQuery("#copyright").info(); 238 info_description.bottom += info_copyright.height; 239 } 240 } 241 242 if (theme.match(RegExp("luciano", "g"))) { info_description.bottom -= 30 } 243 244 info_description.height = info_description.bottom - info_description.top; 245 246 247 if (DEBUG == "true") { 248 249 /* jQuery("#Debug").text(jQuery("#Debug").text() + user_status); 250 251 252 info_description.width = "800"; 253 */ 254 jQuery("#Debug").css('display', 'block'); 255 jQuery("#Debug1").show(); 256 jQuery("#Debug2").show(); 257 Bandeau_bas = info_description; 258 259 jQuery("#Debug").css({ 260 filter: 'alpha(opacity:50)', 261 position: "absolute", 262 width: "800px", 263 border: "solid 1px green", 264 top: Bandeau + "px" 265 }); 266 jQuery("#Debug").text("Debug:Bandeau : " + Bandeau); 267 268 jQuery("#Debug1").css({ 269 filter: 'alpha(opacity:50)', 270 position: "absolute", 271 border: "solid 1px green", 272 top: Bandeau_bas.top + "px", 273 width: (200) + "px", 274 height: Bandeau_bas.height + "px" 275 }); 276 jQuery("#Debug1").text("Debug1:Bandeau_bas top : " + Bandeau_bas.top + " height:" + Bandeau_bas.height); 277 278 jQuery("#Debug2").css({ 279 filter: 'alpha(opacity:50)', 280 position: "absolute", 281 left: '50px', 282 width: (300) + "px", 283 border: "solid 1px green", top: Bandeau_bas.bottom + "px" 284 }); 285 jQuery("#Debug2").text("Debug2:Bandeau_bas bottom :" + Bandeau_bas.bottom); 286 287 } 288 289 if (check_desc_v != 'checked="checked"') { 290 info_description.height = 0; 291 } 292 293 return info_description; 294 295 } 296 297 /* 298 * 299 */ 300 jQuery("#pamoorama_iner").bind('resize', function () { 301 wait_Timer(); 302 }) 303 //============================================================//== 304 jQuery("#pamoorama_outter").bind('resize', function () { 305 wait_Timer(); 306 }) 307 308 309 310 //============================================================ 311 jQuery("#iGMapsIcon").bind('resize', function () { 312 jQuery().recentrage_widget(); 313 }) 314 jQuery("#icon_gmaps").bind('click', function () { 315 jQuery().recentrage_widget(); 316 }) 317 318 319 320 321 322 323 /* jQuery */ 62 324 var img_init = { height: img_height, width: img_width }; // taille initiale 63 325 var img_defaut = { height: scaled_height, width: scaled_width }; … … 66 328 var Zone_Affichage = { height: 0, width: 0 }; 67 329 68 330 //============================================================ 331 332 var Info_the_page = jQuery("#the_page").info(); 333 var Zone_Affichage = jQuery("#theImage").info(); 334 335 var Bandeau = 0; 336 var Bandeau_t = Info_entete("theImage") 337 Bandeau = Bandeau_t.img_top; 338 var Bandeau_bas = 0; 339 Bandeau_bas = Info_description("theImage"); 69 340 //=================================================================== 70 71 341 /* 72 342 * window .resize 73 343 */ 74 344 jQuery(window).resize(function (event, ui) { 75 76 345 if (typeof (event) == 'undefined') return; 77 346 if (!cl_visible == true) return; … … 80 349 81 350 351 82 352 //========================================================================== 83 var Window_width = jQuery(window).width(); 84 var Window_height = jQuery(window).height(); 85 var winwidth = Window_width; 86 var winheight = Window_height; 353 var winwidth = jQuery(window).width(); 354 var winheight = jQuery(window).height(); 87 355 if (old_w == winwidth && old_h == winheight) return; 88 356 … … 160 428 winwidth -= (marge_right + marge_left); 161 429 430 431 432 162 433 if (Type_Img == "pamoorama") { 163 var myPamoorama = this.myPamoorama; 164 //===================================================== 434 var info_pamoorama = jQuery("#pamoorama").info(); 435 var info_pamoorama_outter = jQuery("#pamoorama_outter").info(); 436 var info_pamoorama_inner = jQuery("#pamoorama_inner").info(); 437 var info_pamoorama_footer = jQuery("#pamoorama_footer").info(); 438 TheImg = jQuery("#pamoorama"); 165 439 if (typeof (myPamoorama) == "undefined") { 440 166 441 return 442 167 443 } 168 169 var h01 = typeof (myPamoorama.imageHeight); 170 171 if (h01 == "undefined") { 172 old_w = 0; 173 old_h = 0; 174 return; 175 } 176 177 //============================================= 178 if (myPamoorama.skipInit == false) 179 return 180 181 444 445 446 447 po = myPamoorama; 182 448 183 449 /* … … 307 573 //========================================================= 308 574 309 var info_pamoorama = jQuery("#pamoorama").info(); 310 var info_pamoorama_outter = jQuery("#pamoorama_outter").info(); 311 var info_pamoorama_inner = jQuery("#pamoorama_inner").info(); 312 var info_pamoorama_footer = jQuery("#pamoorama_footer").info(); 313 TheImg = jQuery("#pamoorama"); 314 315 if (info_pamoorama_outter.height == 0) { 316 old_h = 0; 317 jQuery(window).resize(); 318 return 319 } 320 // event = window.event ? window.event : event; 321 ; 322 // jQuery("#pamoorama_outter").trigger(jQuery.browser.msie ? "propertychange" : "change", [event]); 323 // 324 // jQuery("#pamoorama_outter").trigger("onPropertychange", [event]); 575 576 if (typeof (myPamoorama.imageHeight) == "undefined") { 577 old_w = 0; 578 return; 579 } 325 580 326 581 img_reelle.height = myPamoorama.imageHeight; … … 449 704 var widthmin = winwidth; 450 705 451 if (check_auto_w == 'checked="checked"' || Type_Img == "pamoorama") {706 if (check_auto_w == 'checked="checked"') { 452 707 // if (Type_Img != "pamoorama" && Type_Img != "panorama" ) { 453 708 //==== largeur à atteindre === … … 470 725 if (echelle_w > echelle_max) { echelle_w = echelle_max; } 471 726 Image_width = parseInt(img_reelle.width * echelle_w); 472 if (Type_Img != "pamoorama") { 473 if (rapport > 0) 474 Image_height = parseInt(Image_width / rapport); 475 } 727 if (rapport > 0) 728 Image_height = parseInt(Image_width / rapport); 476 729 } 477 730 … … 617 870 Gmap_ = gmaps.maps[0]; 618 871 if (Gmap_.sizeMode == 'A') { 619 jQuery("#iGMapsIcon").css({ width: Window_width * gmaps.popupAutomaticSize + "px", height: Window_height * gmaps.popupAutomaticSize + "px" }); 872 jQuery("#iGMapsIcon").css({ width: old_w * 0.8 + "px", height: old_h * 0.8 + "px" }); 873 620 874 } 621 875 } … … 657 911 img_height = myPamoorama.imageHeight 658 912 659 660 new_width = Zone_Affichage.width ;913 marge_left += 0; 914 new_width = Zone_Affichage.width - marge_right - marge_left; 661 915 new_width -= 4; 662 916 jQuery("#pamoorama").css({ marginLeft: "auto", … … 688 942 jQuery("#linkPrev").css({ width: "200px", overflow: "hidden" }); 689 943 zoom = Image_height / img_height; 690 944 691 945 692 946 … … 741 995 if (jQuery("#navThumbPrev").length > 0) { 742 996 jQuery("#navThumbPrev").css({ height: info_img.height + "px", 743 top: info_img.top 997 top: info_img.top + 20 + "px" 744 998 }); 745 999 } 746 1000 if (jQuery("#navThumbNext").length > 0) { 747 1001 jQuery("#navThumbNext").css({ height: info_img.height + "px", 748 top: info_img.top 1002 top: info_img.top + 20 +"px" 749 1003 }); 750 1004 } … … 754 1008 jQuery("#imageToolBar").css("position", "static"); 755 1009 info_imageInfoBar = jQuery("#imageInfoBar").info(); 756 info_theImage = jQuery("#theImage").info(); 757 Maxi_b = info_theImage.bottom - info_imageInfoBar.top 758 if (info_imageInfoBar.bottom < info_theImage.bottom) { 759 jQuery("#imageInfoBar").height(info_theImage.height); 760 jQuery("#imageInfoBar").css("height", info_theImage.height + "px"); 1010 if (info_imageInfoBar.bottom < info_img.bottom) { 1011 jQuery("#imageInfoBar").height(info_img.bottom); 761 1012 } 762 1013 … … 773 1024 pos = jQuery("#copyright").info(); 774 1025 if (pos.top > 100) jQuery("#the_page").height(pos.top); 775 776 1026 if (old_w == jQuery(window).width() && old_h == jQuery(window).height()) return; 777 778 1027 jQuery(window).resize(); 779 1028 return; 780 }); // fin resize1029 }); 781 1030 var pos; 782 //================================================ 783 function Info_entete(Parent) { 784 785 var info_imageToolBar = jQuery("#imageToolBar").info(); 786 if (info_imageToolBar.position == "absolute") { 787 jQuery("#imageToolBar").css("position", "relative"); 788 jQuery("#imageToolBar").css("top", 0 + "px"); 789 } 790 791 var info_theImage = jQuery("#theImage").info(); 792 793 if (info_theImage.position == "relative") { 794 //--- passage relative ==> static ===/ 795 jQuery("#theImage").css("position", "static"); 796 info_theImage = jQuery("#theImage").info(); 797 798 } 799 if (info_theImage.position == "absolute") { 800 //--- passage absolute ==> static ===/ 801 jQuery("#theImage").css("position", "static"); 802 info_theImage = jQuery("#theImage").info(); 803 804 } 805 806 marge_top = Info_the_page.top + 807 Info_the_page.borderwidth.top + 808 info_theImage.borderwidth.top; 809 810 img_top = info_theImage.top + info_theImage.borderwidth.top; 811 return { marge_top: marge_top, img_top: img_top }; 812 813 } 814 815 /* Récupère les informations sur la description. 816 * 817 */ 818 function Info_description(Parent) { 819 // jQuery("#" + Parent + " p:not(:contains(' ')) ").remove(); 820 //============================================================================= 821 var info_description = { top: 0, bottom: 0, height: 0 }; 822 if (theme.match(RegExp("simple", "gi"))) { 823 jQuery("#" + Parent).css({ padding: "0px", 824 marginLeft: "0px", 825 marginRight: "auto", 826 marginTop: "0px", 827 marginBottom: "0px", position: "absolute", top: Bandeau + "px" 828 }); 829 } else { 830 831 jQuery("#" + Parent).css({ padding: "0px", 832 marginLeft: "auto", 833 marginRight: "auto", 834 marginTop: "0px", 835 marginBottom: "0px" 836 }); 837 838 839 } 840 841 842 // jQuery("#" + Parent + " p").css({ padding: "0px", margin: "0px " }); 843 844 845 if (theme.match(RegExp("luciano", "g"))) { 846 info_img = jQuery("#" + Parent + " #theImg img").info(); 847 848 } else { 849 850 info_img = jQuery("#" + Parent + " img").info(); 851 } 852 853 info_description.marge = { bottom: info_img.padding.bottom + info_img.margin.bottom + info_img.borderwidth.bottom, 854 top: info_img.padding.top + info_img.borderwidth.top 855 } 856 857 info_description.top = info_img.bottom + info_img.margin.bottom + info_img.borderwidth.bottom; 858 //============================================================================= 859 info_gbo = jQuery("#gbo").info(); 860 if (info_description.top < info_gbo.bottom) 861 info_description.top = info_gbo.bottom; 862 //============================================================================= 863 info_desc = jQuery("#" + Parent + " p:first").info(); 864 if (info_desc.bottom < info_img.bottom) 865 info_desc.bottom = info_img.bottom; 866 867 // if (info_desc.top > info_img.bottom) 868 // info_description.top = info_desc.top; 869 870 if (jQuery("#Panorama").length) { 871 Type_Img = "panorama"; 872 // cl_visible = false; 873 874 } 875 info_table = jQuery(".infoTable").info(); 876 877 if (info_table.top > info_description.bottom) 878 info_description.bottom = info_table.top; 879 //=========================================================================== 880 881 info_licencetag = jQuery(".licencetag").info(); 882 883 884 if (info_licencetag.bottom > 0) { 885 jQuery(".licencetag").css("border", "solid 5px transparent"); 886 if (info_licencetag.bottom > info_description.bottom) { 887 info_description.bottom = info_licencetag.bottom; 888 } 889 else 890 info_description.bottom += info_table.margin.top + info_table.padding.top; 891 892 } 893 //============================================================================= 894 if (theme.match(RegExp("gally", "gi"))) { 895 if (!theme.match(RegExp("lapis", "gi"))) { 896 info_description.bottom = info_description.bottom 897 } 898 } 899 900 901 902 903 904 if (info_description.top < 1) 905 info_description.top = info_description.bottom; 906 907 908 if (info_description.bottom < info_description.top) { 909 info_description.bottom = info_description.top; 910 911 info_desc = jQuery("#" + Parent + " p:last").info(); 912 913 if (info_desc.bottom > info_img.bottom) 914 info_description.bottom = info_desc.bottom; 915 } 916 917 918 if (theme.match(RegExp("gally", "g"))) { 919 if (!theme.match(RegExp("lapis", "gi"))) { 920 info_copyright = jQuery("#copyright").info(); 921 info_description.bottom += info_copyright.height; 922 } 923 } 924 925 if (theme.match(RegExp("luciano", "g"))) { info_description.bottom -= 30 } 926 927 info_description.height = info_description.bottom - info_description.top; 928 929 930 if (DEBUG == "true") { 931 932 /* jQuery("#Debug").text(jQuery("#Debug").text() + user_status); 933 934 935 info_description.width = "800"; 936 */ 937 jQuery("#Debug").css('display', 'block'); 938 jQuery("#Debug1").show(); 939 jQuery("#Debug2").show(); 940 Bandeau_bas = info_description; 941 942 jQuery("#Debug").css({ 943 opacity: "0.50", 944 filter: 'alpha(opacity:50)', 945 position: "absolute", 946 width: "800px", 947 border: "solid 1px green", 948 top: Bandeau + "px" 949 }); 950 jQuery("#Debug").text("Debug:Bandeau : " + Bandeau); 951 952 jQuery("#Debug1").css({ opacity: "0.50", 953 filter: 'alpha(opacity:50)', 954 position: "absolute", 955 border: "solid 1px green", 956 top: Bandeau_bas.top + "px", 957 width: (200) + "px", 958 height: Bandeau_bas.height + "px" 959 }); 960 961 // jQuery("#Debug1").text(jQuery("#Debug1").text()+"Debug1:Bandeau_bas top : " + Bandeau_bas.top + " height:" + Bandeau_bas.height); 962 963 jQuery("#Debug2").css({ opacity: "0.50", 964 filter: 'alpha(opacity:50)', 965 position: "absolute", 966 left: '50px', 967 width: (300) + "px", 968 border: "solid 1px green", top: Bandeau_bas.bottom + "px" 969 }); 970 jQuery("#Debug2").text("Debug2:Bandeau_bas bottom :" + Bandeau_bas.bottom); 971 972 } 973 974 if (check_desc_v != 'checked="checked"') { 975 info_description.height = 0; 976 } 977 978 return info_description; 979 980 } 981 //================================================================================== 982 983 //======== jQuery(window).resize();=========================================================== 984 1031 //=================================================================== 1032 jQuery(window).resize(); 985 1033 /* 986 1034 * recherche la plus grande image (hauteur ou largeur) … … 1007 1055 } 1008 1056 1009 jQuery("#theImage").css({ opacity: "0.0", filter: 'alpha(opacity:0)' });1010 1011 var Bandeau = 0;1012 var Info_the_page = jQuery("#the_page").info();1013 var Zone_Affichage = jQuery("#theImage").info();1014 var Bandeau_t = Info_entete("theImage");1015 var Bandeau_bas = 0;1016 1017 //====================================================================================1018 jQuery(window).load(function () {1019 1020 1021 1022 Info_the_page = jQuery("#the_page").info();1023 Zone_Affichage = jQuery("#theImage").info();1024 Bandeau_t = Info_entete("theImage")1025 Bandeau = Bandeau_t.img_top;1026 Bandeau_bas = Info_description("theImage");1027 setTimeout('wait_Timer()', 10);1028 });1029 //====================================================================================1030 1057 1031 1058 } // function 1032 ); 1033 1034 //============================================================= 1035 function cl_Timer() { 1036 // if (!jQuery.browser.msie) { jQuery(function () { alert(jQuery.browser.version); }); } 1037 if (jQuery.browser.msie && parseInt(jQuery.browser.version) < 8) 1038 alert(jQuery.browser.version); 1039 panoramaContainer = jQuery(".panorama-container"); 1040 n = document.scripts[6]; //12--14affiche_script ; 1041 t = n.src; 1042 1043 currentPosition = 0 - parseInt(jQuery(panoramaContainer).css('margin-left')); 1044 if (currentPosition == NaN) return; 1045 1046 1047 if (currentPosition > 1000) 1048 jQuery(panoramaContainer).css('margin-left', "0px") 1049 setTimeout("cl_Timer()", 500); 1050 } 1051 1052 1053 //============================================================ 1054 jQuery("#iGMapsIcon").bind('resize', function () { 1055 jQuery().recentrage_widget(); 1056 }) 1057 jQuery("#icon_gmaps").bind('click', function () { 1058 jQuery().recentrage_widget(); 1059 }) 1060 1061 1062 //============================================================= 1063 //frame.injectInside 1064 function onPropertyChange(e) { 1065 1066 var el = e.srcElement; 1067 if (e.srcElement == null) return 1068 ID = el.id; 1069 if (jQuery.browser.msie) 1070 PropertyName = window.event.propertyName; 1071 else 1072 PropertyName = window.evt.propertyName; 1073 1074 if (!PropertyName) return; 1075 Prop = PropertyName.split("."); 1076 1077 Valeur = ""; 1078 Property = Prop[1]; 1079 if (typeof (Property) != "undefined") { 1080 Valeur = parseInt(el.currentStyle[Property]); 1081 } else { 1082 Property = Prop[0]; 1083 } 1084 if (DEBUG == "true") { 1085 1086 if (typeof (message) == "undefined") message = jQuery("#Debug1").text(); 1087 1088 jQuery("#Debug1").css({ 1089 filter: 'alpha(opacity:60)', 1090 opacity: 0.8, 1091 position: "absolute", 1092 border: "solid 1px green", 1093 top: 100 + "px", 1094 width: "auto", 1095 height: 400 + "px" 1096 }); 1097 if (ID != "pamoorama") { 1098 message += "onPropertyChange : " + ID + " : " + Property + " : " + Valeur + "\n"; 1099 jQuery("#Debug1").text(message); 1100 } 1101 1102 if (Valeur == "block") { 1103 1104 1105 } 1106 } 1107 return; 1108 } 1109 //==================================================================== // ready 1110 /* 1111 * 1112 */ 1059 ); // ready 1060 /* 1061 * 1062 */ 1113 1063 jQuery.extend(jQuery.expr[':'], { 1114 1064 // Nom du sélecteur personnalisé … … 1129 1079 jQuery('html,body').stop().scrollTop(0); 1130 1080 jQuery('html,body').stop().scrollLeft(0); 1131 jQuery(".ui-widget-overlay").css( {opacity:"0.75",filter: 'alpha(opacity:65)'});1081 jQuery(".ui-widget-overlay").css("opacity", "0.75"); 1132 1082 1133 1083 l1 = (jQuery(window).width() - (jQuery(".gmapsPopup").width()))/2; … … 1137 1087 jQuery(".gmapsPopup").css("top", h1 + "px"); 1138 1088 1089 }, 1090 //------------------------------------------------------- 1091 absolutize: function (element) { 1092 element = jQuery(element).get(0); 1093 if (element.getStyle('position') == 'absolute') return; 1094 // Position.prepare(); // To be done manually by Scripty when it needs it. 1095 1096 var offsets = element.positionedOffset(); 1097 var top = offsets[1]; 1098 var left = offsets[0]; 1099 var width = element.clientWidth; 1100 var height = element.clientHeight; 1101 1102 element._originalLeft = left - parseFloat(element.style.left || 0); 1103 element._originalTop = top - parseFloat(element.style.top || 0); 1104 element._originalWidth = element.style.width; 1105 element._originalHeight = element.style.height; 1106 1107 element.style.position = 'absolute'; 1108 element.style.top = top + 'px'; 1109 element.style.left = left + 'px'; 1110 element.style.width = width + 'px'; 1111 element.style.height = height + 'px'; 1112 return element; 1113 }, 1114 1115 relativize: function (element) { 1116 element = jQuery(element).get(0); ; 1117 if (jQuery(element).css('position') == 'relative') return; 1118 // Position.prepare(); // To be done manually by Scripty when it needs it. 1119 element._originalLeft = parseFloat(element.style.left || 0); 1120 element._originalTop = parseFloat(element.style.top || 0); 1121 element._originalWidth = element.style.width; 1122 element._originalHeight = element.style.height; 1123 1124 element.style.position = 'relative'; 1125 var top = parseFloat(element.style.top || 0) - (element._originalTop || 0); 1126 var left = parseFloat(element.style.left || 0) - (element._originalLeft || 0); 1127 1128 element.style.top = top + 'px'; 1129 element.style.left = left + 'px'; 1130 // element.style.height = element._originalHeight; 1131 // element.style.width = element._originalWidth; 1132 return element; 1139 1133 } 1140 1134 //========================================================= 1141 1135 }); // fin extend 1142 1143 1144 function wait_Timer() {1145 old_w = 0;1146 old_h = 0;1147 1148 1149 if (jQuery("#pamoorama").length > 0) {1150 var info_pamoorama_outter = jQuery("#pamoorama_outter").info();1151 if (info_pamoorama_outter.height == 0) {1152 1153 jQuery("#theImage").css({ opacity: '0', filter: 'alpha(opacity:' + '0' + ')' });1154 setTimeout('wait_Timer()', 200);1155 return1156 }1157 }1158 jQuery(window).resize();1159 jQuery("#theImage").css({ opacity: '1', filter: 'alpha(opacity:' + '100' + ')' });1160 1161 }1162 1163
Note: See TracChangeset
for help on using the changeset viewer.