* Added unit test for AutoCompleteBox DataValidationErrors
- checks that when the TextBox control's Errors are bound to the parent AutoCompleteBox, they get updated correctly in both parent AutoCompleteBox control and TextBox control
* Fix issue with DataValidationErrors causing issues with AutoCompleteBox because of Bindings
- when binding a control's DataValidationErrors.Errors property to the same property of another control, the use of a static bool flag "s_overridingErrors" was preventing the control with the Binding from being updated correctly
- issue is resolved by replacing static bool flag with a private AttachedProperty<bool> in DataValidationErrors.cs
* Clean up Asserts in previous AutoCompleteBoxTests.cs changes
* fix: 17453 don't lose text selection when contextmenu opens on another control
* fix: 17453 don't effect other callers and move the check to FocusChanged method
* Added failing AutoCompleteBox test.
* Make sure that flags are reset if exits early.
Wrap everything in a `try`...`finally` block so that they get reset even on exception.
Applying styling in the constructor isn't a good idea as demonstrated by #8549..
Instead apply styling when showing a window, or if it's needed call `ApplyStyling` manually, e.g. in unit tests.
Fixes#8549
And implement the functionality in the content controls themselves. `ContentControlMixin` was too complex and even with its complexity had bugs (such as in #2821). By moving the functionality to the content controls there is some repeated code but it's much more straightforward.