• 设为首页
  • 收藏本站
  • 积分充值
  • VIP赞助
  • 手机版
  • 微博
  • 微信
    微信公众号 添加方式:
    1:搜索微信号(888888
    2:扫描左侧二维码
  • 快捷导航
    福建二哥 门户 查看主题

    Extjs gridpanel 出现横向滚动条问题的解决方法

    发布者: 福建二哥 | 发布时间: 2025-8-13 13:09| 查看数: 96| 评论数: 0|帖子模式

    viewConfig : {
    layout : function() {
    if (!this.mainBody) {
    return; // not rendered
    }
    var g = this.grid;
    var c = g.getGridEl();
    var csize = c.getSize(true);
    var vw = csize.width;
    if (!g.hideHeaders && (vw < 20 || csize.height < 20)) { // display:
    // none?
    return;
    }
    if (g.autoHeight) {
    if (this.innerHd) {
    this.innerHd.style.width = (vw) + 'px';
    }
    } else {
    this.el.setSize(csize.width, csize.height);
    var hdHeight = this.mainHd.getHeight();
    var vh = csize.height - (hdHeight);
    this.scroller.setSize(vw, vh);
    if (this.innerHd) {
    this.innerHd.style.width = (vw) + 'px';
    }
    }
    if (this.forceFit) {
    if (this.lastViewWidth != vw) {
    this.fitColumns(false, false);
    this.lastViewWidth = vw;
    }
    } else {
    this.autoExpand();
    this.syncHeaderScroll();
    }
    this.onLayout(vw, vh);
    }
    }

    来源:互联网
    免责声明:如果侵犯了您的权益,请联系站长(1277306191@qq.com),我们会及时删除侵权内容,谢谢合作!

    最新评论

    浏览过的版块

    QQ Archiver 手机版 小黑屋 福建二哥 ( 闽ICP备2022004717号|闽公网安备35052402000345号 )

    Powered by Discuz! X3.5 © 2001-2023

    快速回复 返回顶部 返回列表