BlockUI / BlockPanel summary

Community Driven Extensions Project
Post Reply
mkienenb
Posts: 123
Joined: 03 Aug 2012, 04:42
Location: Elmira, NY
Contact:

31 Aug 2012, 20:04

UP to this point, we have been using custom java code in each a4j:support's on[event] and oncomplete attribute to block events and visually indicate that events are blocked.

Code: Select all

     event="onclick" 
     onclick="process();" 
     oncomplete="processStop();"
So I'm interested in p:blockUI, pe:blockUI, and pe:blockPanel

However, after reading every reference that a search on BlockUI turned up, it's still not 100% clear what the differences are.

It appears that pe:blockUI also blocks keys but not every kind of ajax request, and also allows you to specify blocking only certain kinds of events, although it's unclear whether that means we're blocking everything only when certain events are initiated, or if once we start blocking (on any event), we are only stopping certain events during blocking.

p:blockUI appears to be a much more limited subset of pe:blockUI functionality.

Internally, p:blockUI was written from scratch while pe:blockUI uses JQuery blocking infrastructure.

pe:blockPanel appears to be a convenience component that blocks everything outside of a panel allowing modal panel behavior. Basically a replacement strategy for rich:modalPanel.

Do I have this right?
Mike Kienenberger
Myfaces 2.1.14, Primefaces-5.3

tandraschko
PrimeFaces Core Developer
Posts: 3699
Joined: 03 Dec 2010, 14:11
Location: Bavaria, DE
Contact:

31 Aug 2012, 21:25

Absolutely right.

The only difference that i see, is that rich:modalPanel is more like an modal p:dialog.
BlockPanel will be renamed to spotlight later and is more like an inverse blockUI.
Thomas Andraschko

PrimeFaces | PrimeFaces Extensions

Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE

Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko

mkienenb
Posts: 123
Joined: 03 Aug 2012, 04:42
Location: Elmira, NY
Contact:

31 Aug 2012, 21:46

Can you explain the use of the BlockUI event attribute?

Does <pe:blockUI event="click"> mean that only click events are blocked? Or does it mean that everything is blocked once something is clicked?

The documentation isn't clear to me:

event - Name(s) of one or several accepted events. Several events should be defined as space or comma separated list.
Mike Kienenberger
Myfaces 2.1.14, Primefaces-5.3

tandraschko
PrimeFaces Core Developer
Posts: 3699
Joined: 03 Dec 2010, 14:11
Location: Bavaria, DE
Contact:

31 Aug 2012, 21:49

it will only block for the "click" event. If you use

event="sort,filter"

then only sort and filter behaviors will block.
Thomas Andraschko

PrimeFaces | PrimeFaces Extensions

Apache Member | OpenWebBeans, DeltaSpike, MyFaces, BVal, TomEE

Sponsor me: https://github.com/sponsors/tandraschko
Blog: http://tandraschko.blogspot.de/
Twitter: https://twitter.com/TAndraschko

User avatar
Oleg
Expert Member
Posts: 3803
Joined: 02 Oct 2009, 09:41
Location: Germany, Black Forest

03 Sep 2012, 23:28

Yes, Thomas described it right. "event" specifies events to be considered for blocking.

By the way, pe:blockPanel will be renamed to pe:spotlight - inspired by Spotlight in Ext JS 4.0.I will start to use this component too in order to end CDI conversion at right time point in wizard-like scenarios.
PrimeFaces Cookbook (2. edition): http://ova2.github.io/primefaces-cookbook/ Learning Angular UI Development with PrimeNG: https://github.com/ova2/angular-develop ... th-primeng Blog: https://medium.com/@OlegVaraksin

mkienenb
Posts: 123
Joined: 03 Aug 2012, 04:42
Location: Elmira, NY
Contact:

04 Sep 2012, 18:37

Code: Select all

event - Name(s) of one or several accepted events. Several events should be defined as space or comma separated list.
How does this sound as a documentation rewrite? I'm guessing on the default.

Code: Select all

event - Name(s) of one or more events which will be blocked.  Multiple events should be defined as a space- or comma-separated list. By default, all events are blocked
Mike Kienenberger
Myfaces 2.1.14, Primefaces-5.3

User avatar
Oleg
Expert Member
Posts: 3803
Joined: 02 Oct 2009, 09:41
Location: Germany, Black Forest

04 Sep 2012, 18:48

events which will be blocked ...
sounds strange but I can consider this during BlockUI update. I plan to add new features to BlockUI in 0.7.0.
PrimeFaces Cookbook (2. edition): http://ova2.github.io/primefaces-cookbook/ Learning Angular UI Development with PrimeNG: https://github.com/ova2/angular-develop ... th-primeng Blog: https://medium.com/@OlegVaraksin

Post Reply

Return to “Extensions”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 4 guests