Exemplo n.º 1
0
        public override bool Equals(object obj)
        {
            TextNavigationPoint b = obj as TextNavigationPoint;

            if (b == null)
            {
                return(false);
            }
            return(this.FileName.Equals(b.FileName) &&
                   (Math.Abs(this.LineNumber - b.LineNumber) <= THREASHOLD));
        }
Exemplo n.º 2
0
        public override int CompareTo(object obj)
        {
            int result = base.CompareTo(obj);

            if (0 != result)
            {
                return(result);
            }
            TextNavigationPoint b = obj as TextNavigationPoint;

            if (this.LineNumber == b.LineNumber)
            {
                return(0);
            }
            else if (this.LineNumber > b.LineNumber)
            {
                return(1);
            }
            else
            {
                return(-1);
            }
        }