robertj98
6 Jul 2010, 1:22 AM
Hi,
I have just modified the JSONP example to try and display different content when I click on some test buttons in a toolbar.
However, the handler events for the toolbar seem to be firing when the page loads and then do not fire when you click on the buttons. The panel definition is:
new Ext.Panel({
fullscreen: true,
id: 'content',
scroll: 'vertical',
dockedItems: [{
xtype: 'toolbar',
dock: 'top',
items: [
{
text: 'Refresh Issues',
handler: getIssues (1991)
},
{
text: '1978',
handler: getIssues (1978)
}
]
},{
id: 'status',
xtype: 'toolbar',
dock: 'bottom',
title: "Tap one of the buttons above."
}
]
})
The getIssues function is declared above this - I have an alert in it and it displays the data and year parameters, 1991 and 1978 when the page loads.
Am I doing something wrong here?
Robert Jones
I have just modified the JSONP example to try and display different content when I click on some test buttons in a toolbar.
However, the handler events for the toolbar seem to be firing when the page loads and then do not fire when you click on the buttons. The panel definition is:
new Ext.Panel({
fullscreen: true,
id: 'content',
scroll: 'vertical',
dockedItems: [{
xtype: 'toolbar',
dock: 'top',
items: [
{
text: 'Refresh Issues',
handler: getIssues (1991)
},
{
text: '1978',
handler: getIssues (1978)
}
]
},{
id: 'status',
xtype: 'toolbar',
dock: 'bottom',
title: "Tap one of the buttons above."
}
]
})
The getIssues function is declared above this - I have an alert in it and it displays the data and year parameters, 1991 and 1978 when the page loads.
Am I doing something wrong here?
Robert Jones