Example #1
0
        /*
         * Link up the Host to the Target and initialize but do not start the timer
         * */
        public void BindToTarget(LayoutToLayoutTarget t)
        {
            Target          = t;
            t.Host          = this;
            translation     = new TranslateTransform(0, 0);
            RenderTransform = translation;

            Refresher          = new DispatcherTimer();
            Refresher.Interval = TimeSpan.FromMilliseconds(timeSpan);
            Refresher.Tick    += OnAnimStateInvalidated;

            UpdateFromTarget();
        }
Example #2
0
 /*
  * Break the cyclical reference
  * */
 public void ReleaseFromTarget()
 {
     Target.Host = null;
     Target = null;
 }
Example #3
0
        /*
         * Link up the Host to the Target and initialize but do not start the timer
         * */
        public void BindToTarget(LayoutToLayoutTarget t)
        {
            Target = t;
            t.Host = this;
            translation = new TranslateTransform(0, 0);
            RenderTransform = translation;

            Refresher = new DispatcherTimer();
            Refresher.Interval = TimeSpan.FromMilliseconds(timeSpan);
            Refresher.Tick += OnAnimStateInvalidated;

            UpdateFromTarget();
        }
Example #4
0
 /*
  * Break the cyclical reference
  * */
 public void ReleaseFromTarget()
 {
     Target.Host = null;
     Target      = null;
 }