View Full Version : How to use suspendEvents to queue events of a Ext.Button?

Ben Holzer
31 Jul 2012, 8:36 AM
Hi all,

I have the following button in one of my view components:

var creationButton = Ext.create('Ext.Button', {
id : 'CreationButton',
text : 'CreationButton',
handler : function(button, event) {
scope : this

In my controller I want to suspend (queue) the events of this button and later on I like to resume the queued events.

How can I implement this? In my controller I tried:


Nothing worked... What am I doing wrong? Could someone please, please help me out?

Thanks in advance.

31 Jul 2012, 10:42 AM
You should suspendEvents on whatever 'this' is inside that method, it's not the button...

Ben Holzer
31 Jul 2012, 11:16 PM
Thanks for your quick answer!

I already tried to suspend the events of the panel where the button lies on.


This did not work. Is there any other way to fire or suspend the events of this button?

Ben Holzer
1 Aug 2012, 12:40 AM
I forgot to mension that I also tried to send click events and to suspend the events of the button, which did not work too.

With this button I like to trigger an AJAX call. So I suspended once the events of the ajaxcomunication interface. Of course this was the wrong way as I only suspended the success event, but suspending those events would have worked...