|
@@ -382,6 +382,7 @@ namespace InABox.DynamicGrid
|
|
|
DataGrid.CellTapped += DataGrid_CellTapped;
|
|
|
DataGrid.CellDoubleTapped += DataGrid_CellDoubleTapped;
|
|
|
DataGrid.SelectionChanging += DataGrid_SelectionChanging;
|
|
|
+ DataGrid.SelectionChanged += DataGrid_SelectionChanged;
|
|
|
DataGrid.SelectionMode = GridSelectionMode.Extended;
|
|
|
DataGrid.SelectionUnit = GridSelectionUnit.Row;
|
|
|
DataGrid.CanMaintainScrollPosition = true;
|
|
@@ -631,6 +632,10 @@ namespace InABox.DynamicGrid
|
|
|
}
|
|
|
}
|
|
|
|
|
|
+ private void DataGrid_SelectionChanged(object? sender, GridSelectionChangedEventArgs e)
|
|
|
+ {
|
|
|
+ }
|
|
|
+
|
|
|
public bool IsReady { get; private set; }
|
|
|
|
|
|
public UIElement? Header
|
|
@@ -902,8 +907,7 @@ namespace InABox.DynamicGrid
|
|
|
return;
|
|
|
|
|
|
var row = GetRowFromIndex(e.RowColumnIndex.RowIndex);
|
|
|
- if (row is null)
|
|
|
- return;
|
|
|
+
|
|
|
e.ToolTip.Template = TemplateGenerator.CreateControlTemplate(
|
|
|
typeof(ToolTip),
|
|
|
() => toolTip.Invoke(col, row)
|
|
@@ -1294,9 +1298,13 @@ namespace InABox.DynamicGrid
|
|
|
|
|
|
private void DataGrid_KeyUp(object sender, KeyEventArgs e)
|
|
|
{
|
|
|
+ if (sender != DataGrid) return;
|
|
|
+
|
|
|
if (!bFilterVisible && !bSwallowKey && DataGrid.SelectedIndex > -1)
|
|
|
+ {
|
|
|
//Logger.Send(LogType.Information, "", String.Format("{0}: KeyUp -> {1}", this.GetType().EntityName(), SelectedRows.Length));
|
|
|
SelectItems(SelectedRows);
|
|
|
+ }
|
|
|
bSwallowKey = false;
|
|
|
|
|
|
if (IsSequenced)
|
|
@@ -1619,6 +1627,7 @@ namespace InABox.DynamicGrid
|
|
|
ApplyFilterStyle(newcol, true, true);
|
|
|
|
|
|
newcol.ShowToolTip = column.ToolTip != null;
|
|
|
+ newcol.ShowHeaderToolTip = column.ToolTip != null;
|
|
|
|
|
|
var style = new Style();
|
|
|
style.Setters.Add(new Setter(BackgroundProperty, new SolidColorBrush(Colors.Gainsboro)));
|
|
@@ -1687,7 +1696,7 @@ namespace InABox.DynamicGrid
|
|
|
newcol.AllowFiltering = column.Filters != null && column.Filters.Any();
|
|
|
newcol.AllowSorting = false;
|
|
|
newcol.FilterRowOptionsVisibility = Visibility.Collapsed;
|
|
|
- newcol.ShowToolTip = column.ToolTip != null;
|
|
|
+ newcol.ShowHeaderToolTip = column.ToolTip != null;
|
|
|
|
|
|
var style = new Style();
|
|
|
style.Setters.Add(new Setter(BackgroundProperty, new SolidColorBrush(Colors.Gainsboro)));
|
|
@@ -1726,6 +1735,7 @@ namespace InABox.DynamicGrid
|
|
|
newcol.AllowSorting = false;
|
|
|
newcol.FilterRowOptionsVisibility = Visibility.Collapsed;
|
|
|
newcol.ShowToolTip = false;
|
|
|
+ newcol.ShowHeaderToolTip = false;
|
|
|
|
|
|
var style = new Style();
|
|
|
style.Setters.Add(new Setter(BackgroundProperty, new SolidColorBrush(Colors.Gainsboro)));
|