Browse Source
Merge branch 'master' into fix/xaml-errors
pull/6020/head
Max Katz
5 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with
7 additions and
3 deletions
-
src/Avalonia.Controls/DateTimePickers/DatePicker.cs
-
src/Avalonia.Controls/DateTimePickers/TimePicker.cs
-
src/Windows/Avalonia.Win32/WindowImpl.CustomCaptionProc.cs
|
|
|
@ -2,6 +2,7 @@ |
|
|
|
using Avalonia.Controls.Primitives; |
|
|
|
using Avalonia.Controls.Shapes; |
|
|
|
using Avalonia.Controls.Templates; |
|
|
|
using Avalonia.Data; |
|
|
|
using Avalonia.Interactivity; |
|
|
|
using System; |
|
|
|
using System.Collections.Generic; |
|
|
|
@ -88,7 +89,8 @@ namespace Avalonia.Controls |
|
|
|
/// </summary>
|
|
|
|
public static readonly DirectProperty<DatePicker, DateTimeOffset?> SelectedDateProperty = |
|
|
|
AvaloniaProperty.RegisterDirect<DatePicker, DateTimeOffset?>(nameof(SelectedDate), |
|
|
|
x => x.SelectedDate, (x, v) => x.SelectedDate = v); |
|
|
|
x => x.SelectedDate, (x, v) => x.SelectedDate = v, |
|
|
|
defaultBindingMode: BindingMode.TwoWay); |
|
|
|
|
|
|
|
// Template Items
|
|
|
|
private Button _flyoutButton; |
|
|
|
|
|
|
|
@ -2,6 +2,7 @@ |
|
|
|
using Avalonia.Controls.Primitives; |
|
|
|
using Avalonia.Controls.Shapes; |
|
|
|
using Avalonia.Controls.Templates; |
|
|
|
using Avalonia.Data; |
|
|
|
using System; |
|
|
|
using System.Globalization; |
|
|
|
|
|
|
|
@ -44,7 +45,8 @@ namespace Avalonia.Controls |
|
|
|
/// </summary>
|
|
|
|
public static readonly DirectProperty<TimePicker, TimeSpan?> SelectedTimeProperty = |
|
|
|
AvaloniaProperty.RegisterDirect<TimePicker, TimeSpan?>(nameof(SelectedTime), |
|
|
|
x => x.SelectedTime, (x, v) => x.SelectedTime = v); |
|
|
|
x => x.SelectedTime, (x, v) => x.SelectedTime = v, |
|
|
|
defaultBindingMode: BindingMode.TwoWay); |
|
|
|
|
|
|
|
// Template Items
|
|
|
|
private TimePickerPresenter _presenter; |
|
|
|
|
|
|
|
@ -117,7 +117,7 @@ namespace Avalonia.Win32 |
|
|
|
{ |
|
|
|
var visual = window.Renderer.HitTestFirst(position, _owner as Window, x => |
|
|
|
{ |
|
|
|
if (x is IInputElement ie && !ie.IsHitTestVisible) |
|
|
|
if (x is IInputElement ie && (!ie.IsHitTestVisible || !ie.IsVisible)) |
|
|
|
{ |
|
|
|
return false; |
|
|
|
} |
|
|
|
|