Browse Source
Add xmlns definitions, fix references & trim some warnings.
pull/2109/head
Jumar Macato
8 years ago
No known key found for this signature in database
GPG Key ID: B19884DAC3A5BF3F
8 changed files with
14 additions and
9 deletions
-
samples/ControlCatalog/Pages/DataGridPage.xaml
-
src/Avalonia.Controls.DataGrid/Collections/CollectionView.cs
-
src/Avalonia.Controls.DataGrid/DataGrid.cs
-
src/Avalonia.Controls.DataGrid/DataGridColumnHeader.cs
-
src/Avalonia.Controls.DataGrid/DataGridRows.cs
-
src/Avalonia.Controls.DataGrid/Primitives/DataGridDetailsPresenter.cs
-
src/Avalonia.Controls.DataGrid/Properties/AssemblyInfo.cs
-
src/Avalonia.Themes.Default/Avalonia.Themes.Default.csproj
|
|
|
@ -1,6 +1,7 @@ |
|
|
|
<UserControl xmlns="https://github.com/avaloniaui" |
|
|
|
xmlns:local="clr-namespace:ControlCatalog.Models;assembly=ControlCatalog" |
|
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"> |
|
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" |
|
|
|
x:Class="ControlCatalog.Pages.DataGridPage"> |
|
|
|
<UserControl.Resources> |
|
|
|
<local:GDPValueConverter x:Key="GDPConverter" /> |
|
|
|
</UserControl.Resources> |
|
|
|
|
|
|
|
@ -3360,7 +3360,7 @@ namespace Avalonia.Collections |
|
|
|
addIndex); |
|
|
|
|
|
|
|
// next check if we need to add an item into the current group
|
|
|
|
bool needsGrouping = false; |
|
|
|
// bool needsGrouping = false;
|
|
|
|
if (Count == 1 && GroupDescriptions.Count > 0) |
|
|
|
{ |
|
|
|
// if this is the first item being added
|
|
|
|
@ -3387,7 +3387,7 @@ namespace Avalonia.Collections |
|
|
|
// otherwise, we need to validate that it is within the current page.
|
|
|
|
if (PageSize == 0 || (PageIndex + 1) * PageSize > leafIndex) |
|
|
|
{ |
|
|
|
needsGrouping = true; |
|
|
|
//needsGrouping = true;
|
|
|
|
|
|
|
|
int pageStartIndex = PageIndex * PageSize; |
|
|
|
|
|
|
|
|
|
|
|
@ -746,11 +746,12 @@ namespace Avalonia.Controls |
|
|
|
|
|
|
|
static DataGrid() |
|
|
|
{ |
|
|
|
AffectsMeasure( |
|
|
|
AffectsMeasure<DataGrid>( |
|
|
|
ColumnHeaderHeightProperty, |
|
|
|
HorizontalScrollBarVisibilityProperty, |
|
|
|
VerticalScrollBarVisibilityProperty); |
|
|
|
PseudoClass(IsValidProperty, x => !x, ":invalid"); |
|
|
|
|
|
|
|
PseudoClass<DataGrid, bool>(IsValidProperty, x => !x, ":invalid"); |
|
|
|
|
|
|
|
ItemsProperty.Changed.AddClassHandler<DataGrid>(x => x.OnItemsPropertyChanged); |
|
|
|
CanUserResizeColumnsProperty.Changed.AddClassHandler<DataGrid>(x => x.OnCanUserResizeColumnsChanged); |
|
|
|
|
|
|
|
@ -340,7 +340,7 @@ namespace Avalonia.Controls |
|
|
|
&& OwningGrid.DataConnection.SortDescriptions != null) |
|
|
|
{ |
|
|
|
DataGrid owningGrid = OwningGrid; |
|
|
|
bool desending; |
|
|
|
|
|
|
|
AvaloniaSortDescription newSort; |
|
|
|
|
|
|
|
KeyboardHelper.GetMetaKeyState(inputModifiers, out bool ctrl, out bool shift); |
|
|
|
|
|
|
|
@ -2505,7 +2505,7 @@ namespace Avalonia.Controls |
|
|
|
double indent; |
|
|
|
for (int i = 0; i < groupLevelCount; i++) |
|
|
|
{ |
|
|
|
DataGridRowGroupHeader rowGroupHeader = null; |
|
|
|
//DataGridRowGroupHeader rowGroupHeader = null;
|
|
|
|
indent = DATAGRID_defaultRowGroupSublevelIndent; |
|
|
|
//if (i < RowGroupHeaderStyles.Count && RowGroupHeaderStyles[i] != null)
|
|
|
|
//{
|
|
|
|
|
|
|
|
@ -42,7 +42,7 @@ namespace Avalonia.Controls.Primitives |
|
|
|
|
|
|
|
public DataGridDetailsPresenter() |
|
|
|
{ |
|
|
|
AffectsMeasure(ContentHeightProperty); |
|
|
|
AffectsMeasure<DataGridDetailsPresenter>(ContentHeightProperty); |
|
|
|
} |
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
|
|
@ -9,4 +9,6 @@ using Avalonia.Metadata; |
|
|
|
[assembly: InternalsVisibleTo("Avalonia.DesignerSupport")] |
|
|
|
|
|
|
|
[assembly: XmlnsDefinition("https://github.com/avaloniaui", "Avalonia")] |
|
|
|
[assembly: XmlnsDefinition("https://github.com/avaloniaui", "Avalonia.Controls.DataGrid")] |
|
|
|
[assembly: XmlnsDefinition("https://github.com/avaloniaui", "Avalonia.Controls")] |
|
|
|
[assembly: XmlnsDefinition("https://github.com/avaloniaui", "Avalonia.Controls.Primitives")] |
|
|
|
[assembly: XmlnsDefinition("https://github.com/avaloniaui", "Avalonia.Controls.Collections")] |
|
|
|
|
|
|
|
@ -7,6 +7,7 @@ |
|
|
|
<ProjectReference Include="..\Avalonia.Animation\Avalonia.Animation.csproj" /> |
|
|
|
<ProjectReference Include="..\Avalonia.Base\Avalonia.Base.csproj" /> |
|
|
|
<ProjectReference Include="..\Avalonia.Controls\Avalonia.Controls.csproj" /> |
|
|
|
<ProjectReference Include="..\Avalonia.Controls.DataGrid\Avalonia.Controls.DataGrid.csproj" /> |
|
|
|
<ProjectReference Include="..\Avalonia.Input\Avalonia.Input.csproj" /> |
|
|
|
<ProjectReference Include="..\Avalonia.Interactivity\Avalonia.Interactivity.csproj" /> |
|
|
|
<ProjectReference Include="..\Avalonia.Layout\Avalonia.Layout.csproj" /> |
|
|
|
|