示例#1
0
        private void TreeView_SelectedItemChanged(object sender, RoutedPropertyChangedEventArgs <object> e)
        {
            ItemTreeData treeViewItem = (ItemTreeData)(treeView.SelectedItem);

            if (treeViewItem == null)
            {
                return;
            }
            mainWindowViewModel.SelectItemChange(treeViewItem.itemId);
        }
示例#2
0
        private void OnSelectItem(ItemTreeData itemTreeData)
        {
            if (itemTreeData == null || itemTreeData.itemId <= 0)
            {
                SelectedCodeId = 0;
                return;
            }

            SelectedCodeId = itemTreeData.itemId;
            var parameters = new NavigationParameters();

            parameters.Add("Id", itemTreeData.itemId);
            _regionManager.RequestNavigate(RegionNames.ContentRegionCode, "CodeInfo", parameters);
        }