Mantis - tweak
Viewing Issue Advanced Details
1155 Any feature always 05-13-05 12:49 05-13-05 20:31
bernd  
 
normal  
feedback  
open  
none    
none  
0001155: CTabButtonList value always nil (CList in general)
the value of such a list isn't sychroniced with the selection, like described in the class comment.
In general all CLists should behave in that way, that the value of a list hold the current selection. that makes is easier to set a list as a player and vice versa.
DropdownLists have already such a behavior.
Adding following or similar two methods to CList resolves the problem:
onSelectionChanged
    <on: cursorChanged>
    self value: self selection

onValueChanged

    self selection: self value

Notes
(0001482)
andreas   
05-13-05 20:31   
I've changed this to a feature request since it's not a bug in the sense of the word. I'm somewhat hesitent about changing this since it seems to me that a valid alternative for the lists value would be the items of the list iself. Given that there are multiple valid interpretations as for what a list's value represents it seems to me that hard-coding a single interpretation for *all* lists is problematic.