我想通过单击工具栏中的按钮来显示模态信息窗口。我不知道为什么,但是当我点击按钮时没有任何反应。
继承我的代码:
xtype: 'toolbar',
docked: 'bottom',
items: [
{
xtype: 'button',
text: 'Infos anzeigen',
handler: function(){
var panel = new Ext.Panel({
modal: true,
left: 0,
top: 0,
width: 220,
height: 356,
layout: 'fit',
html: 'Testing'
});
panel.show();
}
}]
答案 0 :(得分:1)
您可能正在寻找Ext.Window:
var win = new Ext.Window({
modal: true,
left: 0,
top: 0,
width: 220,
height: 356,
layout: 'fit',
html: 'Testing'
});
win.show();