Example #1
0
        public override void OnApplyTemplate()
        {
            if (_comboBox != null)
            {
                _comboBox.ItemSelected   -= ComboBox_SelectionChanged;
                _comboBox.PreviewProvider = null;
            }

            _comboBox = GetTemplateChild(@"PART_ComboBox") as HierarchicalComboBox;
            if (_comboBox != null)
            {
                _comboBox.ItemSelected   += ComboBox_SelectionChanged;
                _comboBox.PreviewProvider = this;
            }

            base.OnApplyTemplate();
        }
Example #2
0
        public override void OnApplyTemplate() {
            if (_comboBox != null) {
                _comboBox.ItemSelected -= ComboBox_SelectionChanged;
                _comboBox.PreviewProvider = null;
            }

            _comboBox = GetTemplateChild(@"PART_ComboBox") as HierarchicalComboBox;
            if (_comboBox != null) {
                _comboBox.ItemSelected += ComboBox_SelectionChanged;
                _comboBox.PreviewProvider = this;
            }

            base.OnApplyTemplate();
        }