Browse Source
When ClipValueToMinMax=false and the user enters an out-of-range value then tabs away (UpdateSourceTrigger=LostFocus), the control was silently truncating digits to bring the value within Min/Max range. For example, with Max=20000, typing 123456 would set the VM property to 12345 instead of reverting to the original valid value. Root cause: The intermediate valid values typed (e.g. 12345) were being committed to the internal Value property during typing. On LostFocus, when the final value (123456) was out of range, the text was reverted to the last committed intermediate value instead of the pre-edit value. Fix: Save the initial Value on focus gain (_initialValueOnFocus), and restore it in the SyncTextAndValueProperties catch block when ClipValueToMinMax=false and the user is not actively typing. Fixes #1801pull/1809/head
1 changed files with 945 additions and 930 deletions
File diff suppressed because it is too large
Loading…
Reference in new issue