Marko Prosen
3 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
1 additions and
1 deletions
-
src/Avalonia.Controls/DateTimePickers/DateTimePickerPanel.cs
|
|
|
@ -406,7 +406,7 @@ namespace Avalonia.Controls.Primitives |
|
|
|
/// </summary>
|
|
|
|
public void ScrollDown(int numItems = 1) |
|
|
|
{ |
|
|
|
var scrollHeight = _extent.Height - Viewport.Height; |
|
|
|
var scrollHeight = Math.Max(Extent.Height - ItemHeight, 0); |
|
|
|
var newY = Math.Min(Offset.Y + (numItems * ItemHeight), scrollHeight); |
|
|
|
Offset = new Vector(0, newY); |
|
|
|
} |
|
|
|
|