/// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { #region Controls var defBtnSizeBig = new Size(100, 23); var defBtnSize = new Size(70, 23); constFullLbl = new BaseLabel(_res, "constFullLbl", 6, new Point(233, 315), new Size(178, 18), "Constructed Full Address:", autoSize: true); genAddLbl = new BaseLabel(_res, "genAddLbl", 3, new Point(3, 315), new Size(131, 18), "Generate Address:", autoSize: true); macVendorsLbl = new BaseLabel(_res, "macVendorsLbl", 1, new Point(3, 40), new Size(100, 18), "Mac Vendors:", autoSize: true); savedAddysLbl = new BaseLabel(_res, "savedAddysLbl", 3, new Point(5, 40), new Size(123, 17), "Saved Addresses:", padding: new Padding(5, 40, 3, 0), autoSize: true); generateRndmBtn = new BaseButton(_res, "generateRndmBtn", 9, point: new Point(236, 237), size: new Size(120, 23), text: "Generate Random", visStyleBackColor: true); applyFullAddBtn = new BaseButton(_res, "applyFullAddBtn", 8, point: new Point(236, 387), size: defBtnSizeBig, text: "Apply Full Address", visStyleBackColor: true); saveToFileBtn = new BaseButton(_res, "saveToFileBtn", 0, point: new Point(236, 433), size: new Size(70, 23), margin: new Padding(20, 20, 3, 3), text: "Save", visStyleBackColor: true); generateAddrBtn = new BaseButton(_res, "generateAddrBtn", 5, point: new Point(6, 387), size: defBtnSizeBig, text: "Generate New", visStyleBackColor: true); addVendorBtn = new BaseButton(_res, "addVendorBtn", 4, point: new Point(6, 237), size: new Size(100, 23), text: "Add Selected", visStyleBackColor: true); applySelectBtn = new BaseButton(_res, "applySelectBtn", 1, point: new Point(35, 151), size: defBtnSize, margin: new Padding(35, 60, 3, 3), text: "Apply", visStyleBackColor: true); removeSelectBtn = new BaseButton(_res, "removeSelectBtn", 2, point: new Point(35, 192), size: defBtnSize, margin: new Padding(35, 15, 3, 3), text: "Remove", visStyleBackColor: true); macAddHelpBtn = new BaseButton(_res, "macAddHelpBtn", 5, point: new Point(80, 233), size: new Size(40, 23), margin: new Padding(80, 15, 3, 3), text: "Help!", visStyleBackColor: true); fullMacTxtBox = new BaseTextBox(_res, "fullMacTxtBox", 7, new Point(236, 349), new Size(160, 20)); generatedTxtBox = new BaseTextBox(_res, "generatedTxtBox", 2, new Point(6, 349), new Size(120, 20)); macVendorsLstBox = new BaseListBox(_res, "macVendorsLstBox", 0, true, point: new Point(6, 67), size: new Size(350, 147)); savedMacsCmboBox = new BaseComboBox(_res, "savedMacsCmboBox", 3, new Point(5, 67), new Size(121, 21), new Padding(5, 10, 3, 3)); #endregion #region Panels macDetailsPnl = new BaseFlowPanel(_res, "macDetailsPnl", 0, new Control[] { generateRndmBtn, applyFullAddBtn, saveToFileBtn, fullMacTxtBox, constFullLbl, generateAddrBtn, addVendorBtn, genAddLbl, generatedTxtBox, macVendorsLbl, macVendorsLstBox }, new Point(12, 12), new Size(434, 491)); savedAddrsPnl = new BaseFlowPanel(_res, "svedAddrsPnl", 1, new Control[] { savedAddysLbl, savedMacsCmboBox, applySelectBtn, removeSelectBtn, macAddHelpBtn }, new Point(461, 12), new Size(140, 490), borderStyle: BorderStyle.Fixed3D); #endregion SuspendLayout(); InitMacAddress(); }
/// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { #region Controls var defBigButtonSize = new Size(120, 23); var defButtonPadding = new Padding(85, 10, 85, 5); var defControlPadding = new Padding(5, 10, 5, 5); removeCurrBtn = new BaseButton(_res, "removeCurrBtn", 2, visStyleBackColor: true, point: new Point(85, 79), margin: defButtonPadding, size: defBigButtonSize, text: "Remove Selected"); setSelectedBtn = new BaseButton(_res, "setSelectedBtn", 11, visStyleBackColor: true, point: new Point(85, 117), margin: defButtonPadding, size: defBigButtonSize, text: "Set Selected"); setAsDefBtn = new BaseButton(_res, "setAsDefBtn", 6, visStyleBackColor: true, point: new Point(85, 155), margin: defButtonPadding, size: defBigButtonSize, text: "Set as Default"); setToDefBtn = new BaseButton(_res, "setToDefBtn", 3, visStyleBackColor: true, point: new Point(85, 193), margin: defButtonPadding, size: defBigButtonSize, text: "Set to Default"); checkGeoDataBtn = new BaseButton(_res, "checkGeoData", 5, visStyleBackColor: true, point: new Point(85, 231), margin: defButtonPadding, size: defBigButtonSize, text: "Check Geo-Data"); addCustomBtn = new BaseButton(_res, "addCustomBtn", 9, visStyleBackColor: true, point: new Point(85, 337), margin: defButtonPadding, size: defBigButtonSize, text: "Add Custom"); addNSetCustBtn = new BaseButton(_res, "addNSetCustBtn", 12, visStyleBackColor: true, point: new Point(85, 375), margin: defButtonPadding, size: defBigButtonSize, text: "Add and Set Custom"); removeSimilarBtn = new BaseButton(_res, "removeSimilarBtn", 10, visStyleBackColor: true, point: new Point(85, 413), margin: defButtonPadding, size: defBigButtonSize, text: "Remove Similar"); currHelpBtn = new BaseButton(_res, "currHelpBtn", 4, visStyleBackColor: true, point: new Point(190, 461), margin: new Padding(0, 20, 25, 5), size: new Size(75, 23), text: "Help!", dock: DockStyle.Right); addNewBtn = new BaseButton(_res, "addNewBtn", 0, visStyleBackColor: true, point: new Point(84, 15), margin: new Padding(84, 15, 3, 3), size: defBigButtonSize, text: "Add New"); addnSetNewBtn = new BaseButton(_res, "addnSetNewBtn", 1, visStyleBackColor: true, point: new Point(84, 56), margin: new Padding(84, 15, 3, 3), size: defBigButtonSize, text: "Add and Set New"); helpNewBtn = new BaseButton(_res, "helpNewBtn", 2, visStyleBackColor: true, point: new Point(183, 107), margin: new Padding(183, 25, 15, 3), size: new Size(80, 23), text: "Help!", dock: DockStyle.Right); customTagInpBox = new BaseTextBox(_res, "customTagInpBox", 8, new Point(5, 302), new Size(270, 20), padding: defControlPadding); langTagListBox = new BaseListBox(_res, "langTagListBox", 18, formatting: true, scrollAlwaysVisible: true, backColor: SystemColors.MenuText, foreColor: Color.OliveDrab, point: new Point(317, 12), size: new Size(288, 346), selMode: SelectionMode.MultiSimple); customInpLbl = new BaseLabel(_res, "customInpLbl", 7, new Point(5, 269), new Size(96, 18), "Custom Input", padding: defControlPadding, autoSize: true); currentInstLangsLbl = new BaseLabel(_res, "currentInstLangsLbl", 1, new Point(5, 10), new Size(186, 18), "Current Installed Languages:", autoSize: true, padding: defControlPadding); currentLangsCmboBox = new BaseComboBox(_res, "currentLangsCmboBox", point: new Point(5, 43), size: new Size(270, 21), padding: defControlPadding); #endregion #region Panels currLangOpPanel = new BaseFlowPanel(_res, "currLangOpPanel", 1, controls: new Control[] { currentInstLangsLbl, currentLangsCmboBox, removeCurrBtn, setSelectedBtn, setAsDefBtn, setToDefBtn, checkGeoDataBtn, customInpLbl, customTagInpBox, addCustomBtn, addNSetCustBtn, removeSimilarBtn, currHelpBtn }, new Point(12, 12), new Size(290, 498), borderStyle: BorderStyle.Fixed3D, flow: FlowDirection.TopDown); newLangListPanel = new BaseFlowPanel(_res, "newLangListPanel", 2, controls: new Control[] { addNewBtn, addnSetNewBtn, helpNewBtn }, new Point(317, 364), new Size(288, 146), borderStyle: BorderStyle.Fixed3D, flow: FlowDirection.TopDown); #endregion SuspendLayout(); InitSysLanguage(); }
/// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { #region Controls var defVisStyleBackCol = true; connTxtBox = new BaseTextBox(_res, "connTxtBox", 1, new Point(30, 52), new Size(120, 20), padding: new Padding(30, 5, 3, 3)); addressTxtBox = new BaseTextBox(_res, "addressTxtBox", 3, new Point(30, 112), new Size(120, 20), padding: new Padding(30, 5, 3, 3)); portTxtBox = new BaseTextBox(_res, "portTxtBox", 5, new Point(30, 172), new Size(120, 20), padding: new Padding(30, 5, 3, 3)); gatewayTxtBox = new BaseTextBox(_res, "gatewayTxtBox", 7, new Point(30, 232), new Size(120, 20), padding: new Padding(30, 5, 3, 3)); screenWidthTxtBox = new BaseTextBox(_res, "screenWidthTxtBox", 23, new Point(20, 124), new Size(105, 20), padding: new Padding(20, 5, 3, 3)); screenHeightTxtBox = new BaseTextBox(_res, "screenHeightTxtBox", 25, new Point(20, 184), new Size(105, 20), padding: new Padding(20, 5, 3, 3)); connLbl = new BaseLabel(_res, "connLbl", 0, new Point(30, 30), new Size(124, 17), "Connection Name:", autoSize: true, padding: new Padding(30, 30, 3, 0)); addressLbl = new BaseLabel(_res, "addressLbl", 2, new Point(30, 90), new Size(110, 17), "Server Address:", autoSize: true, padding: new Padding(30, 15, 3, 0)); portLbl = new BaseLabel(_res, "portLbl", 4, new Point(30, 150), new Size(84, 17), "Server Port:", autoSize: true, padding: new Padding(30, 15, 3, 0)); gatewayLbl = new BaseLabel(_res, "gatewayLbl", 6, new Point(30, 120), new Size(67, 17), "Gateway:", autoSize: true, padding: new Padding(30, 15, 3, 0)); connStatusLbl = new BaseLabel(_res, "connStatusLbl", 8, new Point(175, 129), new Size(127, 17), "Connection Status", autoSize: true); savedRdpsLbl = new BaseLabel(_res, "savedRdpsLbl", 1, new Point(31, 28), new Size(97, 18), "Saved RDPs:", autoSize: true); screenWidthLbl = new BaseLabel(_res, "screenWidthLbl", 22, new Point(20, 102), new Size(97, 17), "Screen Width:", autoSize: true, padding: new Padding(20, 15, 3, 0)); screenHeightLbl = new BaseLabel(_res, "screenHeightLbl", 24, new Point(20, 162), new Size(102, 17), "Screen Height:", autoSize: true, padding: new Padding(20, 15, 3, 0)); useGatewayChckBox = new BaseCheckBox(_res, "useGatewayChckBox", 8, defVisStyleBackCol, "Use Gateway", new Point(30, 285), new Size(98, 19), margin: new Padding(30, 30, 3, 3)); asAdminChckBox = new BaseCheckBox(_res, "asAdminChckBox", 9, defVisStyleBackCol, "As Admin", new Point(30, 317), new Size(77, 19), margin: new Padding(30, 10, 3, 3)); remGuardChckBox = new BaseCheckBox(_res, "remGuardChckBox", 10, defVisStyleBackCol, "Remote Guard", new Point(30, 349), new Size(107, 19), margin: new Padding(30, 10, 3, 3)); restrictedAdminChckBox = new BaseCheckBox(_res, "restrictedAdminChckBox", 15, defVisStyleBackCol, "As Restricted Admin", new Point(30, 381), new Size(135, 19), margin: new Padding(30, 10, 3, 3)); fullScreenChckBox = new BaseCheckBox(_res, "fullScreenChckBox", 19, defVisStyleBackCol, "Start Fullscreen", new Point(10, 15), new Size(111, 19), margin: new Padding(10, 15, 3, 3)); multiMonitorChckBox = new BaseCheckBox(_res, "multiMonitorChckBox", 20, defVisStyleBackCol, "Multi Monitor Mode", new Point(10, 40), new Size(133, 19), margin: new Padding(10, 3, 3, 3)); spanMonitorsChckBox = new BaseCheckBox(_res, "spanMonitorsChckBox", 21, defVisStyleBackCol, "Span Monitors Mode", new Point(10, 65), new Size(141, 19), margin: new Padding(10, 3, 3, 3)); rdpCredsHelpBtn = new BaseButton(_res, "rdpCredsHelpBtn", 16, visStyleBackColor: defVisStyleBackCol, point: new Point(174, 458), margin: new Padding(174, 55, 3, 3), size: new Size(40, 23)); recheckConnBtn = new BaseButton(_res, "recheckConnBtn", 9, visStyleBackColor: defVisStyleBackCol, point: new Point(33, 228), size: new Size(120, 23), text: "Recheck Connection"); editCrntBtn = new BaseButton(_res, "editCrntBtn", 6, visStyleBackColor: defVisStyleBackCol, point: new Point(33, 190), size: new Size(75, 23), text: "Edit"); delCrntBtn = new BaseButton(_res, "delCrntBtn", 5, visStyleBackColor: defVisStyleBackCol, point: new Point(33, 161), size: new Size(75, 23), text: "Delete"); connectCrntBtn = new BaseButton(_res, "connectCrntBtn", 4, visStyleBackColor: defVisStyleBackCol, point: new Point(33, 129), size: new Size(75, 23), text: "Connect To"); refreshRdpsBtn = new BaseButton(_res, "refreshRdpBtn", 3, visStyleBackColor: defVisStyleBackCol, point: new Point(237, 57), size: new Size(60, 23), text: "Refresh"); saveNUpdtBtn = new BaseButton(_res, "saveNUpdtBtn", visStyleBackColor: defVisStyleBackCol, point: new Point(19, 10), margin: new Padding(19, 10, 3, 3), size: new Size(110, 23), text: "Save / Update"); saveToRdpFileBtn = new BaseButton(_res, "saveToRdpFileBtn", 5, visStyleBackColor: defVisStyleBackCol, point: new Point(19, 46), margin: new Padding(19, 10, 3, 3), size: new Size(110, 23), text: "Save as .RDP"); saveToXmlBtn = new BaseButton(_res, "saveToXmlBtn", 4, visStyleBackColor: defVisStyleBackCol, point: new Point(19, 82), margin: new Padding(19, 10, 3, 3), size: new Size(110, 23), text: "Save as .XML"); connGivenBtn = new BaseButton(_res, "connGivenBtn", 2, visStyleBackColor: defVisStyleBackCol, point: new Point(19, 118), margin: new Padding(19, 10, 3, 3), size: new Size(110, 23), text: "Quick Connect"); resetBtn = new BaseButton(_res, "resetBtn", 1, visStyleBackColor: defVisStyleBackCol, point: new Point(19, 154), margin: new Padding(19, 10, 3, 3), size: new Size(110, 23), text: "Reset To Defaults"); screenSettingsHelpBtn = new BaseButton(_res, "screenSettingsHelpBtn", 3, visStyleBackColor: defVisStyleBackCol, point: new Point(88, 185), margin: new Padding(88, 5, 3, 3), size: new Size(40, 23), text: "Help!"); isMstcRunningImgBox = new BasePicBox(_res, "isMstcRunningImgBox", 7, new Point(191, 161), new Size(106, 90)); savedRdpsResults = new BaseComboBox(_res, "savedRdpsResults", 2, new Point(33, 59), new Size(181, 21)); onlyRdpFilesRdio = new BaseRadioButton(_res, "onlyRdpFilesRdio", text: "Only .RDP Files", autoSize: true, point: new Point(173, 25), size: new Size(125, 21), tabStop: true, visualStyleCol: true); #endregion #region Panels currentRdpsPnl = new BaseFlowPanel(_res, "currentRdpsPnl", 3, new Control[] { recheckConnBtn, connStatusLbl, isMstcRunningImgBox, editCrntBtn, delCrntBtn, connectCrntBtn, refreshRdpsBtn, savedRdpsResults, savedRdpsLbl, saveToRdpFileBtn, onlyRdpFilesRdio }, new Point(276, 12), new Size(327, 264), borderStyle: BorderStyle.Fixed3D); screenSettingsHolderPnl = new BaseFlowPanel(_res, "screenSettingsHolderPnl", 4, new Control[] { rdpButtonsPnl, screenSettingsPnl }, new Point(276, 285), new Size(328, 225), borderStyle: BorderStyle.Fixed3D); connectionSettingsPnl = new BaseFlowPanel(_res, "connectionSettingsPnl", controls: new Control[] { connLbl, connTxtBox, addressLbl, addressTxtBox, portLbl, portTxtBox, gatewayLbl, gatewayTxtBox, useGatewayChckBox, asAdminChckBox, remGuardChckBox, restrictedAdminChckBox, rdpCredsHelpBtn }, point: new Point(12, 12), size: new Size(244, 498), borderStyle: BorderStyle.Fixed3D, flow: FlowDirection.TopDown); rdpButtonsPnl = new BaseFlowPanel(_res, "rdpButtonsPnl", 1, new Control[] { saveNUpdtBtn, saveToRdpFileBtn, saveToXmlBtn, connGivenBtn, resetBtn, screenSettingsHelpBtn }, new Point(173, 3), new Size(148, 215)); screenSettingsPnl = new BaseFlowPanel(_res, "screenSettingsPnl", controls: new Control[] { fullScreenChckBox, multiMonitorChckBox, spanMonitorsChckBox, screenWidthLbl, screenWidthTxtBox, screenHeightLbl, screenHeightTxtBox }, point: new Point(3, 3), size: new Size(164, 215)); #endregion ((System.ComponentModel.ISupportInitialize)(isMstcRunningImgBox)).BeginInit(); SuspendLayout(); InitRdp(); }
/// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { #region Controls var regularBtnSize = new Size(80, 23); var largeBtnSize = new Size(120, 23); var defaultButtonPadding = new Padding(60, 10, 0, 5); var defTxtBoxPoint = new Point(6, 57); var defTxtBoxSize = new Size(135, 21); var defLblPoint = new Point(3, 29); var defComboPoint = new Point(6, 57); var defComboSize = new Size(135, 21); var defPanelSize = new Size(150, 100); selectConnBtn = new BaseButton(_res, "selectConnBtn", visStyleBackColor: true, point: new Point(60, 20), margin: new Padding(60, 20, 0, 5), size: regularBtnSize, text: "Connect to Selected"); selectEditBtn = new BaseButton(_res, "selectEditBtn", visStyleBackColor: true, point: new Point(60, 58), margin: defaultButtonPadding, size: regularBtnSize, text: "Edit"); selectRmvBtn = new BaseButton(_res, "selectRmvBtn", visStyleBackColor: true, point: new Point(60, 96), margin: defaultButtonPadding, size: regularBtnSize, text: "Remove"); vpnHelpBtn = new BaseButton(_res, "vpnHelpBtn", 3, visStyleBackColor: true, point: new Point(100, 139), margin: new Padding(100, 15, 0, 5), size: regularBtnSize, text: "Help!"); clearValsBtn = new BaseButton(_res, "clearValsBtn", 5, visStyleBackColor: true, point: new Point(132, 96), size: new Size(120, 23), text: "Clear Values"); saveConnBtn = new BaseButton(_res, "saveConnBtn", 3, visStyleBackColor: true, point: new Point(74, 136), size: largeBtnSize, text: "Save and Connect"); saveVpnNewBtn = new BaseButton(_res, "saveVpnNewBtn", visStyleBackColor: true, point: new Point(6, 96), size: largeBtnSize, text: "Save New / Edited"); vpnsTxtBox = new BaseTextBox(_res, "vpnsTxtBox", 1, defTxtBoxPoint, defTxtBoxSize); vpnNameTxtBox = new BaseTextBox(_res, "vpnNameTxtBox", 1, defTxtBoxPoint, defTxtBoxSize); selectedInfoTxtBox = new BaseRichTextBox(_res, "selectedInfoTxtBox", 1, SystemColors.MenuText, Color.YellowGreen, new Point(6, 31), new Size(212, 134)); selectedsLbl = new BaseLabel(_res, "selectedsLbl", point: new Point(3, 10), size: new Size(108, 18), text: "Selected\'s Info:"); currentVpnsLbl = new BaseLabel(_res, "currentVpnsLbl", point: defLblPoint, size: new Size(103, 18), text: "Current VPNs:"); nameVpnLbl = new BaseLabel(_res, "nameVpnLbl", point: defLblPoint, size: new Size(52, 18), text: "Name:"); addressVpnLbl = new BaseLabel(_res, "addressVpnLbl", point: defLblPoint, size: new Size(66, 18), text: "Address:"); ttypeVpnLbl = new BaseLabel(_res, "tTypeVpnLbl", point: defLblPoint, size: new Size(92, 18), text: "Tunnel Type:"); encryptLvlVpnLbl = new BaseLabel(_res, "encryptLvlVpnLbl", point: defLblPoint, size: new Size(120, 18), text: "Encryption LEvel:"); authMetLbl = new BaseLabel(_res, "authMetLbl", point: defLblPoint, size: new Size(99, 18), text: "Auth. Method:"); currentVpnsComBox = new BaseComboBox(_res, "currentVpnsCombox", 2, defComboPoint, defComboSize); tTypeSelectCombBox = new BaseComboBox(_res, "tTypeSelectComBox", 1, defComboPoint, defComboSize); encryLvlCombBox = new BaseComboBox(_res, "encrLvlComBox", 2, defComboPoint, defComboSize); authMetCombBox = new BaseComboBox(_res, "authMetComBox", 2, defComboPoint, defComboSize); availForAllCheckBox = new BaseCheckBox(_res, "availForAllCheckBox", visStyleBackColor: true, text: "Available for All Users", point: new Point(5, 67), size: new Size(169, 22)); splitTunCheckBox = new BaseCheckBox(_res, "splitTunCheckBox", visStyleBackColor: true, text: "Split Tunnel:", point: new Point(6, 17), size: new Size(103, 22)); #endregion #region Panels bottomInfosPnl = new BaseFlowPanel(_res, "bottomInfosPnl", 2, new Control[] { currOpersPnl, currInfoPnl, currPnl }, new Point(12, 335), new Size(590, 175), borderStyle: BorderStyle.Fixed3D); currOpersPnl = new BaseFlowPanel(_res, "currOpersPnl", 6, new Control[] { selectConnBtn, selectEditBtn, selectRmvBtn, vpnHelpBtn }, new Point(383, 3), new Size(200, 170), flow: FlowDirection.TopDown); vpnSettingsPnl = new BaseFlowPanel(_res, "vpnSettingsPnl", 3, new Control[] { namePnl, addressPnl, tunnelPnl, encryptionPnl, authPnl, btnsTopPnl }, new Point(12, 12), new Size(590, 306)); currInfoPnl = new BasePanel(_res, "currInfoPnl", 5, new Control[] { selectedInfoTxtBox, selectedsLbl }, new Point(150, 3), new Size(231, 170)); currPnl = new BasePanel(_res, "currPnl", 4, new Control[] { currentVpnsComBox, currentVpnsLbl }, new Point(3, 3), new Size(150, 170)); namePnl = new BasePanel(_res, "namePnl", 2, new Control[] { vpnsTxtBox, nameVpnLbl }, new Point(3, 3), defPanelSize); addressPnl = new BasePanel(_res, "addressPnl", 0, new Control[] { vpnNameTxtBox, addressVpnLbl }, new Point(159, 3), defPanelSize); tunnelPnl = new BasePanel(_res, "tunnelPnl", 2, new Control[] { tTypeSelectCombBox, ttypeVpnLbl }, new Point(315, 3), defPanelSize); encryptionPnl = new BasePanel(_res, "encryptionPnl", 3, new Control[] { encryLvlCombBox, encryptLvlVpnLbl }, new Point(3, 109), defPanelSize); authPnl = new BasePanel(_res, "authPnl", 4, new Control[] { authMetCombBox, authMetLbl }, new Point(159, 109), defPanelSize); btnsTopPnl = new BasePanel(_res, "btnSopPnl", 5, new Control[] { clearValsBtn, saveConnBtn, saveVpnNewBtn, availForAllCheckBox, splitTunCheckBox }, new Point(315, 109), new Size(270, 197)); #endregion SuspendLayout(); InitVpnElements(); }
public MaterialComboBox() { SetStyle(ControlStyles.OptimizedDoubleBuffer | ControlStyles.DoubleBuffer, true); animationManager = new AnimationManager { Increment = 0.06, AnimationType = AnimationType.EaseInOut, InterruptAnimation = false }; animationManager.OnAnimationProgress += sender => Invalidate(); baseComboBox = new BaseComboBox { //BorderStyle = BorderStyle.None, Font = SkinManager.ROBOTO_REGULAR_11, ForeColor = SkinManager.GetPrimaryTextColor(), Location = new Point(0, 0), Width = Width, Height = Height - 57, FlatStyle = FlatStyle.Flat, DropDownStyle = ComboBoxStyle.DropDownList //Multiline = false, //TextAlign = HorizontalAlignment.Left }; if (!Controls.Contains(baseComboBox) && !DesignMode) { Controls.Add(baseComboBox); } baseComboBox.GotFocus += (sender, args) => animationManager.StartNewAnimation(AnimationDirection.In); baseComboBox.LostFocus += (sender, args) => animationManager.StartNewAnimation(AnimationDirection.Out); BackColorChanged += (sender, args) => { baseComboBox.BackColor = BackColor; baseComboBox.ForeColor = SkinManager.GetPrimaryTextColor(); }; //Fix for tabstop baseComboBox.TabStop = true; this.TabStop = false; }
/// <summary> /// カレンダーをコンボボックスへ読み込む /// </summary> /// <param name="calendarComboBox"></param> public static void LoadCalendarToComboBox(BaseComboBox calendarComboBox) { try { DbUtil util = DbUtil.GetInstance(); CalendarModel model = new CalendarModel(); model.CalendarId = 0; model.Description = "--未設定--"; calendarComboBox.Items.Add(model); foreach (KeyValuePair <int, object[]> pair in CalendarInfos.GetInstance().CalendarInfoDic) { calendarComboBox.Items.Add((CalendarModel)pair.Value[1]); } } catch (Exception ex) { throw Program.ThrowException(ex); } }
private void CompareSubmitBtn_Click(object sender, EventArgs e) { //if test run is unchosen, alert and focus combo box if (CompareTestComboBox.SelectedIndex == -1) { MessageBox.Show("Please Choose a Test Run", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); CompareTestComboBox.Focus(); } //if base run is unchosen, alert and focus combo box else if (BaseComboBox.SelectedIndex == -1) { MessageBox.Show("Please Choose a Base Run", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); BaseComboBox.Focus(); } else { //run background workers AND compare } }
/// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> void InitializeComponent() { #region Controls loginButton = new BaseButton(_res, "loginButton", backColor: Color.YellowGreen); registerButton = new BaseButton(_res, "registerButton", backColor: Color.DarkTurquoise); quitButton = new BaseButton(_res, "quitButton", backColor: Color.Violet); saveUserInfoChckBox = new BaseCheckBox(_res, "saveUserInfoChkBox", visStyleBackColor: true, text: "Save User Info", alignText: ContentAlignment.MiddleCenter, alignBox: ContentAlignment.MiddleLeft); usersSavedBox = new BaseComboBox(_res, "usersSavedBox"); passwordTxtBox = new BaseTextBox(_res, "passwordTxtBox"); usernameTxtBox = new BaseTextBox(_res, "usernameTxtBox"); #endregion #region Panels loginBottomPanel = new BasePanel(_res, "loginBottomPanel", controls: new Control[] { loginButton, quitButton, registerButton }); loginTopPanel = new BasePanel(_res, "loginTopPanel", controls: new Control[] { saveUserInfoChckBox, passwordTxtBox, usernameTxtBox, usersSavedBox }); #endregion InitLoginWin(); }
/// <summary> /// Required method for Designer support - do not modify /// the contents of this method with the code editor. /// </summary> private void InitializeComponent() { #region Controls var defButtonSize = new Size(80, 23); var defTextBoxSize = new Size(140, 20); var defTextBoxPadding = new Padding(40, 5, 3, 3); var defLabelPadding = new Padding(40, 20, 3, 0); saveProxyBtn = new BaseButton(_res, "saveProxyBtn", 8, visStyleBackColor: true, point: new Point(50, 336), margin: new Padding(50, 30, 3, 3), size: new Size(120, 23), text: "Save to File"); saveNConnectProxyBtn = new BaseButton(_res, "saveNConnectProxyBtn", 9, visStyleBackColor: true, point: new Point(50, 382), margin: new Padding(50, 20, 3, 3), size: new Size(120, 23), text: "Save and Connect"); proxyHelpBtn = new BaseButton(_res, "proxyHelpBtn", 13, visStyleBackColor: true, point: new Point(140, 458), margin: new Padding(140, 50, 3, 3), size: new Size(60, 23), text: "Help!"); connectToSavedBtn = new BaseButton(_res, "connectToSavedBtn", 2, visStyleBackColor: true, point: new Point(70, 320), margin: new Padding(70, 20, 70, 3), size: new Size(80, 23), text: "Connect To"); editSavedBtn = new BaseButton(_res, "editSavedBtn", 3, visStyleBackColor: true, point: new Point(70, 361), margin: new Padding(70, 15, 70, 3), size: new Size(80, 23), text: "Edit"); deleteSavedBtn = new BaseButton(_res, "deleteSavedBtn", 4, visStyleBackColor: true, point: new Point(70, 402), margin: new Padding(70, 15, 70, 3), size: new Size(80, 23), text: "Delete"); selectTextFileBtn = new BaseButton(_res, "selectTextFileBtn", visStyleBackColor: true, point: new Point(20, 78), margin: new Padding(20, 40, 20, 3), size: new Size(100, 23), text: "Select Text File"); helpImportBtn = new BaseButton(_res, "helpImportBtn", 2, visStyleBackColor: true, point: new Point(30, 119), margin: new Padding(30, 15, 30, 3), size: new Size(80, 23), text: "Help!"); ipAddyLbl = new BaseLabel(_res, "ipAddyLbl", 0, new Point(40, 20), new Size(83, 18), "IP Address:", autoSize: true, padding: defLabelPadding); portLbl = new BaseLabel(_res, "portLbl", 11, new Point(40, 86), new Size(40, 18), "Port:", autoSize: true, padding: defLabelPadding); passLbl = new BaseLabel(_res, "passLbl", 4, new Point(40, 218), new Size(79, 18), "Password:"******"uNameLbl", 2, new Point(40, 152), new Size(81, 18), "Username:"******"proxyInfoLbl", 6, new Point(10, 92), new Size(114, 18), "Info of Selected:", autoSize: true, padding: new Padding(10, 20, 10, 0)); savedProxiesLbl = new BaseLabel(_res, "savedProxiesLbl", 5, new Point(10, 20), new Size(107, 18), "Saved Proxies:", autoSize: true, padding: new Padding(10, 20, 3, 0)); importProxiesLbl = new BaseLabel(_res, "importProxiesLbl", 1, new Point(18, 20), new Size(104, 18), "Import Proxies", autoSize: true, padding: new Padding(18, 20, 0, 0)); ipAddyTxtBox = new BaseTextBox(_res, "ipAddyTxtBox", 1, new Point(40, 43), defTextBoxSize, padding: defTextBoxPadding); portTxtBox = new BaseTextBox(_res, "portTxtBox", 12, new Point(40, 109), defTextBoxSize, padding: defTextBoxPadding); uNameTxtBox = new BaseTextBox(_res, "uNameTxtBox", 3, new Point(40, 175), defTextBoxSize, padding: defTextBoxPadding); passTextBox = new BaseTextBox(_res, "passTextBox", 5, new Point(40, 241), defTextBoxSize, padding: defTextBoxPadding); authReqChckBox = new BaseCheckBox(_res, "authReqChckBox", 10, true, "Authorization Required", new Point(40, 284), new Size(151, 19), margin: new Padding(40, 20, 3, 3)); savedProxiesCombBox = new BaseComboBox(_res, "savedProxiesCombBox", 1, new Point(10, 48), new Size(180, 21), new Padding(10, 10, 3, 3)); proxyInfoTxtBox = new BaseRichTextBox(_res, "proxyInfoTxtBox", 0, SystemColors.MenuText, Color.GreenYellow, new Point(10, 120), new Size(200, 177), margin: new Padding(10, 10, 10, 3)); #endregion #region Panels importProxiesPnl = new BaseFlowPanel(_res, "importProxiesPnl", 1, new Control[] { importProxiesLbl, selectTextFileBtn, helpImportBtn }, new Point(12, 12), new Size(140, 498), borderStyle: BorderStyle.Fixed3D, flow: FlowDirection.TopDown); savedProxiesPnl = new BaseFlowPanel(_res, "savedProxiesPnl", 1, new Control[] { savedProxiesLbl, savedProxiesCombBox, proxyInfoLbl, proxyInfoTxtBox, connectToSavedBtn, editSavedBtn, deleteSavedBtn }, new Point(158, 12), new Size(220, 498), borderStyle: BorderStyle.Fixed3D, flow: FlowDirection.TopDown); addNewProxyPnl = new BaseFlowPanel(_res, "addNewProxyPnl", 0, new Control[] { ipAddyLbl, ipAddyTxtBox, portLbl, portTxtBox, uNameLbl, uNameTxtBox, passLbl, passTextBox, authReqChckBox, saveProxyBtn, saveNConnectProxyBtn, proxyHelpBtn }, new Point(384, 12), new Size(220, 498), borderStyle: BorderStyle.Fixed3D, flow: FlowDirection.TopDown); #endregion SuspendLayout(); InitProxy(); }