easyui layout布局问题

$('#container').layout('panel','west').panel({
    onExpand:function(){
        onWindowResize();
    },
    onCollapse:function(){
        onWindowResize();
    }
   });
function onWindowResize(){
    if(timer!=null){
        clearTimeout(timer);
        timer=null;
    }
    timer=setTimeout(function(){
        $("#labcontainer").layout('resize');
        var width=parseFloat(container.offsetWidth);
        var height=parseFloat(container.offsetHeight);
        camera.aspect = width/height;
        camera.updateProjectionMatrix();
        renderer.setPixelRatio(window.devicePixelRatio);
        renderer.setSize(width,height);
        camera.updateMatrixWorld();
        renderer.render(scene, camera);
    },200);
}

阅读更多
想对作者说点什么?

博主推荐

换一批

没有更多推荐了,返回首页