代码之家  ›  专栏  ›  技术社区  ›  Alexander

DockedItems不考虑重量

  •  1
  • Alexander  · 技术社区  · 7 年前

    Sencha documentation says :

    我现在想展示一个 container 低于 buttons 配置。因此,我做了一个简单的小提琴来应用文档的知识:

    https://fiddle.sencha.com/#view/editor&fiddle/26m0

    1 回复  |  直到 7 年前
        1
  •  2
  •   scebotari66    7 年前

    这个 dock 容器的配置没有任何影响。从文档中:

    您的容器不在 dockedItems 配置。此外,似乎权重越大,渲染的项目越高。

    Ext.create('Ext.window.Window',{
        width:300,
        items:[{
            xtype:'container',
            html: 'Normal text'
        }],
        dockedItems: {
            xtype: 'container',
            dock: 'bottom',
            weight: -10,
            html: 'Some text that goes below the buttons'
        },
        buttons:[{
            text: 'Some button',
            weight: 10
        }]
    
    }).show();
    

    https://fiddle.sencha.com/#view/editor&fiddle/26m8