コード例 #1
0
        Panel BuildProgressTextPanel()
        {
            Panel result = ControlBuilder.CreatePanel(
                ControlBuilder.DefaultControlHeight, DockStyle.Bottom);

            mProgressLabel = ControlBuilder.CreateLabel(string.Empty, DockStyle.Left);

            ControlPacker.AddControl(result, ControlBuilder.CreateHorizontalPadding(DockStyle.Left));
            ControlPacker.AddControl(result, mProgressLabel);

            return(result);
        }
コード例 #2
0
        Panel BuildListBoxPanel()
        {
            Panel result = ControlBuilder.CreatePanel(DockStyle.Fill);

            mListBox = ControlBuilder.CreateListBox(DockStyle.Fill);
            mListBox.SelectionMode = SelectionMode.None;

            ControlPacker.AddControl(result, ControlBuilder.CreateHorizontalPadding(DockStyle.Left));
            ControlPacker.AddControl(result, ControlBuilder.CreateHorizontalPadding(DockStyle.Right));
            ControlPacker.AddControl(result, mListBox);

            return(result);
        }
コード例 #3
0
ファイル: ErrorDialog.cs プロジェクト: xush1611/GuiTestSharp
        Panel BuildButtonPanel()
        {
            Panel result = ControlBuilder.CreatePanel(
                ControlBuilder.DefaultControlHeight, DockStyle.Top);

            mOkButton = ControlBuilder.CreateButton(
                Localization.GetText(Localization.Name.Ok), DockStyle.Right);

            mOkButton.Click += OkButton_Click;
            CancelButton     = mOkButton;

            ControlPacker.AddControl(result, mOkButton);
            ControlPacker.AddControl(
                result, ControlBuilder.CreateHorizontalPadding(DockStyle.Right));

            return(result);
        }
コード例 #4
0
        Panel BuildTextInputPanel()
        {
            Panel result = ControlBuilder.CreatePanel(
                ControlBuilder.DefaultControlHeight, DockStyle.Top);

            Label textInputLabel = ControlBuilder.CreateLabel(
                Localization.GetText(Localization.Name.TextInputLabel),
                DockStyle.Left);

            mTextBox = ControlBuilder.CreateTextbox(DockStyle.Fill);

            ControlPacker.AddControl(
                result, ControlBuilder.CreateHorizontalPadding(DockStyle.Left));
            ControlPacker.AddControl(result, textInputLabel);
            ControlPacker.AddControl(result, mTextBox);
            ControlPacker.AddControl(
                result, ControlBuilder.CreateHorizontalPadding(DockStyle.Right));

            return(result);
        }
コード例 #5
0
        Panel BuildButtonsPanel()
        {
            Panel result = ControlBuilder.CreatePanel(
                ControlBuilder.DefaultControlHeight, DockStyle.Top);

            mRemoveButton = ControlBuilder.CreateButton(
                Localization.GetText(Localization.Name.RemoveButton),
                DockStyle.Right);

            mAddButton = ControlBuilder.CreateButton(
                Localization.GetText(Localization.Name.AddButton),
                DockStyle.Right);

            ControlPacker.AddControl(result, mRemoveButton);
            ControlPacker.AddControl(
                result, ControlBuilder.CreateHorizontalPadding(DockStyle.Right));
            ControlPacker.AddControl(result, mAddButton);
            ControlPacker.AddControl(
                result, ControlBuilder.CreateHorizontalPadding(DockStyle.Right));

            return(result);
        }
コード例 #6
0
ファイル: ErrorDialog.cs プロジェクト: xush1611/GuiTestSharp
        Panel BuildMessagePanel()
        {
            Panel result = ControlBuilder.CreatePanel(DockStyle.Top);

            result.Height = 70;

            PictureBox errorPictureBox = ControlBuilder.CreatePictureBox(
                SystemIcons.Error.ToBitmap(), DockStyle.Left);

            mMessageLabel          = ControlBuilder.CreateLabel(string.Empty, DockStyle.Fill);
            mMessageLabel.AutoSize = false;

            ControlPacker.AddControl(
                result, ControlBuilder.CreateHorizontalPadding(DockStyle.Left));
            ControlPacker.AddControl(result, errorPictureBox);
            ControlPacker.AddControl(
                result, ControlBuilder.CreateHorizontalPadding(DockStyle.Left));
            ControlPacker.AddControl(result, mMessageLabel);
            ControlPacker.AddControl(
                result, ControlBuilder.CreateHorizontalPadding(DockStyle.Right));

            return(result);
        }