Steven Kirk
e3bf19a399
Update tests due to changes in #10803 .
3 years ago
Steven Kirk
2aca946a71
Respect single-select with IsSelected bindings.
Use the existing `UpdateSelection` methods to correctly respect the current `SelectionMode`.
3 years ago
Steven Kirk
487fe9ed77
Make TreeViewItem IsSelected bindings work.
3 years ago
Steven Kirk
191a835c6a
Make container IsSelected bindings work again.
Rather than using the `ISelectable` interface to communicate container selection from the `SelectingItemsControl` to the container, use the `SelectingItemsControl.IsSelected` attached property, setting it with `SetCurrentValue` so that bindings defined in a style or item container theme can override the selection. Required an extra virtual `ContainerForItemPreparedOverride` method on `ItemsControl`.
3 years ago
Steven Kirk
e609822311
Modernized some SelectingItemsControl tests.
And moved some of the tests that were specific to user interaction to `ListBoxTests` as `SelectingItemsControl` doesn't define user interactions.
3 years ago
Steven Kirk
39db10b345
Handle recycling control items inside containers.
Fixes #10825
3 years ago
Steven Kirk
670eea0977
Modernized ItemsControl tests.
3 years ago
Steven Kirk
124d318499
Handle unrealized focused element losing focus.
3 years ago
Steven Kirk
9f95bd9156
Recycle elements early when viewport is disjunct.
3 years ago
Steven Kirk
bc32c061e8
Added tests to detect scroll jumps.
3 years ago
Tom Edwards
b400a1f72d
Fixed children being attached to the visual or logical tree multiple times
3 years ago
Steven Kirk
6dc5eddfeb
Fix nullability issues.
3 years ago
Tom Edwards
2a5a5d229f
Fix tests
3 years ago
Tom Edwards
74f75b0525
Converted RangeBase to StyledProperty
Normalised ScrollViewer internal properties and bindings
3 years ago
Steven Kirk
6dd9106fe5
Don't layout invisible controls.
And fix unit tests that were relying on this behavior.
3 years ago
Steven Kirk
a28483252b
Make MaskedTextBox tests pass again.
They need a registered `IPlatformRenderInterface` and were only passing because `GlyphRunTests` was leaking one.
3 years ago
Steven Kirk
b7a249107b
Make data templates work again with MenuItem.
- `MenuItem` is a `HeaderedSelectingItemsControl` not a `HeaderedItemsControl` so need to separate logic for that case when preparing items
- Added `HeaderTemplate` to `HeaderedSelectingItemsControl `
- Tweaked logic for selecting header templates: parent's `ItemTemplate` should be used if set (cross-checked with WPF)
- Update menu templates to bind to menu item's `HeaderTemplate`
Fixes #10626
Fixes #10718
3 years ago
Steven Kirk
7bb6d06ac5
Added failing test for #10626 and #10718 .
3 years ago
Emmanuel Hansen
04c8b652c8
move clipboard to TopLevel
3 years ago
Steven Kirk
faf1d83950
Fix merge error.
3 years ago
Nikita Tsukanov
91e4bd00b6
Fixed more tests
3 years ago
Nikita Tsukanov
9d4f11a111
Fixed tests
3 years ago
Steven Kirk
c2b47db2b1
Added failing test for #10769 .
And adjust terminology in tests.
3 years ago
Steven Kirk
8c1d4fbbbf
Added failing test for treeview selection.
3 years ago
Steven Kirk
a3866201a4
Modernized TreeViewTests.
3 years ago
Dan Walmsley
fe1f9d4c77
add a failing unit test.
3 years ago
Nikita Tsukanov
0f4ed2a4b9
Updated tests to use IDispatcherImpl
3 years ago
amwx
a3c8210f2e
Add new tests
3 years ago
Nikita Tsukanov
968e61f649
Fixed tests, reintroduced Post with SendOrPostCallback, removed JobRunner
3 years ago
Nikita Tsukanov
6a99ca39f9
Implemented dispatcher that works like WPF one
3 years ago
Steven Kirk
7dbe277653
More lifecycle event tests with virtualization.
3 years ago
Steven Kirk
9d012fbb6b
Fix terminology.
3 years ago
Steven Kirk
ce2cd52964
Add lifecycle event tests with virtualization.
And fix index error in VirtualizingStackPanel.
3 years ago
Steven Kirk
791ea8beef
Added container lifecycle events.
Seems we weren't calling `ClearItemContainer` for `ItemIsOwnContainer` items in `PanelContainerGenerator`. Fixed that too.
3 years ago
Tom Edwards
86324dca77
Convert Text properties to StyledProperty
3 years ago
robloo
cc7656eecb
Rename ContextMenu.PlacementMode to ContextMenu.Placement
3 years ago
robloo
2eb04c2719
Rename Popup.PlacementMode to Popup.Placement
3 years ago
Steven Kirk
f8eceb4af9
Update usages of ItemsControl Items/ItemsSource.
- Use `ItemsSource` when appropriate
- When `Items` is appropriate, don't use the setter
3 years ago
Steven Kirk
183fed8985
Add more tests.
One failing.
3 years ago
Steven Kirk
9856711494
Don't modify logical tree in ItemsSource mode.
3 years ago
Steven Kirk
ba7e8a20b5
Added ItemsControl.ItemsSource.
`ItemsControl` now works more like WPF, in that there are separate `Items` and `ItemsSource` properties. For backwards compatibility `Items` can still be set, though the setter is deprecated. `Items` needed to be changed from `IEnumerable` to `IList` though.
3 years ago
Dan Walmsley
b2723d84be
Revert "try and catch issue with test."
This reverts commit 1d6fb2d960 .
3 years ago
Dan Walmsley
1d6fb2d960
try and catch issue with test.
3 years ago
Tom Edwards
81530c4231
Converted a variety of writeable DirectProperty definitions to StyledProperty
3 years ago
Julien Lebosquain
3791fa8a51
Don't add ItemsControl items to its panel logical children
3 years ago
Benedikt Stebner
0fc25da0dc
[TextBox] MoveEnd now correctly positions the caret before the line break
3 years ago
Steven Kirk
d7b6a8e97a
Added failing test for #10398 .
3 years ago
Steven Kirk
f745fe1788
Use simpler event args type.
The `PointerEnteredItem` and `PointerExitedItem` were using an obsolete API to create the event args. We don't need a `PointerEventArgs` anyway, just use `RoutedEventArgs`.
3 years ago
Steven Kirk
f87148dbbc
Add failing unit test for #10420 .
3 years ago
Steven Kirk
b92134c682
Added failing test for #10246 .
3 years ago