Java Virtal Machine.net

[ News ] rss

February 01, 2011

Mark Wielaard: New GPG key. Finally created a new GPG key using gnupg. The old one was a DSA/1024 bits one and 8 years old. The new one is a RSA/2048 bits one. I will use the new one in the future to sign any release tarballs I might create. pub 2048R/57816A6A 2011-01-29 Key f...

More »

February 01, 2011

Andrew Hughes: [SECURITY] IcedTea6 1.7.8, 1.8.5, 1.9.5 Released!. We are pleased to announce a new set of security releases, IcedTea6 1.7.8, IcedTea6 1.8.5 and IcedTea6 1.9.5. This update contains the following security updates: The IcedTea project provides a harness to build the source code from OpenJDK6 u...

More »

November/2024
SunMonTueWedThuFriSat
     12
3456789
10111213141516
17181920212223
24252627282930
       

[ Archives News
for 'Java Technology' ]

home > news > java technology > busy status indicator with jsf 2

Busy status indicator with JSF 2

I've had a few requests on how to write a busy status indicator - you know, the little spinning ball that's there while an Ajax call is active, and which goes away once the request is complete. So, I spent about two hours today, and did just that - including putting it into a component so it's reusable. As usual, it involved no Java, and only a minimal amount of JavaScript. First, I needed an animated gif for a spinning image - there were a number at http://mentalized.net/activity-indicators - I just picked one. They're all in the public domain, and there are other sites which offer similar animated gif spinners. After that, I tried to imagine what it would look like in the using page. Something like this seemed appropriate: 1 6 7 Busy Busy 8 9 10 11 12 13 14 15 16 17 18 On line 13, you see a component, busystatus, with a single attribute, "for", which is pointing at the rendered ID of the component I want to monitor. Otherwise, it's a straightforward JSF Ajax app - Ajaxify the "in" component, write to the the "out" component. I had to use the rendered ID (busyForm:in) rather than the JSF id (in), because there was no easy way to do ID resolution inside the component, but we've had to deal with that often enough at this point that the difference shouldn't be too confusing. We...


Date: September, 02 2009
Url: http://www.java.net/blog/driscoll/archive/2009/09/02/busy-status-indicator-jsf-2


Others News

©2002-2019Java-Virtual-Machine.net it | website design software | bootstrap modal popup | free bootstrap template | css slider