Esempio n. 1
0
        public ShopForm()
        {
            InitializeComponent();
            this.rtb_Log.Text = "";
            Logger.SetUpLogFile("", rtb_Log);

            shop = new Shop(15);
            shopClients = new ClientsQueue();

            vendorsThreads = new Dictionary<int, Thread>();
            isShopClosing = false;
            TestShopFill();
            queueHeights = new Dictionary<string, int>();
            queueHeights.Add((string)this.lbl_vendor1.Tag, this.gb_Stand1.Location.Y - 40);
            queueHeights.Add((string)this.lbl_vendor2.Tag, this.gb_Stand1.Location.Y - 40);
            queueHeights.Add((string)this.lbl_vendor3.Tag, this.gb_Stand1.Location.Y - 40);
            queueHeights.Add((string)this.lbl_vendor4.Tag, this.gb_Stand1.Location.Y - 40);
            queueHeights.Add((string)this.lbl_vendor5.Tag, this.gb_Stand1.Location.Y - 40);
            queueHeights.Add((string)this.lbl_vendor6.Tag, this.gb_Stand1.Location.Y - 40);
            queueHeights.Add((string)this.lbl_vendor7.Tag, this.gb_Stand1.Location.Y - 40);
            queueHeights.Add((string)this.lbl_vendor8.Tag, this.gb_Stand1.Location.Y - 40);
            queueHeights.Add((string)this.lbl_vendor9.Tag, this.gb_Stand1.Location.Y - 40);
            queueHeights.Add((string)this.lbl_vendor10.Tag, this.gb_Stand1.Location.Y - 40);
            queueHeights.Add((string)this.lbl_vendor11.Tag, this.gb_Stand1.Location.Y - 40);
        }
Esempio n. 2
0
        public Client(Shop shop)
        {
            idCount++;
            this.clientID = idCount;

            visitedStands = new Dictionary<int, bool>();
            foreach (var stand in shop)
            {
                visitedStands.Add(stand.StandId, false);
            }
        }