Пример #1
0
        /// <summary>
        /// 終了処理
        /// </summary>
        public void Dispose()
        {
            if (_Calendar != null)
            {
                _Calendar.Dispose();
                _Calendar = null;
            }

            if (_Timer != null)
            {
                _Timer.PropertyChanged -= OnTimerPropertyChanged;
                _Timer.Dispose();
                _Timer = null;
            }

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

            if (_TabItem != null)
            {
                _TabItem.PropertyChanged -= OnTabItemPropertyChanged;
                _TabItem.Dispose();
                _TabItem = null;
            }
        }
Пример #2
0
        /// <summary>
        /// 終了処理
        /// </summary>
        public void Dispose()
        {
            if (_Model != null)
            {
                _Model.Dispose();
                _Model = null;
            }

            if (_TimerModel != null)
            {
                _TimerModel.PropertyChanged -= OnTimerPropertyChanged;
                _TimerModel.Dispose();
                _TimerModel = null;
            }
        }