FS#2607 - [Patch] two minor fixes for filtering

Attached to Project: OpenTTD
Opened by Manuel Wolf (Roujin) - Friday, 06 February 2009, 13:40 GMT
Last edited by Remko Bijker (Rubidium) - Friday, 06 February 2009, 18:00 GMT
Type Bug
Category Interface
Status Closed
Assigned To No-one
Operating System All
Severity Low
Priority Normal
Reported Version trunk
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No


This patch fixes two minor bugs wrt. filtering:

1) (about GUILists in general)
bool Filter(FilterFunction *decide, F filter_data) did not return what was stated in comment ( * @return true if the list has been altered by filtering)

2) (about filtering in the content list window)
void FilterContentList() did something useless (iterate through whole list without doing anything). Now it properly updates the list position of the selected item and if the item was filtered out, sets to NULL.
This means that the currently selected item doesn't always get deselected when filtering, like it does right now.
This task depends upon

Closed by  Remko Bijker (Rubidium)
Friday, 06 February 2009, 18:00 GMT
Reason for closing:  Fixed
Additional comments about closing:  In r15377.