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
380
ColumnSort on XamGrid with DragDropManager.DragSource does not work
posted
I have a XamGrid with a DragDropManager and the sort does not work.  
If I comment out the DragDropManager sort works again.
Is this a bug, and if so is there a work around?
Thanks,
-Mark
Code Below:
        <ig:XamGrid Grid.Row="1" x:Name="_endPoints" 
                    SelectedRowsCollectionChanged="_endPoints_SelectedRowsCollectionChanged"
                    ItemsSource="{Binding EndPoints}"  AutoGenerateColumns="False">
            <ig:DragDropManager.DragSource>
                <ig:DragSource IsDraggable="{Binding Source={StaticResource DataContextProxy}, Path=DataSource.IsEditMode, Converter={StaticResource NotBoolConverter}}" 
                               DragChannels="EndPoint"
                               DragStart="DragSource_DragStart" 
                               DragEnd="DragSource_DragEnd"  
                               Drop="DragSource_Drop">
                    <ig:DragSource.DragTemplate>
                        <DataTemplate x:Name="dragTemplate">
                            <ListBox Visibility="Visible" x:Name="dtStackPanel" ItemsSource="{Binding Path=Data}" Opacity=".5">
                                <ListBox.ItemTemplate>
                                    <DataTemplate>
                                        <StackPanel Orientation="Horizontal" Background="{StaticResource GreenGradientBrush}" Margin="-5">
                                            <TextBlock Width="150" FontSize="11" Style="{StaticResource NormalText}" Margin="5" Text="{Binding Name}" />
                                            <TextBlock Width="100" FontSize="11" Style="{StaticResource NormalText}" Margin="5" Text="{Binding IpAddress}"/>
                                        </StackPanel>
                                    </DataTemplate>
                                </ListBox.ItemTemplate>
                            </ListBox>
                        </DataTemplate>
                    </ig:DragSource.DragTemplate>
                    <ig:DragSource.CopyCursorTemplate>
                        <DataTemplate>
                            <Image Height="30" Width="30" Source="/ctConsole;Component/Assets/Images/rollover.png" />
                        </DataTemplate>
                    </ig:DragSource.CopyCursorTemplate>
                    <ig:DragSource.DropNotAllowedCursorTemplate>
                        <DataTemplate>
                            <Image Height="30" Width="30" Source="/ctConsole;Component/Assets/Images/critical.png" />
                        </DataTemplate>
                    </ig:DragSource.DropNotAllowedCursorTemplate>
                    <ig:DragSource.MoveCursorTemplate>
                        <DataTemplate>
                            <Image Height="30" Width="30" Source="/ctConsole;Component/Assets/Images/rollover.png" />
                        </DataTemplate>
                    </ig:DragSource.MoveCursorTemplate>
                </ig:DragSource>
            </ig:DragDropManager.DragSource>
            <ig:XamGrid.Columns>

                <ig:TemplateColumn Key="SecurityConfig" Width="175" 
                                       FilterColumnSettings="{StaticResource FilterColumnSettingsDefault}"
                                       Visibility="{Binding Source={StaticResource DataContextProxy}, Path=DataSource.PoliciesViewModel.SecurityGroupTreeViewModel.IsFolderSelected, Converter={StaticResource BoolToVisibilityConverter}}">
                    <ig:TemplateColumn.FilterEditorTemplate>
                        <DataTemplate>
                            <TextBox Text="{Binding Value, Mode=TwoWay}"/>
                        </DataTemplate>
                    </ig:TemplateColumn.FilterEditorTemplate>
                    <ig:TemplateColumn.HeaderTemplate>
                        <DataTemplate>
                            <TextBlock Text="Security Group" />
                        </DataTemplate>
                    </ig:TemplateColumn.HeaderTemplate>
                    <ig:TemplateColumn.ItemTemplate>
                        <DataTemplate>
                            <HyperlinkButton Click="NavigateSecurityGroup_Click">
                                <HyperlinkButton.Content >
                                    <TextBlock Text="{Binding SecurityConfig}" />
                                </HyperlinkButton.Content>
                            </HyperlinkButton>
                        </DataTemplate>
                    </ig:TemplateColumn.ItemTemplate>
                </ig:TemplateColumn>

                <ig:TextColumn Key="Name" Width="150" >
                    <ig:TextColumn.HeaderTemplate>
                        <DataTemplate>
                            <TextBlock Text="Endpoint" />
                        </DataTemplate>
                    </ig:TextColumn.HeaderTemplate>
                </ig:TextColumn>
                <ig:TextColumn Key="Status"  />
                <ig:TextColumn Key="Mode" >
                    <ig:TextColumn.HeaderTemplate>
                        <DataTemplate>
                            <TextBlock Text="Posture" />
                        </DataTemplate>
                    </ig:TextColumn.HeaderTemplate>
                </ig:TextColumn>
                <ig:TextColumn Key="OperatingSystem" >
                    <ig:TextColumn.HeaderTemplate>
                        <DataTemplate>
                            <TextBlock Text="OS" />
                        </DataTemplate>
                    </ig:TextColumn.HeaderTemplate>
                </ig:TextColumn>
                <ig:TextColumn Key="IpAddress" >
                    <ig:TextColumn.HeaderTemplate>
                        <DataTemplate>
                            <TextBlock Text="IP Address" />
                        </DataTemplate>
                    </ig:TextColumn.HeaderTemplate>
                </ig:TextColumn>
                <ig:TextColumn Key="AgentVersion" >
                    <ig:TextColumn.HeaderTemplate>
                        <DataTemplate>
                            <TextBlock Text="Agent Version" />
                        </DataTemplate>
                    </ig:TextColumn.HeaderTemplate>
                </ig:TextColumn>
                <ig:TextColumn  Key="EventTimeAsDateTime" IsReadOnly="True">
                    <ig:TextColumn.HeaderTemplate>
                        <DataTemplate>
                            <TextBlock Text="Last Update" />
                        </DataTemplate>
                    </ig:TextColumn.HeaderTemplate>
                </ig:TextColumn>
            </ig:XamGrid.Columns>
            <ig:ContextMenuService.Manager>
                <ig:ContextMenuManager ModifierKeys="None">
                    <ig:ContextMenuManager.ContextMenu>
                        <ig:XamContextMenu  Opening="XamContextMenu_Opening"/>
                    </ig:ContextMenuManager.ContextMenu>
                </ig:ContextMenuManager>
            </ig:ContextMenuService.Manager>
            <ig:XamGrid.FilteringSettings>
                <ig:FilteringSettings  AllowFiltering="FilterMenu" />
            </ig:XamGrid.FilteringSettings>
            <ig:XamGrid.ColumnMovingSettings>
                <ig:ColumnMovingSettings AllowColumnMoving="Indicator" />
            </ig:XamGrid.ColumnMovingSettings>
            <ig:XamGrid.ColumnChooserSettings>
                <ig:ColumnChooserSettings AllowHiddenColumnIndicator="True" AllowHideColumnIcon="True" />
            </ig:XamGrid.ColumnChooserSettings>
            <ig:XamGrid.SelectionSettings>
                <ig:SelectionSettings RowSelection="Multiple" CellClickAction="SelectRow"/>
            </ig:XamGrid.SelectionSettings>
            <ig:XamGrid.RowSelectorSettings>
                <ig:RowSelectorSettings Visibility="Collapsed" EnableRowNumbering="False"/>
            </ig:XamGrid.RowSelectorSettings>
            <ig:XamGrid.EditingSettings>
                <ig:EditingSettings 
                     AllowEditing="{Binding Source={StaticResource DataContextProxy}, Path=DataSource.IsEditMode, Converter={StaticResource BoolToAllowEditingConverter}}"  
                     IsMouseActionEditingEnabled="SingleClick" 
                     IsEnterKeyEditingEnabled="True" 
                     IsF2EditingEnabled="True" 
                     IsOnCellActiveEditingEnabled="False" />
            </ig:XamGrid.EditingSettings>
        </ig:XamGrid>
Parents Reply Children