Пример #1
0
        public bool MovePrev()
        {
            if (Matches.IndexOf(current) == 1)
            {
                return(false);
            }

            current = Matches[Matches.IndexOf(current) - 1];

            return(true);
        }
Пример #2
0
        public bool MoveNext()
        {
            if (Matches.IndexOf(current) == (Matches.Count - 1))
            {
                return(false);
            }

            current = Matches[Matches.IndexOf(current) + 1];

            return(true);
        }
Пример #3
0
        public void AddCreatedPoints(List <PointMatchTriplet> list, Point first)
        {
            foreach (PointMatchTriplet t in list)
            {
                matchList.Add(new MatchPoint(new Point(t.x, t.y), false));
            }

            foreach (MatchPoint p in Matches)
            {
                if (Math.Abs(p.Point.X - first.X) <= 5 && Math.Abs(p.Point.Y - first.Y) <= 5)
                {
                    p.Accept();
                    MatchPoint temp  = Matches[0];
                    int        index = Matches.IndexOf(p);
                    Matches[0]     = p;
                    Matches[index] = temp;
                    current        = Matches[1];
                    return;
                }
            }
        }
Пример #4
0
        public void AddCreatedPoints(List<PointMatchTriplet> list, Point first)
        {
            foreach(PointMatchTriplet t in list)
            {
                matchList.Add(new MatchPoint(new Point(t.x, t.y), false));
            }

            foreach (MatchPoint p in Matches)
            {
                if (Math.Abs(p.Point.X - first.X) <= 5 && Math.Abs(p.Point.Y - first.Y) <= 5)
                {
                    p.Accept();
                    MatchPoint temp = Matches[0];
                    int index = Matches.IndexOf(p);
                    Matches[0] = p;
                    Matches[index] = temp;
                    current = Matches[1];
                    return;
                }
            }
        }
Пример #5
0
        public bool MovePrev()
        {
            if (Matches.IndexOf(current) == 1)
                return false;

            current = Matches[Matches.IndexOf(current) - 1];

            return true;
        }
Пример #6
0
        public bool MoveNext()
        {
            if (Matches.IndexOf(current) == (Matches.Count - 1))
                return false;

            current = Matches[Matches.IndexOf(current) + 1];

            return true;
        }