Create a gist now

Instantly share code, notes, and snippets.

@KooKiz /AdaptiveImage.cs Secret
Created Jan 12, 2016

What would you like to do?
namespace CustomControls
{
public class AdaptiveImage : ContentControl
{
public static readonly DependencyProperty SourceProperty = DependencyProperty.Register(
"Source",
typeof(AdaptiveImageSource),
typeof(AdaptiveImage),
new PropertyMetadata(null, OnSourceChanged));
public AdaptiveImageSource Source
{
get { return this.GetValue(SourceProperty) as AdaptiveImageSource; }
set { this.SetValue(SourceProperty, value); }
}
private static void OnSourceChanged(DependencyObject sender, DependencyPropertyChangedEventArgs e)
{
// TODO
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment