At 5:25 PM +0100 2000/02/27, Christian Vandendorpe wrote:
>CategoryCreateList
>LstPopupList
>CategoryFreeList
>
>Looking at the Palm OS source code for CategoryCreateList I have traced the problem 
>to LstSetSelection. It seems that in OS < 3.5 LstSetSelection does some internal list 
>stuff but that's it. While in OS 3.5, LstSetSelection actually displays the selected 
>item on the screen (!!). This is the problem because then when LstPopupList get's 
>called, a copy of what's on the screen at the popup location is saved with 
>WinSaveBits and when the popup closes the screen is restored with WinRestoreBits but 
>this also restores the garbage that LstSetSelection displayed before the popup was 
>opened!

Comparing the LstSetSelection sources for 3.0 and 3.5, both draw the list if it's 
usable and visible (listP->attr.usable && listP->attr.visible). If there is a current 
selection (listP->currentItem != noListSelection), the selection is XORed in OS 
versions prior to 3.5, but it is drawn in OS version 3.5 (because color XOR looks 
bad). Perhaps that's the source of your trouble? Is the visible bit set in the list 
you pass to CategoryCreateList? It should not be marked visible until just before 
calling LstPopupList.

Regards,

Jim Schram
Palm Incorporated
Partner Engineering



-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palm.com/devzone/mailinglists.html

Reply via email to