Ejemplo n.º 1
0
 internal static XamlNode GetValue(XamlDomValue XamlDomValue)
 {
     _xamlNode.Clear();
     _xamlNode.NodeType     = XamlNodeType.Value;
     _xamlNode.Value        = XamlDomValue.Value;
     _xamlNode.LineNumber   = XamlDomValue.StartLineNumber;
     _xamlNode.LinePosition = XamlDomValue.StartLinePosition;
     return(_xamlNode);
 }
Ejemplo n.º 2
0
        public XamlDomMember(Type declaringType, string attachedMember, object value)
        {
            if (attachedMember == null)
            {
                throw new ArgumentNullException("attachedMember");
            }

            _unresolvedDeclaringType = declaringType;
            _unresolvedMemberName    = attachedMember;

            Item = new XamlDomValue(value);
        }
Ejemplo n.º 3
0
        public override void WriteValue(object value)
        {
            var valueNode = new XamlDomValue();

            valueNode.Value = value;

            if (RootNode != null)
            {
                //text should always be inside of a property...
                var propertyNode = (XamlDomMember)writerStack.Peek();
                propertyNode.Items.Add(valueNode);
            }
            else
            {
                RootNode = valueNode;
            }

            valueNode.StartLineNumber   = _lineNumber;
            valueNode.StartLinePosition = _linePosition;
            valueNode.EndLineNumber     = _lineNumber;
            valueNode.EndLinePosition   = _linePosition;
        }
Ejemplo n.º 4
0
        public override void WriteValue(object value)
        {
            var valueNode = new XamlDomValue();
            valueNode.Value = value;

            if (RootNode != null)
            {
                //text should always be inside of a property...
                var propertyNode = (XamlDomMember) writerStack.Peek();
                propertyNode.Items.Add(valueNode);
            }
            else
            {
                RootNode = valueNode;
            }

            valueNode.StartLineNumber = _lineNumber;
            valueNode.StartLinePosition = _linePosition;
            valueNode.EndLineNumber = _lineNumber;
            valueNode.EndLinePosition = _linePosition;
        }
Ejemplo n.º 5
0
 internal static XamlNode GetValue(XamlDomValue XamlDomValue)
 {
     _xamlNode.Clear();
     _xamlNode.NodeType = XamlNodeType.Value;
     _xamlNode.Value = XamlDomValue.Value;
     _xamlNode.LineNumber = XamlDomValue.StartLineNumber;
     _xamlNode.LinePosition = XamlDomValue.StartLinePosition;
     return _xamlNode;
 }
Ejemplo n.º 6
0
 private IEnumerable<XamlNode> ReadValueNode(XamlDomValue XamlDomValue)
 {
     yield return XamlNode.GetValue(XamlDomValue);
 }
Ejemplo n.º 7
0
 public XamlDomMember(XamlMember xamlMember, object value)
     : this(xamlMember)
 {
     Item = new XamlDomValue(value);
     Resolve();
 }
Ejemplo n.º 8
0
        public XamlDomMember(Type declaringType, string attachedMember, object value)
        {
            if (attachedMember == null)
            {
                throw new ArgumentNullException("attachedMember");
            }

            _unresolvedDeclaringType = declaringType;
            _unresolvedMemberName = attachedMember;

            Item = new XamlDomValue(value);
        }
Ejemplo n.º 9
0
 private IEnumerable <XamlNode> ReadValueNode(XamlDomValue XamlDomValue)
 {
     yield return(XamlNode.GetValue(XamlDomValue));
 }
Ejemplo n.º 10
0
 public XamlDomMember(XamlMember xamlMember, object value)
     : this(xamlMember)
 {
     Item = new XamlDomValue(value);
     Resolve();
 }