I currently have two rows of 4 SlideHubTiles. They look great, except that all the slides happen in unison. This looks very weird, so I'm wondering what the recommended way is to stagger them so that they all slide at different, seemingly random, times?
Thanks!
5 Answers, 1 is accepted
Thanks for writing.
You have to set the UpdateInterval property of the tiles to different values. You can do that easily with the Random class.
Victor
the Telerik team
Won't that result in the various tiles updating at different rates? I was thinking I could use the IsFrozen property somehow, in conjunction with a background thread that loops through all the tiles, unfreezing them at random intervals.
Essentially, the effect I'm going for is I want the phase of each tile to be different, not its frequency.
Thanks for writing.
Setting IsFrozen property randomly will change the frequency of the updates. If you generate random update intervals the effect will be the same. The animations themselves will not change speed, only the transitions from state to state will change frequency.
If you want the tiles to update at the exact same time, but have different states displayed, you should simply unfreeze the tiles, one by one, at each update interval step. You can do so with DispatcherTimer for example.
Victor
the Telerik team
Is there a way to know what the tile is currently displaying? What I'm doing is basically picking a random tile and unfreezing it. I want to freeze it again once it has done one loop through all the slides. Then I can pick another random one to unfreeze and so forth.
Thanks for writing.
I am afraid that the hub tiles do not expose details about their visual states. You can inherit from the tile you are using and gain access to its states enumerator. It will provide the current state of the tile.
Victor
the Telerik team