[Chameleon] Custom Query Widget

Eric Bridger eric at gomoos.org
Thu Jan 13 14:38:40 EST 2005


Paul,
This made perfect sense to me and was exactly what I needed!  Thank-you,
thank-you, thank-you.
My custom query widget is working perfectly now. I knew I should have
checked with you first.

Setting PRIORITY in my custom widgets was easy (which handled this case)
but can I pass a PRIORITY to an abitrary widget, e.g. XMLThemeLegend?
Would the syntax just be: priority="PRIORITY_MEDIUM".

Thanks again.

Eric


On Thu, 2005-01-13 at 07:43, Paul Spencer wrote:
> Eric,
> 
> I assume you are willing to write a widget for this, or modify an 
> existing one.  There are a couple of widgets in Chameleon that do 
> something similar, i.e. they change the map obj while the app is 
> executing.  The trick is mostly in timing, which is what widget 
> priorities are for :)
> 
> Note: Widgets are not supposed to use values gathered from ProcessURL 
> for drawing, they are supposed to wait until all widgets have finished 
> processing.  There have been some bugs related to this that I have fixed 
> as they were found, but it is possible that some widgets are still 
> violating this principle.
> 
> So, your widget can be set to either the highest priority (it gets run 
> first) or lowest (it gets run last).  Lowest will expose bugs related to 
> the note above, highest will avoid them.
> 
> My approach to this would be to have a highest priority widget, it can 
> do the query and then set the form variable used by the time widget.  As 
> long as the new query widget runs before the time widget, you should be 
> fine.  The time widget should see time coming in the various form 
> variables and update the layer sources as if the user had entered the 
> time themselves.
> 
> Don't know if that makes sense ... it does to me :)
> 
> Cheers,
> 
> Paul
 



More information about the Chameleon mailing list