You could use a global counter for your requests. Increment it when sending a request, decrement on completion. Show the message when the first request is sent, hide it when the counter reaches zero.
Regards, Daniel On 05/03/2012 06:59 PM, Benjamin Dreux wrote: > I use the flush you pointed to me. > It work relatively good. > > The message is shown. > As you sayed the message is quickly remove, when the request is short. > But that's ok to me. > > > My issue now is that, i do one big query, then multiple (3 or 4) small ones. > The secondary requests are made as a reaction (an event is fired which > trigger the request). > The issue is that the loading message is shown and hided multiple time. > It look like it's blinking. > > I'm looking for a way to show the message once for the bunch of request. > > Regards > > 2012/5/3 Daniel Wagner<[email protected]>: >> Hi Benjamin, >> >> you can call qx.ui.core.queue.Manager.flush(), but I doubt that's going >> to help. If the request completes quickly (particularly if it's cached), >> the user won't have a chance to notice the message. >> >> If you think it's necessary to inform the user in any case, just use >> setTimeout to delay hiding the message for a couple seconds after the >> request completes. >> >> >> Regards, >> Daniel >> >> On 05/03/2012 03:18 PM, Benjamin Dreux wrote: >>> Hi >>> >>> I want to add a "loading" message in my app when stating a ajax call. >>> Here is how i implemeneted it >>> >>> var flash; >>> request.addListenerOnce("sending", function(){ >>> // open flash message with "loading" text >>> }); >>> request.addListenerOnce("completed",function(){ >>> // close flash message >>> }); >>> >>> But as i've seen it the message is not shown. But the code is executed. >>> The flash message is a tooltip. >>> >>> I assume that the message is queued to be redender, but close >>> (destroyed) before it actually shown. >>> Is there way to force the rendering of this message. >>> And is this a good idea to force this?? >>> >>> Regards >>> >> >> ------------------------------------------------------------------------------ >> Live Security Virtual Conference >> Exclusive live event will cover all the ways today's security and >> threat landscape has changed and how IT managers can respond. Discussions >> will include endpoint security, mobile security and the latest in malware >> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ >> _______________________________________________ >> qooxdoo-devel mailing list >> [email protected] >> https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel > > > ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ qooxdoo-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/qooxdoo-devel
