0
タスクバーのクイックスタートにボタンを追加する必要がありますが、私はモジュールウィンドウを開けたくありません。例えば、メッセージボックスを確認するログアウトボタンです。 :Extjs Desktop TaskBarクイックスタートにボタンを追加
getTaskbarConfig: function() {
var ret = this.callParent();
me = this;
return Ext.apply(ret, {
quickStart: [
{ name: 'Window', iconCls: 'icon-window', module: 'ext-win' },
{ name: 'Logout', iconCls:'logout', handler: me.onLogout}
]
});
},
onLogout: function() {
Ext.Msg.confirm('Logout', 'Are you sure you want to logout?');
},
と私はTaskBar.jsのgetQuickStart機能はこれにファイルの変更:
getQuickStart: function() {
var me = this, ret = {
minWidth: 20,
width: Ext.themeName === 'neptune' ? 70 : 60,
items: [],
enableOverflow: true
};
Ext.each(this.quickStart, function (item) {
ret.items.push({
tooltip: { text: item.name, align: 'bl-tl' },
overflowText: item.name,
iconCls: item.iconCls,
module: item.module,
//handler: me.onQuickStartClick, **original code**
handler: item.handler == undefined ? me.onQuickStartClick : item.handler,
scope: me
});
});
return ret;
}
しかし、それは動作しません、タスクバーのクイックスタートに、簡単なボタンを追加する方法はありますか?
あなたはこのための手伝いを提供できますか?あなたが試してみたいことは不明ですか?試してみてください。https://fiddle.sencha.com –
私はこの問題を解決し、回答を投稿しました。ありがとうございます。 – Remigio