Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
45
Content of Views gets toggled when they leave and re-enter the visible Tile-host area.
posted

Hi, we use the XamTilescontrol in our application and we saw strange behaviour with the content of the Tiles. When not all of the tiles are in the visual area scrollbars appear, that is correct, but when we use the scrollbar to view the tiles which are currently not in the view area sometimes the tile shows the wrong content. In that case I mean Tile 6 shows content of tile 1.

 

I will add a demo application where the problem is reproducible.

How to reproduce the problem :

1. Run the app

2. Resize the window so that you can see just 3 tiles on one row (of the 6 available).

3. Use the horizontal scrollbar that appears to watch the 6th tile and go back to the first.

4. Repeat step 3 until you see content of one tile in more tiles.

 

We have serious problems with that glitch :).

 

Thanks in advance,

 

Dave

InfragisticsTileProblem.rar
Parents
  • 4850
    Suggested Answer
    Offline posted

    Hi Dave,

    The problem is caused by the fact that by default we recycle containers (in this case the Tiles). Therefore to accomplish what you ar trying to do you need to do one of the following:

    1. in your derived OurTilesControl class override the ReuseContainerForNewItem virtual method and call your BindVisuals method.
    2. Or set the controls ItemContainerGenerationMode to something other than 'Recycle'.

    Either of these should solve the problem.

Reply Children
No Data