Exemplo n.º 1
0
        protected override object GetLocalValueInternal(PropertyReference propertyReference, PropertyContext context)
        {
            PropertyReference propertyReference1 = this.GetMediaTimelinePropertyReference(propertyReference);

            if (propertyReference1 != null)
            {
                MediaTimelineSceneNode owningTimeline = this.OwningTimeline;
                if (owningTimeline != null)
                {
                    return(owningTimeline.GetLocalValue(propertyReference1, context));
                }
            }
            return(base.GetLocalValueInternal(propertyReference, context));
        }
Exemplo n.º 2
0
        protected override object GetComputedValueInternal(PropertyReference propertyReference)
        {
            PropertyReference propertyReference1 = this.GetMediaTimelinePropertyReference(propertyReference);

            if (propertyReference1 != null)
            {
                MediaTimelineSceneNode owningTimeline = this.OwningTimeline;
                if (owningTimeline != null)
                {
                    ViewState viewState = ViewState.ElementValid | ViewState.AncestorValid | ViewState.SubtreeValid;
                    if (!owningTimeline.ViewModel.DefaultView.IsValid || (owningTimeline.ViewModel.DefaultView.GetViewState((SceneNode)owningTimeline) & viewState) != viewState || propertyReference1.LastStep == MediaTimelineSceneNode.SourceProperty)
                    {
                        return(owningTimeline.GetLocalOrDefaultValue(propertyReference1));
                    }
                    IViewObject viewObject = owningTimeline.ViewModel.GetViewObject(owningTimeline.DocumentNodePath);
                    propertyReference = DesignTimeProperties.GetAppliedShadowPropertyReference(propertyReference, (ITypeId)owningTimeline.TargetElement.Type);
                    return(propertyReference1.GetCurrentValue(viewObject.PlatformSpecificObject));
                }
            }
            return(base.GetComputedValueInternal(propertyReference));
        }
Exemplo n.º 3
0
        protected override DocumentNodePath GetLocalValueAsDocumentNode(IProperty[] propertyPath, bool forceEvaluateExpressions)
        {
            PropertyReference propertyReference = (PropertyReference)null;

            if (propertyPath.Length == 1)
            {
                ReferenceStep step = propertyPath[0] as ReferenceStep;
                if (step != null)
                {
                    propertyReference = this.GetMediaTimelinePropertyReference(step);
                }
            }
            if (propertyReference != null)
            {
                MediaTimelineSceneNode owningTimeline = this.OwningTimeline;
                if (owningTimeline != null)
                {
                    return(owningTimeline.GetLocalValueAsDocumentNode(propertyReference, forceEvaluateExpressions));
                }
            }
            return(base.GetLocalValueAsDocumentNode(propertyPath, forceEvaluateExpressions));
        }
Exemplo n.º 4
0
        protected override void ModifyValue(PropertyReference propertyReference, object valueToSet, SceneNode.Modification modification, int index)
        {
            PropertyReference propertyReference1 = this.GetMediaTimelinePropertyReference(propertyReference);

            if (propertyReference1 != null)
            {
                MediaTimelineSceneNode owningTimeline = this.OwningTimeline;
                if (owningTimeline != null)
                {
                    if (modification == SceneNode.Modification.ClearValue)
                    {
                        owningTimeline.ClearValue(propertyReference1);
                        return;
                    }
                    if (modification != SceneNode.Modification.SetValue)
                    {
                        return;
                    }
                    owningTimeline.SetValue(propertyReference1, valueToSet);
                    return;
                }
            }
            base.ModifyValue(propertyReference, valueToSet, modification, index);
        }