Beispiel #1
0
        public bool MovePrev()
        {
            if (Matches.IndexOf(current) == 1)
            {
                return(false);
            }

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

            return(true);
        }
Beispiel #2
0
        public bool MoveNext()
        {
            if (Matches.IndexOf(current) == (Matches.Count - 1))
            {
                return(false);
            }

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

            return(true);
        }
Beispiel #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;
                }
            }
        }
        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;
                }
            }
        }
        public bool MovePrev()
        {
            if (Matches.IndexOf(current) == 1)
                return false;

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

            return true;
        }
        public bool MoveNext()
        {
            if (Matches.IndexOf(current) == (Matches.Count - 1))
                return false;

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

            return true;
        }