Merge branch 'master' of github.com:gnuboard/g4s

This commit is contained in:
gnuboard
2013-02-20 17:35:56 +09:00
10 changed files with 146 additions and 38 deletions

View File

@ -186,18 +186,25 @@ $(window).load(function() {
view_image_resize();
});
$(function() {
$("a.view_image").click(function() {
window.open(this.href, "large_image", "top=10,left=10,width=10,height=10,resizable=yes,scrollbars=no,status=no");
return false;
});
});
function view_image_resize()
{
var $img = $('#bo_v_atc img');
var img_wrap = $('#bo_v_atc').width();
var $img = $("#bo_v_atc img");
var img_wrap = $("#bo_v_atc").width();
$img.each(function() {
var img_width = $(this).width();
$(this).data("width", img_width); // 원래 이미지 사이즈
if (img_width > img_wrap) {
$(this).addClass('img_fix');
$(this).addClass("img_fix");
} else if (img_width <= img_wrap && img_width >= $(this).data("width")) {
$(this).removeClass('img_fix');
$(this).removeClass("img_fix");
}
});
}