I want to add an apply button to the end of the "add new item" button when the NewRowPosition is set to e.g. Top.
After investigating which controls are involved, I tried to override the default style of DataCellsPresenter but the ItemsPresenter there seems to give me headache. Haven't used ItemsPresenter before so maybe the behavior is normal or it's modified elsewhere in your code.
Here's my modified style:
<Style x:Key="customDataCellsPresenter" TargetType="{x:Type telerik:DataCellsPresenter}"> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type telerik:DataCellsPresenter}"> <Grid> <Grid> <Grid.ColumnDefinitions> <ColumnDefinition Width="*"/> <ColumnDefinition Width="Auto"/> </Grid.ColumnDefinitions> <ItemsPresenter Grid.Column="0"/> <Button Grid.Column="1">Click Me!</Button> </Grid> <telerik:FrozenColumnsSplitter x:Name="PART_FrozenColumnsSplitter" telerik:DragDropManager.AllowDrag="True" telerik:DragDropManager.AllowCapturedDrag="True" Cursor="SizeWE" telerik:TouchManager.DragStartTrigger="TapHoldAndMove" HorizontalAlignment="Left" IsTabStop="False" Stylus.IsFlicksEnabled="False" Stylus.IsPressAndHoldEnabled="False"> <telerik:StyleManager.Theme> <telerik:Windows8TouchTheme/> </telerik:StyleManager.Theme> </telerik:FrozenColumnsSplitter> </Grid> </ControlTemplate> </Setter.Value> </Setter> <Setter Property="IsTabStop" Value="False"/> <Setter Property="ItemsPanel"> <Setter.Value> <ItemsPanelTemplate> <telerik:GridViewCellsPanel IsItemsHost="True"/> </ItemsPanelTemplate> </Setter.Value> </Setter> <Setter Property="SnapsToDevicePixels" Value="True"/> </Style>
The ItemsPresenter seem to span over the button. I.e., the button is not visible. If I excplicitely change column's width from * to 128, the button is shown and the ItemsControl is smaller, but it is clipped after 128 pixels.
Is there another way to add a button to the end of the new item button? I want the user to be able to use the grid with only touch screen (i.e. no physical keyboard available). A cancel button would be needed also.
The optimal solution would be if the user taps elsewhere on the screen (not just the RadGridView control) but there's only one button on the screen ("Back") so that won't do. I.e., no other controls to transfer the focus to. Propably needs some sort of "global" click/tap listener and hit test class...
