var _isIE=(navigator.userAgent.match(/Gecko/))?false:true; var _isIE7=(navigator.userAgent.match(/MSIE\s+7/i))?true:false; var _isIE8=(navigator.userAgent.match(/MSIE\s+8/i))?true:false; var _isXp=(navigator.userAgent.indexOf('Windows NT 5.1') > 0)?true:false; function win_resize() { var bw = document.body.scrollWidth; var bh = document.body.scrollHeight; if (!_isIE) { window.resizeTo(bw+10, bh+60); } else if (_isIE7 || _isIE8) { window.resizeTo(bw+10, bh+80); } else if (_isXp && !_isIE7) { window.resizeTo(bw+10, bh+40); } else { window.resizeTo(bw+10, bh+29); } } function photo_form(s_layer, s_id, s_imgPath, s_swfPath1, s_swfPath2, s_swfPath3, x_position, y_position, s_name, s_depth, s_scale) { para = '?s_layer='+s_layer+'&s_id='+s_id+'&x_position='+x_position+'&y_position='+y_position+'&s_depth='+s_depth+'&s_scale='+s_scale; window.open('/myroom/photo_make.php'+para, 'PHOTO_FORM', 'width=320, height=380, scrollbars=no, top=300, left=400'); } function TodayItemMove(type, cnt) { var value = 50; var init = 4; var limit = value * (cnt-init); var obj = document.getElementById('TodayView'); if(type == 'up') { // IE if(navigator.appName.indexOf('Microsoft') != -1) { if(obj.style.pixelTop != 0) obj.style.pixelTop += 50; } // FF else { if(parseInt(obj.style.top) != 0) obj.style.top = parseInt(obj.style.top)+50; } } else if(type == 'down') { if(cnt > init) { // IE if(navigator.appName.indexOf('Microsoft') != -1) { if(obj.style.pixelTop != -limit) obj.style.pixelTop -= 50; } // FF else { if(parseInt(obj.style.top) != -limit) obj.style.top = parseInt(obj.style.top)-50; } } } } function DeleteSelectboxControl(item_no) { if(item_no == '') { alert('アイテムを選択してください'); } else { //AVATAR_WEAR.options[AVATAR_WEAR.selectedIndex] = null; avatar_box.thisMovie('ExternalInterfacecallback').item_delete(item_no); } } function SwfEmbeded(get_swf, get_width, get_height, get_id) { /* if (navigator.appVersion.indexOf("MSIE") != -1) { var object_str = ""; }else{ var object_str = ""; } document.write(object_str); */ SwfEmbeded_wmode2(get_swf, get_width, get_height, get_id); } function SwfEmbeded_wmode(get_swf, get_width, get_height, get_id) { if (navigator.appVersion.indexOf("MSIE") != -1) { var object_str = ""; }else{ var object_str = ""; } document.write(object_str); } function SwfEmbeded_wmode2(get_swf, get_width, get_height, get_id) { if (navigator.appVersion.indexOf("MSIE") != -1) { var object_str = ""; }else{ var object_str = ""; } document.write(object_str); } var b_id = '' // avatar buy open function item_buy(item_type, item_no, save_area, view_type) { if(save_area > 1) save_area = save_area; else save_area = 1; if(view_type > 1) view_type = view_type; else view_type = 1; link_url = '/settlement/pop_buy.php?item_no='+item_no+'&item_type='+item_type+'&save_area='+save_area+'&view_type='+view_type; b_id = window.open(link_url, '', 'width=320, height=331, top=150, left=400'); } function getItemBuy(s_id) { var url = '/settlement/pop_buy.php?item_no='+s_id+'&view_type=2'; b_id = window.open(url, '', 'width=320, height=331, top=150, left=400'); } // avatar gift open function item_gift(item_type, item_no, save_area, view_type) { if(save_area > 1) save_area = save_area; else save_area = 1; if(view_type > 1) view_type = view_type; else view_type = 1; link_url = '/settlement/pop_gift.php?item_no='+item_no+'&item_type='+item_type+'&save_area='+save_area+'&view_type='+view_type; b_id = window.open(link_url, '', 'width=320, height=479, top=150, left=400'); } // avatar hope function item_hope(item_no, item_name, item_category, item_kind) { // if(confirm('['+item_name+'] hope?')) //{ ACT_FRAME.location.href = '/settlement/action.php?mode=hope&item_no='+item_no+'&item_category='+item_category+'&item_kind='+item_kind; // } } // avatar market function item_market(item_no, item_name, item_category, item_kind) { //if(confirm('['+item_name+'] market?')) // { ACT_FRAME.location.href = '/settlement/action.php?mode=market&item_no='+item_no+'&item_category='+item_category+'&item_kind='+item_kind; //} } // avatar view function item_view(item_type, item_no) { window.open('/settlement/view.php?item_no='+item_no+'&item_type='+item_type, 'VIEW', 'width=305, height=300, top=200, left=400, scrollbars=no'); } function getMyaViewerSoap(kind, nid_aha1, soap_url, swf_path, basic_path) { var width, height, swf; switch(kind) { case '1' : width = 130; height = 200; break; case '2' : width = 100; height = 150; break; case '3' : width = 100; height = 80; break; case '4' : width = 70; height = 60; break; case '5' : width = 40; height = 40; break; case '6' : width = 30; height = 30; break; case '7' : width = 70; height = 105; break; } swf = 'http://image.mgame.jp/mya/AVATAR_EDITVIEW/view_0'+kind+'.swf'; swf = swf+'?nid_sha1='+nid_aha1+'&soap_url='+soap_url+'&swf_path='+swf_path+'&basic_path='+basic_path; SwfEmbeded(swf, width, height, 'viewer_swf'); } function getMyaViewer(kind, nid, sex) { var width, height, swf; switch(kind) { case '1' : width = 130; height = 200; break; case '2' : width = 100; height = 150; break; case '3' : width = 100; height = 80; break; case '4' : width = 70; height = 60; break; case '5' : width = 40; height = 40; break; case '6' : width = 30; height = 30; break; case '7' : width = 70; height = 105; break; } swf = 'http://image.mgame.jp/mya/AVATAR_EDITVIEW/view_0'+kind+'.swf'; swf = swf+'?nid='+nid+'&user_type='+sex; SwfEmbeded(swf, width, height, 'viewer_swf'); } function getMyaViewerClimbx(kind, nid, sex, dir) { var width, height, swf; switch(kind) { case '1' : width = 130; height = 200; break; case '2' : width = 100; height = 150; break; case '3' : width = 100; height = 80; break; case '4' : width = 70; height = 60; break; case '5' : width = 40; height = 40; break; case '6' : width = 30; height = 30; break; case '7' : width = 70; height = 105; break; } swf = 'http://image.mgame.jp/mya/AVATAR_EDITVIEW/view_0'+kind+'.swf'; swf = swf+'?nid='+nid+'&user_type='+sex+'&save_dir='+dir; SwfEmbeded(swf, width, height, 'viewer_swf'); } function getOpenEvent() { swf = '/event/giftbox.swf'; SwfEmbeded(swf, '120', '130', 'giftbox'); }