Opened 16 years ago

Closed 15 years ago

Last modified 15 years ago

#268 closed enhancement (fixed)

improvements to getWidget methods in widget manager

Reported by: dylan Owned by: sjmiles
Priority: high Milestone:
Component: Widgets Version: 0.2
Keywords: Cc:
Blocked By: Blocking:


Some useful additions to the getWidget methods:

getWidgetsByFilter: add a second param that is a boolean, when set to true, it would just return the first widget that matches the unaryFunc (helps performance when you just want the first widget)... perhaps we also want a way to specify searching in reverse order of the widget list when using this.

getWidgetsByPropertyValue: a method with params propertyName, propertyValue, and a boolean... sort of like getting an element by css class, and the boolean would determine whether to return all or just one.



Change History (4)

comment:1 Changed 16 years ago by sjmiles

Milestone: 0.3release0.4
Owner: changed from anonymous to sjmiles

I enhanced getWidgetsByFilter as requested: if second param is true, the function either returns the first widget reference it finds or NULL. Otherwise it returns an array as before.

The other enhancements I'm punting to 0.4 (unless rebuked by Dylan).

comment:2 Changed 15 years ago by sjmiles

I'm not convinced the other suggsted methods are useful enough to warrant inclusion. Would request some discussion on devs list before undertaking.

comment:3 Changed 15 years ago by sjmiles

Resolution: fixed
Status: newclosed

I'm closing this for now. Please re-open if there is consensus that additional search methods should be included in the lib.

comment:4 Changed 15 years ago by (none)

Milestone: 0.4

Milestone 0.4 deleted

Note: See TracTickets for help on using tickets.