using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace SamplesCommon
{
    public partial class SamplesHeader : UserControl
    {
        public SamplesHeader()
        {
            InitializeComponent();
        }


        public string Text
        {
            get { return (string)GetValue(TextProperty); }
            set { SetValue(TextProperty, value); }
        }

        // Using a DependencyProperty as the backing store for Text.  This enables animation, styling, binding, etc...
        public static readonly DependencyProperty TextProperty =
            DependencyProperty.Register("Text", typeof(string), typeof(SamplesHeader), new PropertyMetadata(TextChanged));


        private static void TextChanged(DependencyObject sender, DependencyPropertyChangedEventArgs args) 
        {
            SamplesHeader control = sender as SamplesHeader;
            control.controlname_reflect.Text = args.NewValue.ToString();
            control.controlname.Text = args.NewValue.ToString();
        }
    }
}
