I have an ItemsControl (RadTileList) as the root of a UserControl.
The Items that are loaded by Caliburn are supposed to be Tiles, but they are 'wrapped' in a UserControl before they are added to the RadTileList. This is causing strange effects like having a 'Tile' in a 'Tile' which ends up in several tiles when you start moving the tiles...
RadTileList:
<
Grid
>
<
telerik:RadTileList
x:Name
=
"Items"
>
<
telerik:RadTileList.ItemTemplate
>
<
DataTemplate
>
<
ContentControl
cal:View.Model
=
"{Binding}"
></
ContentControl
>
</
DataTemplate
>
</
telerik:RadTileList.ItemTemplate
>
</
telerik:RadTileList
>
</
Grid
>
In a UserControl, representing the tile:
<
telerik:Tile
TileType
=
"Quadruple"
>
<
TextBlock
>My contacts</
TextBlock
>
</
telerik:Tile
>
Did someone got this Telerik/Caliburn scenario working?
Thanks,
Peter
6 Answers, 1 is accepted
Can someone help?.
Thanks
Generally, Tile is a ContentControl on its own. Can you try reproducing the same behavior without working with Caliburn ? Do you get the same exception ? What is the exact way you see a tile ? What does it mean a tile in a tile ? Probably an image attached will be helpful.
Maya
Telerik
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
- Create new project
- Create user control:
<
UserControl
x:Class
=
"RadTileList.UserControlContainsTileAsRoot"
xmlns:telerik
=
"http://schemas.telerik.com/2008/xaml/presentation"
mc:Ignorable
=
"d"
d:DesignHeight
=
"300"
d:DesignWidth
=
"300"
>
<
telerik:Tile
>
<
TextBlock
>Hello world</
TextBlock
>
</
telerik:Tile
>
</
UserControl
>
- Change MainWindow
<
Window
x:Class
=
"RadTileList.MainWindow"
xmlns:telerik
=
"http://schemas.telerik.com/2008/xaml/presentation"
xmlns:radTileList
=
"clr-namespace:RadTileList"
Title
=
"MainWindow"
Height
=
"318"
Width
=
"1002"
>
<
Grid
>
<
telerik:RadTileList
>
<
telerik:Tile
>Tile 1</
telerik:Tile
>
<
telerik:Tile
>Tile 2</
telerik:Tile
>
<
radTileList:UserControlContainsTileAsRoot
></
radTileList:UserControlContainsTileAsRoot
>
</
telerik:RadTileList
>
</
Grid
>
</
Window
>
Effect2 is when i move the 'inner tile'.
It seems that the RadTileList cannot deal with 'UserControls'. Caliburn wraps the Tiles in a UserControl before they are added. Does someone has experience with preventing the 'wrap'?
Best regards,
Peter
Indeed, you are absolutely right. I have tested the behavior in a simple project and it is easily reproducible. I have also tested the scenario with the binaries that are about to be released with our Q3 2013 version and it behaves a bit better - all tiles are correctly rendered and reordering them does not result in the image you sent. The only thing not working correctly ( that I managed to find in some minutes testing) is selection. I will definitely improve the behavior, but unfortunately it will not be available for the upcoming release since there will be no time for extensive testing.
Will it be possible to clarify what the result you want to get is ? Is there anything more specific that you require and cannot be accomplished by just setting the content of a Tile ?
Maya
Telerik
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
There is still another problem.
If you set a non-default TileType, it is not applied.
<
UserControl
x:Class
=
"RadGridView_WPF_AR_1.UserControl1"
xmlns:telerik
=
"http://schemas.telerik.com/2008/xaml/presentation"
mc:Ignorable
=
"d"
d:DesignHeight
=
"300"
d:DesignWidth
=
"300"
>
<
telerik:Tile
TileType
=
"Quadruple"
>
<
TextBlock
>Hello world</
TextBlock
>
</
telerik:Tile
>
</
UserControl
>
This results in a TileType 'Double' instead of Quadruple...
Best regards,
Peter
Thank you for the additional info. I will investigate the issue further. Let me know in case you encounter any other issues.
Maya
Telerik
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>