Exemplo n.º 1
0
        protected void LinkDetailsWithMasterControl(SceneElement detailsContainerElement)
        {
            BaseFrameworkElement masterControl = this.FindMasterControl(detailsContainerElement);

            if (masterControl == null)
            {
                return;
            }
            masterControl.EnsureNamed();
            BindingSceneNode binding = (BindingSceneNode)this.DragModel.ViewModel.CreateSceneNode(PlatformTypes.Binding);

            binding.ElementName = masterControl.Name;
            binding.SetPath("SelectedItem");
            detailsContainerElement.SetBinding(BaseFrameworkElement.DataContextProperty, binding);
        }