当前位置: 首页>>代码示例>>C#>>正文


C# Base.Hide方法代码示例

本文整理汇总了C#中Gwen.Control.Base.Hide方法的典型用法代码示例。如果您正苦于以下问题:C# Base.Hide方法的具体用法?C# Base.Hide怎么用?C# Base.Hide使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Gwen.Control.Base的用法示例。


在下文中一共展示了Base.Hide方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: TreeNode

        /// <summary>
        /// Initializes a new instance of the <see cref="TreeNode"/> class.
        /// </summary>
        /// <param name="parent">Parent control.</param>
        public TreeNode(Base parent)
            : base(parent)
        {
            m_ToggleButton = new TreeToggleButton(this);
            m_ToggleButton.SetBounds(0, 0, 15, 15);
            m_ToggleButton.Toggled += OnToggleButtonPress;

            m_Title = new TreeNodeLabel(this);
            m_Title.Dock = Pos.Top;
            m_Title.Margin = new Margin(16, 0, 0, 0);
            m_Title.DoubleClicked += OnDoubleClickName;
            m_Title.Clicked += OnClickName;

            m_InnerPanel = new Base(this);
            m_InnerPanel.Dock = Pos.Top;
            m_InnerPanel.Height = 100;
            m_InnerPanel.Margin = new Margin(TreeIndentation, 1, 0, 0);
            m_InnerPanel.Hide();

            IsRoot = parent is TreeControl;
            m_Selected = false;
            IsSelectable = true;

            Dock = Pos.Top;
        }
开发者ID:Sprunth,项目名称:gwen-dotnet,代码行数:29,代码来源:TreeNode.cs

示例2: MenuManager

        public MenuManager()
        {
            MainMenu = ConstructMainMenu();
            MainMenu.Show();

            FindGame = ConstructFindGame();
            FindGame.Hide();

            Connecting = new ConnectingWindow();
            Connecting.Hide();
        }
开发者ID:CloneDeath,项目名称:FantasyScape,代码行数:11,代码来源:MenuManager.cs

示例3: ConstructFindGame

        Base ConstructFindGame()
        {
            Base FindGame = new Base(MainCanvas.GetCanvas());
            FindGame.SetSize(300, 300);

            Label EnterIP = new Label(FindGame);
            EnterIP.AutoSizeToContents = true;
            EnterIP.SetText("Enter an IP:");
            EnterIP.SetPosition(10, 10);

            TextBox IPAddress = new TextBox(FindGame);
            IPAddress.SetText("127.0.0.1");
            IPAddress.SetPosition(10, 40);
            IPAddress.SetSize(260, 20);

            TextBox Port = new TextBox(FindGame);
            Port.SetText("54987");
            Port.SetPosition(10, 70);
            Port.SetSize(260, 20);

            Button Connect = new Button(FindGame);
            Connect.SetText("Connect");
            Connect.SetPosition(10, 200);
            Connect.SetSize(200, 20);
            Connect.Clicked += delegate(Base sender, ClickedEventArgs args) {
                Program.Connect(IPAddress.Text, Int32.Parse(Port.Text));
                MainMenu.Hide();
                FindGame.Hide();

                Connecting.Show();
            };

            Button Back = new Button(FindGame);
            Back.SetText("Back");
            Back.SetPosition(10, 225);
            Back.SetSize(200, 20);
            Back.Clicked += delegate(Base sender, ClickedEventArgs args) {
                Mode = MenuMode.MainMenu;
                MainMenu.Show();
                FindGame.Hide();
            };

            return FindGame;
        }
开发者ID:CloneDeath,项目名称:FantasyScape,代码行数:44,代码来源:MenuManager.cs

示例4: ConstructMainMenu

        Base ConstructMainMenu()
        {
            Base MainMenu = new Base(MainCanvas.GetCanvas());
            MainMenu.SetSize(300, 300);
            MainMenu.Dock = Gwen.Pos.Center;

            Button SinglePlayer = new Button(MainMenu);
            SinglePlayer.SetText("Single Player");
            SinglePlayer.SetPosition(10, 10);
            SinglePlayer.SetSize(220, 20);
            //SinglePlayer.Clicked += delegate(Base caller) {
            //    Mode = SINGLEPLAYER;
            //    MainMenu.Hide();
            //};
            SinglePlayer.Disable();

            Button JoinGame = new Button(MainMenu);
            JoinGame.SetText("Join Game");
            JoinGame.SetPosition(10, 70);
            JoinGame.SetSize(220, 20);
            JoinGame.Clicked += delegate(Base sender, ClickedEventArgs args) {
                MainMenu.Hide();
                FindGame.Show();

                Mode = MenuMode.JoiningGame;
            };

            Button Quit = new Button(MainMenu);
            Quit.SetText("Quit");
            Quit.SetPosition(10, 100);
            Quit.SetSize(220, 20);
            Quit.Clicked += delegate(Base sender, ClickedEventArgs args) {
                MainCanvas.Dispose();
                Environment.Exit(0);
            };

            return MainMenu;
        }
开发者ID:CloneDeath,项目名称:FantasyScape,代码行数:38,代码来源:MenuManager.cs


注:本文中的Gwen.Control.Base.Hide方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。