【问题标题】:titleCollapse in TabPanel in extjs 3.4extjs 3.4 中 TabPanel 中的标题折叠
【发布时间】:2013-04-10 04:30:51
【问题描述】:

在 ExtJS 3.4 中,用于实现 collapsible:truetitleCollapse:true 的 TabPanel 启用 TabPanel 的折叠和展开。但是,即使单击选项卡也会导致折叠/展开。

如何避免这种情况?

var tabs2 = new Ext.TabPanel({
    collapsible:true,
    titleCollapse:true,
    renderTo: document.body,
    activeTab: 0,
    width:600,
    height:250,
    plain:true,
    defaults:{autoScroll: true},
    items:[{
            title: 'Normal Tab',
            html: "My content was added during construction."
        },{
            title: 'Ajax Tab 1',
            autoLoad:'ajax1.htm'
        },{
            title: 'Ajax Tab 2',
            autoLoad: {url: 'ajax2.htm', params: 'foo=bar&wtf=1'}
        },{
            title: 'Event Tab',
            listeners: {activate: handleActivate},
            html: "I am tab 4's content. I also have an event listener attached."
        },{
            title: 'Disabled Tab',
            disabled:true,
            html: "Can't see me cause I'm disabled"
        }
    ]
});

【问题讨论】:

    标签: extjs extjs3 tabpanel


    【解决方案1】:

    删除titleCollapse:true, 属性。选项卡标题呈现在标题元素内,当您打开 titleCollapse 属性时,您的按钮也可以用作展开/折叠按钮。

    【讨论】:

    • 我同意,但我的要求是在单击标题栏上的任意位置时折叠标签面板。
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-08-10
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多