As far as I know the memory is allocated if the panel becomes visible for the first time. After that, the associated bitmaps will remain in texture memory, no matter if they are visible or not. In order to remove them from memory, you have to use a bmap_purge() instruction.