public void Dispose()
        {
            var bus = ServiceContainer.Resolve <MessageBus> ();

            if (propertyTracker != null)
            {
                propertyTracker.Dispose();
                propertyTracker = null;
            }
            if (subscriptionSettingChanged != null)
            {
                bus.Unsubscribe(subscriptionSettingChanged);
                subscriptionSettingChanged = null;
            }
            if (timeEntryManager != null)
            {
                timeEntryManager.PropertyChanged -= OnActiveTimeEntryManagerPropertyChanged;
                timeEntryManager = null;
            }
            if (propertyTracker != null)
            {
                propertyTracker.Dispose();
                propertyTracker = null;
            }
        }
        public void Dispose()
        {
            var bus = ServiceContainer.Resolve <MessageBus> ();

            if (propertyTracker != null)
            {
                propertyTracker.Dispose();
                propertyTracker = null;
            }
            if (subscriptionSettingChanged != null)
            {
                bus.Unsubscribe(subscriptionSettingChanged);
                subscriptionSettingChanged = null;
            }
            if (subscriptionAuthChanged != null)
            {
                bus.Unsubscribe(subscriptionAuthChanged);
                subscriptionAuthChanged = null;
            }
            if (propertyTracker != null)
            {
                propertyTracker.Dispose();
                propertyTracker = null;
            }
        }
Exemple #3
0
 public void OnDestroy(Activity activity)
 {
     if (propertyTracker != null)
     {
         propertyTracker.Dispose();
         propertyTracker = null;
     }
 }
 private void ClearTracker()
 {
     if (_tracker != null)
     {
         Unsubscribe(_tracker);
         _tracker.Validated -= RaiseValidated;
         _tracker.Stop();
         _tracker.Dispose();
         _tracker = null;
     }
 }
        public override void OnStop ()
        {
            base.OnStop ();

            canRebind = false;

            if (propertyTracker != null) {
                propertyTracker.Dispose ();
                propertyTracker = null;
            }
        }
        protected override void Dispose(bool disposing)
        {
            if (disposing)
            {
                if (tracker != null)
                {
                    tracker.Dispose();
                    tracker = null;
                }
            }

            base.Dispose(disposing);
        }
Exemple #7
0
        public void Stop()
        {
            // Stop listening to timer changes
            isStarted = false;

            if (propertyTracker != null)
            {
                propertyTracker.Dispose();
                propertyTracker = null;
            }

            if (timeEntryManager != null)
            {
                timeEntryManager.PropertyChanged -= OnTimeEntryManagerPropertyChanged;
                timeEntryManager = null;
            }

            if (showRunning)
            {
                currentTimeEntry = null;
            }
        }
Exemple #8
0
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         if (propertyTracker != null)
         {
             propertyTracker.Dispose();
             propertyTracker = null;
         }
         if (data != null)
         {
             data.Updated -= OnDateGroupUpdated;
             data          = null;
         }
         if (models != null)
         {
             models.Clear();
             models = null;
         }
     }
     base.Dispose(disposing);
 }