Windows8TouchTheme

4 posts, 0 answers
  1. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 04 Mar 2013 Link to this post

    Hi,

    I am using the following to define a GridView Column

    <telerik:GridViewDataColumn 
    DataMemberBinding="{Binding IsSelected}"
            IsFilterable="False"
            Header="">
            <telerik:GridViewDataColumn.CellTemplate>
                <DataTemplate>
                    <CheckBox  IsChecked="{Binding IsSelected, Mode=TwoWay}" 
                               Checked="IsSelected_Checked" 
                               Unchecked="IsSelected_Unchecked"/>
                     </DataTemplate>
            </telerik:GridViewDataColumn.CellTemplate>

    </telerik:GridViewDataColumn>

    The default theme and the Windows7 theme works as expected but the Windows8Theme has the following behavior. I have to hit the screen to the right of the checkbox to check the item and when I put the mouse directly on the checkbox I get the sizing icon.  I assume it has something to due with the fact that the CheckBox is a Windows control?

    I originally defined the column as telerik:GridViewCheckBoxColumn but that did not provide me with Checked and Unchecked events.  I then went to the above code which I got from the forum.  It seems to me that the telerik:GridViewCheckBoxColumn should provide the checked events otherwise why have it?  When and  if its decided to make a change to telerik:GridViewCheckBoxColumn for the checked events I would also suggest that you provide a property to not dim the checkbox whether the row is selected or not.  

    Thanks
    Rich


    :
  2. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 05 Mar 2013 Link to this post

    Hi Richard,

    I tried to reproduce the issue with Windows8Theme, but I am not quite sure what is the exact behavior that you have on your side. What is the sizing icon that you get, do you get it when clicking directly on the CheckBox ?
    Considering the events you require from GridViewCheckBoxColumn, the idea of the columns is not to provide events since it is used for editing a property and that change can be traced in the setter of the corresponding property. As for the selection, we have such specific column - GridViewSelectColumn that keeps track of the selection state of the row. 
     

    Kind regards,
    Maya
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  3. Richard Harrigan
    Richard Harrigan avatar
    235 posts
    Member since:
    Nov 2009

    Posted 05 Mar 2013 Link to this post

    Hi Maya,

    I tried to send a .zip file of a test project but it tells me its the wrong format, It also said it was to big. (5.37 MB).  I then tried to attach the xaml and cs files but also invalid format. 

    So I am going to include the xaml an cd file in the body of the post.  Can you tell me how I can send you a zipped project?

    I am using the following:

    Visual Studio 12 Express - Update 1
    Telerik Controls
       Version: 2013.1.220.40
       RT Version v4.0.30319

    Thanks
    Rich

    using System;

    using System.Collections.Generic;

    using System.Collections.ObjectModel;

    using System.Linq;

    using System.Text;

    using System.Threading.Tasks;

    using System.Windows;

    using System.Windows.Controls;

    using System.Windows.Data;

    using System.Windows.Documents;

    using System.Windows.Input;

    using System.Windows.Media;

    using System.Windows.Media.Imaging;

    using System.Windows.Navigation;

    using System.Windows.Shapes;

    using Telerik.Windows.Controls;

    namespace WpfApplication1

    {

    /// <summary>

    /// Interaction logic for MainWindow.xaml

    /// </summary>

    public partial class MainWindow : Window

    {

    ObservableCollection<ColumnInfo> Columns = new ObservableCollection<ColumnInfo>();

    public MainWindow()

    {

    StyleManager.ApplicationTheme = new Windows8TouchTheme();

    InitializeComponent();

    for (Int32 i = 0; i < 10; i++)

    {

    ColumnInfo columnInfo = new ColumnInfo();

    columnInfo.FullTableName = "FullTableName" + i.ToString();

    columnInfo = new ColumnInfo();

    columnInfo.IsSelected = false;

    columnInfo.ColumnName = "ColumnName" + i.ToString();

    Columns.Add(columnInfo);

    }

    radGridViewColumns.ItemsSource = Columns;

    }

    private void IsSelected_Checked(object sender, RoutedEventArgs e)

    {

    }

    private void IsSelected_Unchecked(object sender, RoutedEventArgs e)

    {

    }

    }

    #region ColumnInfo

    public partial class ColumnInfo

    {

    public string FullTableName;

    public bool IsSelected { get; set; }

    public string ColumnName { get; set; }

    }

    #endregion ColumnInfo

    }



    ========================================================================

    <Window x:Class="WpfApplication1.MainWindow"

    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"

    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"

    xmlns:telerik="http://schemas.telerik.com/2008/xaml/presentation"

    Title="MainWindow" Height="350" Width="525">

    <Grid>

    <telerik:RadGridView

    Name="radGridViewColumns"

    ShowGroupPanel="False"

    AutoGenerateColumns="False"

    RowIndicatorVisibility="Collapsed">

    <telerik:RadGridView.Columns>

    <telerik:GridViewDataColumn

    DataMemberBinding="{Binding IsSelected}"

    IsFilterable="False"

    Header="">

    <telerik:GridViewDataColumn.CellTemplate>

    <DataTemplate>

    <CheckBox IsChecked="{Binding IsSelected, Mode=TwoWay}"

    Checked="IsSelected_Checked"

    Unchecked="IsSelected_Unchecked"/>

    </DataTemplate>

    </telerik:GridViewDataColumn.CellTemplate>

    </telerik:GridViewDataColumn>

    <telerik:GridViewDataColumn

    IsFilterable="False"

    Name="ColumnName"

    Header="Column Name"

    DataMemberBinding="{Binding ColumnName}" />

    </telerik:RadGridView.Columns>

    </telerik:RadGridView>

    </Grid>

    </Window>



  4. Maya
    Admin
    Maya avatar
    4062 posts

    Posted 06 Mar 2013 Link to this post

    Hi Richard,

    Generally, you can attach zip files only in a support ticket and it should be up to 20MB. If possible, try opening a support ticket and send us the sample you mentioned above. 

    Greetings,
    Maya
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top