示例#1
0
        public Control[] draw(int index)
        {
            if (next is ControlLine)
            {
                return(next.draw(index));
            }
            else
            {
                lblScene.Text = "Scene " + index;

                lblScene.Location      = new Point(8, 22 + 37 * (index - 1));
                cobxScenes.Location    = new Point(72, 19 + 37 * (index - 1));
                pnlGames.Location      = new Point(238, 21 + 37 * (index - 1));
                btnAddGames.Location   = new Point(508, 18 + 37 * (index - 1));
                btnDeleteLine.Location = new Point(583, 18 + 37 * (index - 1));

                lblNoGames.Location = new Point(238, pnlGames.Location.Y + 24);
                lblNoScene.Location = new Point(72, cobxScenes.Location.Y + 23);

                for (int i = 0; i < pnlGames.Controls.Count; i++)
                {
                    pnlGames.Controls[i].Location = new Point(20 * i, 0);
                }

                return(new Control[] { lblScene, cobxScenes, pnlGames, btnAddGames, btnDeleteLine });
            }
        }
示例#2
0
        public void addSceneConfig(string[] games)
        {
            controlLineList = controlLineList.addControlLine(games);
            pnlSceneConfig.Controls.AddRange(controlLineList.draw(controlLineList.getLength()));

            btnAddSceneConfig.Location = new Point(6, 22 + 37 * controlLineList.getLength());

            controlLineList.fillComboboxes(sceneNamesStr);
        }