mirror of
https://github.com/ClemensFischer/XAML-Map-Control.git
synced 2026-04-08 07:55:13 +00:00
Removed BindingHelper
This commit is contained in:
parent
8bb7dc3eb3
commit
3d275cd924
8 changed files with 51 additions and 74 deletions
|
|
@ -5,9 +5,11 @@
|
|||
#if UWP
|
||||
using Windows.UI.Xaml;
|
||||
using Windows.UI.Xaml.Controls;
|
||||
using Windows.UI.Xaml.Data;
|
||||
#else
|
||||
using Microsoft.UI.Xaml;
|
||||
using Microsoft.UI.Xaml.Controls;
|
||||
using Microsoft.UI.Xaml.Data;
|
||||
#endif
|
||||
|
||||
namespace MapControl
|
||||
|
|
@ -61,15 +63,18 @@ namespace MapControl
|
|||
//
|
||||
if (Background == null)
|
||||
{
|
||||
SetBinding(BackgroundProperty, parentMap.CreateBinding(nameof(Background)));
|
||||
SetBinding(BackgroundProperty,
|
||||
new Binding { Source = parentMap, Path = new PropertyPath(nameof(Background)) });
|
||||
}
|
||||
if (Foreground == null)
|
||||
{
|
||||
SetBinding(ForegroundProperty, parentMap.CreateBinding(nameof(Foreground)));
|
||||
SetBinding(ForegroundProperty,
|
||||
new Binding { Source = parentMap, Path = new PropertyPath(nameof(Foreground)) });
|
||||
}
|
||||
if (BorderBrush == null)
|
||||
{
|
||||
SetBinding(BorderBrushProperty, parentMap.CreateBinding(nameof(Foreground)));
|
||||
SetBinding(BorderBrushProperty,
|
||||
new Binding { Source = parentMap, Path = new PropertyPath(nameof(Foreground)) });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue