diff --git a/mRemoteV1/App/Windows.cs b/mRemoteV1/App/Windows.cs index faecf0ed..d12adb4b 100644 --- a/mRemoteV1/App/Windows.cs +++ b/mRemoteV1/App/Windows.cs @@ -18,7 +18,6 @@ namespace mRemoteNG.App private static DockContent _helpPanel = new DockContent(); private static ExternalToolsWindow _externalappsForm; private static DockContent _externalappsPanel = new DockContent(); - private static SSHCommandWIndow _sshcommandForm; private static DockContent _sshcommandPanel = new DockContent(); private static PortScanWindow _portscanForm; private static DockContent _portscanPanel = new DockContent(); @@ -35,8 +34,6 @@ namespace mRemoteNG.App public static DockContent ErrorsPanel { get; set; } = new DockContent(); public static ScreenshotManagerWindow ScreenshotForm { get; set; } public static DockContent ScreenshotPanel { get; set; } = new DockContent(); - public static SSHCommandWIndow SSHCommandForm { get; set; } - public static DockContent SSHCommandPanel { get; set; } = new DockContent(); public static UpdateWindow UpdateForm { get; set; } public static DockContent UpdatePanel { get; set; } = new DockContent(); public static SSHTransferWindow SshtransferForm { get; set; } @@ -104,15 +101,6 @@ namespace mRemoteNG.App } _externalappsForm.Show(frmMain.Default.pnlDock); } - else if (windowType.Equals(WindowType.SSHCommandWindow)) - { - if (_sshcommandForm == null || _sshcommandForm.IsDisposed) - { - _sshcommandForm = new SSHCommandWIndow(_sshcommandPanel); - _sshcommandPanel = _sshcommandForm; - } - _externalappsForm.Show(frmMain.Default.pnlDock); - } else if (windowType.Equals(WindowType.PortScan)) { _portscanForm = new PortScanWindow(_portscanPanel); diff --git a/mRemoteV1/Config/Settings/LayoutSettingsLoader.cs b/mRemoteV1/Config/Settings/LayoutSettingsLoader.cs index b7ecbf5c..1728e8b9 100644 --- a/mRemoteV1/Config/Settings/LayoutSettingsLoader.cs +++ b/mRemoteV1/Config/Settings/LayoutSettingsLoader.cs @@ -76,9 +76,6 @@ namespace mRemoteNG.Config.Settings if (persistString == typeof(ScreenshotManagerWindow).ToString()) return Windows.ScreenshotPanel; - - if (persistString == typeof(SSHCommandWIndow).ToString()) - return Windows.SSHCommandPanel; } catch (Exception ex) { @@ -102,9 +99,6 @@ namespace mRemoteNG.Config.Settings Windows.ScreenshotForm = new ScreenshotManagerWindow(Windows.ScreenshotPanel); Windows.ScreenshotPanel = Windows.ScreenshotForm; - Windows.SSHCommandForm = new SSHCommandWIndow(Windows.SSHCommandPanel); - Windows.SSHCommandPanel = Windows.SSHCommandForm; - Windows.UpdateForm = new UpdateWindow(Windows.UpdatePanel); Windows.UpdatePanel = Windows.UpdateForm; } diff --git a/mRemoteV1/UI/Forms/frmMain.Designer.cs b/mRemoteV1/UI/Forms/frmMain.Designer.cs index 08c8a14b..7d8b6ca8 100644 --- a/mRemoteV1/UI/Forms/frmMain.Designer.cs +++ b/mRemoteV1/UI/Forms/frmMain.Designer.cs @@ -61,7 +61,6 @@ namespace mRemoteNG.UI.Forms this.mMenViewConfig = new System.Windows.Forms.ToolStripMenuItem(); this.mMenViewErrorsAndInfos = new System.Windows.Forms.ToolStripMenuItem(); this.mMenViewScreenshotManager = new System.Windows.Forms.ToolStripMenuItem(); - this.mMenViewMultiPuttyCommand = new System.Windows.Forms.ToolStripMenuItem(); this.ToolStripSeparator1 = new System.Windows.Forms.ToolStripSeparator(); this.mMenViewJumpTo = new System.Windows.Forms.ToolStripMenuItem(); this.mMenViewJumpToConnectionsConfig = new System.Windows.Forms.ToolStripMenuItem(); @@ -70,6 +69,7 @@ namespace mRemoteNG.UI.Forms this.mMenViewSep2 = new System.Windows.Forms.ToolStripSeparator(); this.mMenViewQuickConnectToolbar = new System.Windows.Forms.ToolStripMenuItem(); this.mMenViewExtAppsToolbar = new System.Windows.Forms.ToolStripMenuItem(); + this.mMenViewMultiSSHToolbar = new System.Windows.Forms.ToolStripMenuItem(); this.mMenViewSep3 = new System.Windows.Forms.ToolStripSeparator(); this.mMenViewFullscreen = new System.Windows.Forms.ToolStripMenuItem(); this.mMenTools = new System.Windows.Forms.ToolStripMenuItem(); @@ -103,6 +103,9 @@ namespace mRemoteNG.UI.Forms this.tsExternalTools = new System.Windows.Forms.ToolStrip(); this.cMenExtAppsToolbar = new System.Windows.Forms.ContextMenuStrip(this.components); this.cMenToolbarShowText = new System.Windows.Forms.ToolStripMenuItem(); + this.tsMultiSSH = new System.Windows.Forms.ToolStrip(); + this.lblMultiSSH = new System.Windows.Forms.ToolStripLabel(); + this.txtMultiSSH = new System.Windows.Forms.ToolStripTextBox(); this.tmrAutoSave = new System.Windows.Forms.Timer(this.components); this.msMain.SuspendLayout(); this.tsContainer.ContentPanel.SuspendLayout(); @@ -110,6 +113,7 @@ namespace mRemoteNG.UI.Forms this.tsContainer.SuspendLayout(); this.tsQuickConnect.SuspendLayout(); this.cMenExtAppsToolbar.SuspendLayout(); + this.tsMultiSSH.SuspendLayout(); this.SuspendLayout(); // // pnlDock @@ -121,7 +125,7 @@ namespace mRemoteNG.UI.Forms this.pnlDock.DocumentStyle = WeifenLuo.WinFormsUI.Docking.DocumentStyle.DockingSdi; this.pnlDock.Location = new System.Drawing.Point(0, 0); this.pnlDock.Name = "pnlDock"; - this.pnlDock.Size = new System.Drawing.Size(966, 498); + this.pnlDock.Size = new System.Drawing.Size(1288, 541); this.pnlDock.TabIndex = 13; this.pnlDock.ActiveDocumentChanged += new System.EventHandler(this.pnlDock_ActiveDocumentChanged); // @@ -129,15 +133,16 @@ namespace mRemoteNG.UI.Forms // this.msMain.Dock = System.Windows.Forms.DockStyle.None; this.msMain.GripMargin = new System.Windows.Forms.Padding(0); + this.msMain.ImageScalingSize = new System.Drawing.Size(20, 20); this.msMain.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.mMenFile, this.mMenView, this.mMenTools, this.mMenInfo}); - this.msMain.Location = new System.Drawing.Point(3, 0); + this.msMain.Location = new System.Drawing.Point(3, 75); this.msMain.Name = "msMain"; this.msMain.Padding = new System.Windows.Forms.Padding(2, 2, 0, 2); - this.msMain.Size = new System.Drawing.Size(177, 24); + this.msMain.Size = new System.Drawing.Size(210, 28); this.msMain.Stretch = false; this.msMain.TabIndex = 16; this.msMain.Text = "Main Toolbar"; @@ -164,7 +169,7 @@ namespace mRemoteNG.UI.Forms this.mMenFileSep5, this.mMenFileExit}); this.mMenFile.Name = "mMenFile"; - this.mMenFile.Size = new System.Drawing.Size(37, 20); + this.mMenFile.Size = new System.Drawing.Size(44, 24); this.mMenFile.Text = "&File"; this.mMenFile.DropDownOpening += new System.EventHandler(this.mMenFile_DropDownOpening); // @@ -173,7 +178,7 @@ namespace mRemoteNG.UI.Forms this.mMenFileNewConnection.Image = global::mRemoteNG.Resources.Connection_Add; this.mMenFileNewConnection.Name = "mMenFileNewConnection"; this.mMenFileNewConnection.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.N))); - this.mMenFileNewConnection.Size = new System.Drawing.Size(281, 22); + this.mMenFileNewConnection.Size = new System.Drawing.Size(340, 26); this.mMenFileNewConnection.Text = "New Connection"; this.mMenFileNewConnection.Click += new System.EventHandler(this.mMenFileNewConnection_Click); // @@ -183,20 +188,20 @@ namespace mRemoteNG.UI.Forms this.mMenFileNewFolder.Name = "mMenFileNewFolder"; this.mMenFileNewFolder.ShortcutKeys = ((System.Windows.Forms.Keys)(((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.Shift) | System.Windows.Forms.Keys.N))); - this.mMenFileNewFolder.Size = new System.Drawing.Size(281, 22); + this.mMenFileNewFolder.Size = new System.Drawing.Size(340, 26); this.mMenFileNewFolder.Text = "New Folder"; this.mMenFileNewFolder.Click += new System.EventHandler(this.mMenFileNewFolder_Click); // // mMenFileSep1 // this.mMenFileSep1.Name = "mMenFileSep1"; - this.mMenFileSep1.Size = new System.Drawing.Size(278, 6); + this.mMenFileSep1.Size = new System.Drawing.Size(337, 6); // // mMenFileNew // this.mMenFileNew.Image = global::mRemoteNG.Resources.Connections_New; this.mMenFileNew.Name = "mMenFileNew"; - this.mMenFileNew.Size = new System.Drawing.Size(281, 22); + this.mMenFileNew.Size = new System.Drawing.Size(340, 26); this.mMenFileNew.Text = "New Connection File"; this.mMenFileNew.Click += new System.EventHandler(this.mMenFileNew_Click); // @@ -205,7 +210,7 @@ namespace mRemoteNG.UI.Forms this.mMenFileLoad.Image = global::mRemoteNG.Resources.Connections_Load; this.mMenFileLoad.Name = "mMenFileLoad"; this.mMenFileLoad.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.O))); - this.mMenFileLoad.Size = new System.Drawing.Size(281, 22); + this.mMenFileLoad.Size = new System.Drawing.Size(340, 26); this.mMenFileLoad.Text = "Open Connection File..."; this.mMenFileLoad.Click += new System.EventHandler(this.mMenFileLoad_Click); // @@ -214,7 +219,7 @@ namespace mRemoteNG.UI.Forms this.mMenFileSave.Image = global::mRemoteNG.Resources.Connections_Save; this.mMenFileSave.Name = "mMenFileSave"; this.mMenFileSave.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.S))); - this.mMenFileSave.Size = new System.Drawing.Size(281, 22); + this.mMenFileSave.Size = new System.Drawing.Size(340, 26); this.mMenFileSave.Text = "Save Connection File"; this.mMenFileSave.Click += new System.EventHandler(this.mMenFileSave_Click); // @@ -224,20 +229,20 @@ namespace mRemoteNG.UI.Forms this.mMenFileSaveAs.Name = "mMenFileSaveAs"; this.mMenFileSaveAs.ShortcutKeys = ((System.Windows.Forms.Keys)(((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.Shift) | System.Windows.Forms.Keys.S))); - this.mMenFileSaveAs.Size = new System.Drawing.Size(281, 22); + this.mMenFileSaveAs.Size = new System.Drawing.Size(340, 26); this.mMenFileSaveAs.Text = "Save Connection File As..."; this.mMenFileSaveAs.Click += new System.EventHandler(this.mMenFileSaveAs_Click); // // mMenFileSep2 // this.mMenFileSep2.Name = "mMenFileSep2"; - this.mMenFileSep2.Size = new System.Drawing.Size(278, 6); + this.mMenFileSep2.Size = new System.Drawing.Size(337, 6); // // mMenFileDelete // this.mMenFileDelete.Image = global::mRemoteNG.Resources.Delete; this.mMenFileDelete.Name = "mMenFileDelete"; - this.mMenFileDelete.Size = new System.Drawing.Size(281, 22); + this.mMenFileDelete.Size = new System.Drawing.Size(340, 26); this.mMenFileDelete.Text = "Delete..."; this.mMenFileDelete.Click += new System.EventHandler(this.mMenFileDelete_Click); // @@ -245,7 +250,7 @@ namespace mRemoteNG.UI.Forms // this.mMenFileRename.Image = global::mRemoteNG.Resources.Rename; this.mMenFileRename.Name = "mMenFileRename"; - this.mMenFileRename.Size = new System.Drawing.Size(281, 22); + this.mMenFileRename.Size = new System.Drawing.Size(340, 26); this.mMenFileRename.Text = "Rename"; this.mMenFileRename.Click += new System.EventHandler(this.mMenFileRename_Click); // @@ -253,27 +258,27 @@ namespace mRemoteNG.UI.Forms // this.mMenFileDuplicate.Image = global::mRemoteNG.Resources.page_copy; this.mMenFileDuplicate.Name = "mMenFileDuplicate"; - this.mMenFileDuplicate.Size = new System.Drawing.Size(281, 22); + this.mMenFileDuplicate.Size = new System.Drawing.Size(340, 26); this.mMenFileDuplicate.Text = "Duplicate"; this.mMenFileDuplicate.Click += new System.EventHandler(this.mMenFileDuplicate_Click); // // mMenFileSep4 // this.mMenFileSep4.Name = "mMenFileSep4"; - this.mMenFileSep4.Size = new System.Drawing.Size(278, 6); + this.mMenFileSep4.Size = new System.Drawing.Size(337, 6); // // mMenReconnectAll // this.mMenReconnectAll.Image = global::mRemoteNG.Resources.Refresh; this.mMenReconnectAll.Name = "mMenReconnectAll"; - this.mMenReconnectAll.Size = new System.Drawing.Size(281, 22); + this.mMenReconnectAll.Size = new System.Drawing.Size(340, 26); this.mMenReconnectAll.Text = "Reconnect All Connections"; this.mMenReconnectAll.Click += new System.EventHandler(this.mMenReconnectAll_Click); // // mMenFileSep3 // this.mMenFileSep3.Name = "mMenFileSep3"; - this.mMenFileSep3.Size = new System.Drawing.Size(278, 6); + this.mMenFileSep3.Size = new System.Drawing.Size(337, 6); // // mMenFileImport // @@ -282,48 +287,48 @@ namespace mRemoteNG.UI.Forms this.mMenFileImportFromActiveDirectory, this.mMenFileImportFromPortScan}); this.mMenFileImport.Name = "mMenFileImport"; - this.mMenFileImport.Size = new System.Drawing.Size(281, 22); + this.mMenFileImport.Size = new System.Drawing.Size(340, 26); this.mMenFileImport.Text = "&Import"; // // mMenFileImportFromFile // this.mMenFileImportFromFile.Name = "mMenFileImportFromFile"; - this.mMenFileImportFromFile.Size = new System.Drawing.Size(235, 22); + this.mMenFileImportFromFile.Size = new System.Drawing.Size(284, 26); this.mMenFileImportFromFile.Text = "Import from &File..."; this.mMenFileImportFromFile.Click += new System.EventHandler(this.mMenFileImportFromFile_Click); // // mMenFileImportFromActiveDirectory // this.mMenFileImportFromActiveDirectory.Name = "mMenFileImportFromActiveDirectory"; - this.mMenFileImportFromActiveDirectory.Size = new System.Drawing.Size(235, 22); + this.mMenFileImportFromActiveDirectory.Size = new System.Drawing.Size(284, 26); this.mMenFileImportFromActiveDirectory.Text = "Import from &Active Directory..."; this.mMenFileImportFromActiveDirectory.Click += new System.EventHandler(this.mMenFileImportFromActiveDirectory_Click); // // mMenFileImportFromPortScan // this.mMenFileImportFromPortScan.Name = "mMenFileImportFromPortScan"; - this.mMenFileImportFromPortScan.Size = new System.Drawing.Size(235, 22); + this.mMenFileImportFromPortScan.Size = new System.Drawing.Size(284, 26); this.mMenFileImportFromPortScan.Text = "Import from &Port Scan..."; this.mMenFileImportFromPortScan.Click += new System.EventHandler(this.mMenFileImportFromPortScan_Click); // // mMenFileExport // this.mMenFileExport.Name = "mMenFileExport"; - this.mMenFileExport.Size = new System.Drawing.Size(281, 22); + this.mMenFileExport.Size = new System.Drawing.Size(340, 26); this.mMenFileExport.Text = "&Export to File..."; this.mMenFileExport.Click += new System.EventHandler(this.mMenFileExport_Click); // // mMenFileSep5 // this.mMenFileSep5.Name = "mMenFileSep5"; - this.mMenFileSep5.Size = new System.Drawing.Size(278, 6); + this.mMenFileSep5.Size = new System.Drawing.Size(337, 6); // // mMenFileExit // this.mMenFileExit.Image = global::mRemoteNG.Resources.Quit; this.mMenFileExit.Name = "mMenFileExit"; this.mMenFileExit.ShortcutKeys = ((System.Windows.Forms.Keys)((System.Windows.Forms.Keys.Alt | System.Windows.Forms.Keys.F4))); - this.mMenFileExit.Size = new System.Drawing.Size(281, 22); + this.mMenFileExit.Size = new System.Drawing.Size(340, 26); this.mMenFileExit.Text = "Exit"; this.mMenFileExit.Click += new System.EventHandler(this.mMenFileExit_Click); // @@ -337,17 +342,17 @@ namespace mRemoteNG.UI.Forms this.mMenViewConfig, this.mMenViewErrorsAndInfos, this.mMenViewScreenshotManager, - this.mMenViewMultiPuttyCommand, this.ToolStripSeparator1, this.mMenViewJumpTo, this.mMenViewResetLayout, this.mMenViewSep2, this.mMenViewQuickConnectToolbar, this.mMenViewExtAppsToolbar, + this.mMenViewMultiSSHToolbar, this.mMenViewSep3, this.mMenViewFullscreen}); this.mMenView.Name = "mMenView"; - this.mMenView.Size = new System.Drawing.Size(44, 20); + this.mMenView.Size = new System.Drawing.Size(53, 24); this.mMenView.Text = "&View"; this.mMenView.DropDownOpening += new System.EventHandler(this.mMenView_DropDownOpening); // @@ -355,7 +360,7 @@ namespace mRemoteNG.UI.Forms // this.mMenViewAddConnectionPanel.Image = global::mRemoteNG.Resources.Panel_Add; this.mMenViewAddConnectionPanel.Name = "mMenViewAddConnectionPanel"; - this.mMenViewAddConnectionPanel.Size = new System.Drawing.Size(228, 22); + this.mMenViewAddConnectionPanel.Size = new System.Drawing.Size(279, 26); this.mMenViewAddConnectionPanel.Text = "Add Connection Panel"; this.mMenViewAddConnectionPanel.Click += new System.EventHandler(this.mMenViewAddConnectionPanel_Click); // @@ -363,13 +368,13 @@ namespace mRemoteNG.UI.Forms // this.mMenViewConnectionPanels.Image = global::mRemoteNG.Resources.Panels; this.mMenViewConnectionPanels.Name = "mMenViewConnectionPanels"; - this.mMenViewConnectionPanels.Size = new System.Drawing.Size(228, 22); + this.mMenViewConnectionPanels.Size = new System.Drawing.Size(279, 26); this.mMenViewConnectionPanels.Text = "Connection Panels"; // // mMenViewSep1 // this.mMenViewSep1.Name = "mMenViewSep1"; - this.mMenViewSep1.Size = new System.Drawing.Size(225, 6); + this.mMenViewSep1.Size = new System.Drawing.Size(276, 6); // // mMenViewConnections // @@ -377,7 +382,7 @@ namespace mRemoteNG.UI.Forms this.mMenViewConnections.CheckState = System.Windows.Forms.CheckState.Checked; this.mMenViewConnections.Image = global::mRemoteNG.Resources.Root; this.mMenViewConnections.Name = "mMenViewConnections"; - this.mMenViewConnections.Size = new System.Drawing.Size(228, 22); + this.mMenViewConnections.Size = new System.Drawing.Size(279, 26); this.mMenViewConnections.Text = "Connections"; this.mMenViewConnections.Click += new System.EventHandler(this.mMenViewConnections_Click); // @@ -387,7 +392,7 @@ namespace mRemoteNG.UI.Forms this.mMenViewConfig.CheckState = System.Windows.Forms.CheckState.Checked; this.mMenViewConfig.Image = global::mRemoteNG.Resources.cog; this.mMenViewConfig.Name = "mMenViewConfig"; - this.mMenViewConfig.Size = new System.Drawing.Size(228, 22); + this.mMenViewConfig.Size = new System.Drawing.Size(279, 26); this.mMenViewConfig.Text = "Config"; this.mMenViewConfig.Click += new System.EventHandler(this.mMenViewConfig_Click); // @@ -397,29 +402,22 @@ namespace mRemoteNG.UI.Forms this.mMenViewErrorsAndInfos.CheckState = System.Windows.Forms.CheckState.Checked; this.mMenViewErrorsAndInfos.Image = global::mRemoteNG.Resources.ErrorsAndInfos; this.mMenViewErrorsAndInfos.Name = "mMenViewErrorsAndInfos"; - this.mMenViewErrorsAndInfos.Size = new System.Drawing.Size(228, 22); + this.mMenViewErrorsAndInfos.Size = new System.Drawing.Size(279, 26); this.mMenViewErrorsAndInfos.Text = "Errors and Infos"; this.mMenViewErrorsAndInfos.Click += new System.EventHandler(this.mMenViewErrorsAndInfos_Click); // // mMenViewScreenshotManager // - this.mMenViewScreenshotManager.Image = global::mRemoteNG.Resources.Screenshot; + this.mMenViewScreenshotManager.Image = global::mRemoteNG.Resources.Screenshot; this.mMenViewScreenshotManager.Name = "mMenViewScreenshotManager"; - this.mMenViewScreenshotManager.Size = new System.Drawing.Size(228, 22); + this.mMenViewScreenshotManager.Size = new System.Drawing.Size(279, 26); this.mMenViewScreenshotManager.Text = "Screenshot Manager"; this.mMenViewScreenshotManager.Click += new System.EventHandler(this.mMenViewScreenshotManager_Click); - // - // mMenViewMultiPuttyCommand - // - this.mMenViewMultiPuttyCommand.Name = "mMenViewMultiPuttyCommand"; - this.mMenViewMultiPuttyCommand.Size = new System.Drawing.Size(228, 22); - this.mMenViewMultiPuttyCommand.Text = "Multi Putty Commander"; - this.mMenViewMultiPuttyCommand.Click += new System.EventHandler(this.mMenViewMultiPuttyCommand_Click); // // ToolStripSeparator1 // this.ToolStripSeparator1.Name = "ToolStripSeparator1"; - this.ToolStripSeparator1.Size = new System.Drawing.Size(225, 6); + this.ToolStripSeparator1.Size = new System.Drawing.Size(276, 6); // // mMenViewJumpTo // @@ -428,7 +426,7 @@ namespace mRemoteNG.UI.Forms this.mMenViewJumpToErrorsInfos}); this.mMenViewJumpTo.Image = global::mRemoteNG.Resources.JumpTo; this.mMenViewJumpTo.Name = "mMenViewJumpTo"; - this.mMenViewJumpTo.Size = new System.Drawing.Size(228, 22); + this.mMenViewJumpTo.Size = new System.Drawing.Size(279, 26); this.mMenViewJumpTo.Text = "Jump To"; // // mMenViewJumpToConnectionsConfig @@ -437,7 +435,7 @@ namespace mRemoteNG.UI.Forms this.mMenViewJumpToConnectionsConfig.Name = "mMenViewJumpToConnectionsConfig"; this.mMenViewJumpToConnectionsConfig.ShortcutKeys = ((System.Windows.Forms.Keys)(((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.Alt) | System.Windows.Forms.Keys.C))); - this.mMenViewJumpToConnectionsConfig.Size = new System.Drawing.Size(258, 22); + this.mMenViewJumpToConnectionsConfig.Size = new System.Drawing.Size(309, 26); this.mMenViewJumpToConnectionsConfig.Text = "Connections && Config"; this.mMenViewJumpToConnectionsConfig.Click += new System.EventHandler(this.mMenViewJumpToConnectionsConfig_Click); // @@ -447,7 +445,7 @@ namespace mRemoteNG.UI.Forms this.mMenViewJumpToErrorsInfos.Name = "mMenViewJumpToErrorsInfos"; this.mMenViewJumpToErrorsInfos.ShortcutKeys = ((System.Windows.Forms.Keys)(((System.Windows.Forms.Keys.Control | System.Windows.Forms.Keys.Alt) | System.Windows.Forms.Keys.E))); - this.mMenViewJumpToErrorsInfos.Size = new System.Drawing.Size(258, 22); + this.mMenViewJumpToErrorsInfos.Size = new System.Drawing.Size(309, 26); this.mMenViewJumpToErrorsInfos.Text = "Errors && Infos"; this.mMenViewJumpToErrorsInfos.Click += new System.EventHandler(this.mMenViewJumpToErrorsInfos_Click); // @@ -455,20 +453,20 @@ namespace mRemoteNG.UI.Forms // this.mMenViewResetLayout.Image = global::mRemoteNG.Resources.application_side_tree; this.mMenViewResetLayout.Name = "mMenViewResetLayout"; - this.mMenViewResetLayout.Size = new System.Drawing.Size(228, 22); + this.mMenViewResetLayout.Size = new System.Drawing.Size(279, 26); this.mMenViewResetLayout.Text = "Reset Layout"; this.mMenViewResetLayout.Click += new System.EventHandler(this.mMenViewResetLayout_Click); // // mMenViewSep2 // this.mMenViewSep2.Name = "mMenViewSep2"; - this.mMenViewSep2.Size = new System.Drawing.Size(225, 6); + this.mMenViewSep2.Size = new System.Drawing.Size(276, 6); // // mMenViewQuickConnectToolbar // this.mMenViewQuickConnectToolbar.Image = global::mRemoteNG.Resources.Play_Quick; this.mMenViewQuickConnectToolbar.Name = "mMenViewQuickConnectToolbar"; - this.mMenViewQuickConnectToolbar.Size = new System.Drawing.Size(228, 22); + this.mMenViewQuickConnectToolbar.Size = new System.Drawing.Size(279, 26); this.mMenViewQuickConnectToolbar.Text = "Quick Connect Toolbar"; this.mMenViewQuickConnectToolbar.Click += new System.EventHandler(this.mMenViewQuickConnectToolbar_Click); // @@ -476,21 +474,29 @@ namespace mRemoteNG.UI.Forms // this.mMenViewExtAppsToolbar.Image = global::mRemoteNG.Resources.ExtApp; this.mMenViewExtAppsToolbar.Name = "mMenViewExtAppsToolbar"; - this.mMenViewExtAppsToolbar.Size = new System.Drawing.Size(228, 22); + this.mMenViewExtAppsToolbar.Size = new System.Drawing.Size(279, 26); this.mMenViewExtAppsToolbar.Text = "External Applications Toolbar"; this.mMenViewExtAppsToolbar.Click += new System.EventHandler(this.mMenViewExtAppsToolbar_Click); // + // mMenViewMultiSSHToolbar + // + this.mMenViewMultiSSHToolbar.Image = global::mRemoteNG.Resources.Panels; + this.mMenViewMultiSSHToolbar.Name = "mMenViewMultiSSHToolbar"; + this.mMenViewMultiSSHToolbar.Size = new System.Drawing.Size(279, 26); + this.mMenViewMultiSSHToolbar.Text = "Multi SSH Toolbar"; + this.mMenViewMultiSSHToolbar.Click += new System.EventHandler(this.mMenViewMultiSSHToolbar_Click); + // // mMenViewSep3 // this.mMenViewSep3.Name = "mMenViewSep3"; - this.mMenViewSep3.Size = new System.Drawing.Size(225, 6); + this.mMenViewSep3.Size = new System.Drawing.Size(276, 6); // // mMenViewFullscreen // this.mMenViewFullscreen.Image = global::mRemoteNG.Resources.arrow_out; this.mMenViewFullscreen.Name = "mMenViewFullscreen"; this.mMenViewFullscreen.ShortcutKeys = System.Windows.Forms.Keys.F11; - this.mMenViewFullscreen.Size = new System.Drawing.Size(228, 22); + this.mMenViewFullscreen.Size = new System.Drawing.Size(279, 26); this.mMenViewFullscreen.Text = "Full Screen"; this.mMenViewFullscreen.Click += new System.EventHandler(this.mMenViewFullscreen_Click); // @@ -505,14 +511,14 @@ namespace mRemoteNG.UI.Forms this.mMenToolsComponentsCheck, this.mMenToolsOptions}); this.mMenTools.Name = "mMenTools"; - this.mMenTools.Size = new System.Drawing.Size(48, 20); + this.mMenTools.Size = new System.Drawing.Size(56, 24); this.mMenTools.Text = "&Tools"; // // mMenToolsSSHTransfer // this.mMenToolsSSHTransfer.Image = global::mRemoteNG.Resources.SSHTransfer; this.mMenToolsSSHTransfer.Name = "mMenToolsSSHTransfer"; - this.mMenToolsSSHTransfer.Size = new System.Drawing.Size(184, 22); + this.mMenToolsSSHTransfer.Size = new System.Drawing.Size(224, 26); this.mMenToolsSSHTransfer.Text = "SSH File Transfer"; this.mMenToolsSSHTransfer.Click += new System.EventHandler(this.mMenToolsSSHTransfer_Click); // @@ -520,7 +526,7 @@ namespace mRemoteNG.UI.Forms // this.mMenToolsUVNCSC.Image = global::mRemoteNG.Resources.UVNC_SC; this.mMenToolsUVNCSC.Name = "mMenToolsUVNCSC"; - this.mMenToolsUVNCSC.Size = new System.Drawing.Size(184, 22); + this.mMenToolsUVNCSC.Size = new System.Drawing.Size(224, 26); this.mMenToolsUVNCSC.Text = "UltraVNC SingleClick"; this.mMenToolsUVNCSC.Visible = false; this.mMenToolsUVNCSC.Click += new System.EventHandler(this.mMenToolsUVNCSC_Click); @@ -529,7 +535,7 @@ namespace mRemoteNG.UI.Forms // this.mMenToolsExternalApps.Image = global::mRemoteNG.Resources.ExtApp; this.mMenToolsExternalApps.Name = "mMenToolsExternalApps"; - this.mMenToolsExternalApps.Size = new System.Drawing.Size(184, 22); + this.mMenToolsExternalApps.Size = new System.Drawing.Size(224, 26); this.mMenToolsExternalApps.Text = "External Applications"; this.mMenToolsExternalApps.Click += new System.EventHandler(this.mMenToolsExternalApps_Click); // @@ -537,20 +543,20 @@ namespace mRemoteNG.UI.Forms // this.mMenToolsPortScan.Image = global::mRemoteNG.Resources.PortScan; this.mMenToolsPortScan.Name = "mMenToolsPortScan"; - this.mMenToolsPortScan.Size = new System.Drawing.Size(184, 22); + this.mMenToolsPortScan.Size = new System.Drawing.Size(224, 26); this.mMenToolsPortScan.Text = "Port Scan"; this.mMenToolsPortScan.Click += new System.EventHandler(this.mMenToolsPortScan_Click); // // mMenToolsSep1 // this.mMenToolsSep1.Name = "mMenToolsSep1"; - this.mMenToolsSep1.Size = new System.Drawing.Size(181, 6); + this.mMenToolsSep1.Size = new System.Drawing.Size(221, 6); // // mMenToolsComponentsCheck // this.mMenToolsComponentsCheck.Image = global::mRemoteNG.Resources.cog_error; this.mMenToolsComponentsCheck.Name = "mMenToolsComponentsCheck"; - this.mMenToolsComponentsCheck.Size = new System.Drawing.Size(184, 22); + this.mMenToolsComponentsCheck.Size = new System.Drawing.Size(224, 26); this.mMenToolsComponentsCheck.Text = "Components Check"; this.mMenToolsComponentsCheck.Click += new System.EventHandler(this.mMenToolsComponentsCheck_Click); // @@ -558,7 +564,7 @@ namespace mRemoteNG.UI.Forms // this.mMenToolsOptions.Image = global::mRemoteNG.Resources.Options; this.mMenToolsOptions.Name = "mMenToolsOptions"; - this.mMenToolsOptions.Size = new System.Drawing.Size(184, 22); + this.mMenToolsOptions.Size = new System.Drawing.Size(224, 26); this.mMenToolsOptions.Text = "Options"; this.mMenToolsOptions.Click += new System.EventHandler(this.mMenToolsOptions_Click); // @@ -576,29 +582,29 @@ namespace mRemoteNG.UI.Forms this.mMenInfoSep2, this.mMenInfoAbout}); this.mMenInfo.Name = "mMenInfo"; - this.mMenInfo.Size = new System.Drawing.Size(44, 20); + this.mMenInfo.Size = new System.Drawing.Size(53, 24); this.mMenInfo.Text = "&Help"; this.mMenInfo.TextDirection = System.Windows.Forms.ToolStripTextDirection.Horizontal; // // mMenInfoHelp // - this.mMenInfoHelp.Image = global::mRemoteNG.Resources.Help; + this.mMenInfoHelp.Image = global::mRemoteNG.Resources.Help; this.mMenInfoHelp.Name = "mMenInfoHelp"; this.mMenInfoHelp.ShortcutKeys = System.Windows.Forms.Keys.F1; - this.mMenInfoHelp.Size = new System.Drawing.Size(190, 22); + this.mMenInfoHelp.Size = new System.Drawing.Size(230, 26); this.mMenInfoHelp.Text = "mRemoteNG Help"; this.mMenInfoHelp.Click += new System.EventHandler(this.mMenInfoHelp_Click); // // mMenInfoSep1 // this.mMenInfoSep1.Name = "mMenInfoSep1"; - this.mMenInfoSep1.Size = new System.Drawing.Size(187, 6); + this.mMenInfoSep1.Size = new System.Drawing.Size(227, 6); // // mMenInfoWebsite // - this.mMenInfoWebsite.Image = global::mRemoteNG.Resources.Website; + this.mMenInfoWebsite.Image = global::mRemoteNG.Resources.Website; this.mMenInfoWebsite.Name = "mMenInfoWebsite"; - this.mMenInfoWebsite.Size = new System.Drawing.Size(190, 22); + this.mMenInfoWebsite.Size = new System.Drawing.Size(230, 26); this.mMenInfoWebsite.Text = "Website"; this.mMenInfoWebsite.Click += new System.EventHandler(this.mMenInfoWebsite_Click); // @@ -606,7 +612,7 @@ namespace mRemoteNG.UI.Forms // this.mMenInfoDonate.Image = global::mRemoteNG.Resources.Donate; this.mMenInfoDonate.Name = "mMenInfoDonate"; - this.mMenInfoDonate.Size = new System.Drawing.Size(190, 22); + this.mMenInfoDonate.Size = new System.Drawing.Size(230, 26); this.mMenInfoDonate.Text = "Donate"; this.mMenInfoDonate.Click += new System.EventHandler(this.mMenInfoDonate_Click); // @@ -614,7 +620,7 @@ namespace mRemoteNG.UI.Forms // this.mMenInfoForum.Image = global::mRemoteNG.Resources.user_comment; this.mMenInfoForum.Name = "mMenInfoForum"; - this.mMenInfoForum.Size = new System.Drawing.Size(190, 22); + this.mMenInfoForum.Size = new System.Drawing.Size(230, 26); this.mMenInfoForum.Text = "Support Forum"; this.mMenInfoForum.Click += new System.EventHandler(this.mMenInfoForum_Click); // @@ -622,33 +628,33 @@ namespace mRemoteNG.UI.Forms // this.mMenInfoBugReport.Image = global::mRemoteNG.Resources.Bug; this.mMenInfoBugReport.Name = "mMenInfoBugReport"; - this.mMenInfoBugReport.Size = new System.Drawing.Size(190, 22); + this.mMenInfoBugReport.Size = new System.Drawing.Size(230, 26); this.mMenInfoBugReport.Text = "Report a Bug"; this.mMenInfoBugReport.Click += new System.EventHandler(this.mMenInfoBugReport_Click); // // ToolStripSeparator2 // this.ToolStripSeparator2.Name = "ToolStripSeparator2"; - this.ToolStripSeparator2.Size = new System.Drawing.Size(187, 6); + this.ToolStripSeparator2.Size = new System.Drawing.Size(227, 6); // // mMenToolsUpdate // this.mMenToolsUpdate.Image = global::mRemoteNG.Resources.Update; this.mMenToolsUpdate.Name = "mMenToolsUpdate"; - this.mMenToolsUpdate.Size = new System.Drawing.Size(190, 22); + this.mMenToolsUpdate.Size = new System.Drawing.Size(230, 26); this.mMenToolsUpdate.Text = "Check for Updates"; this.mMenToolsUpdate.Click += new System.EventHandler(this.mMenToolsUpdate_Click); // // mMenInfoSep2 // this.mMenInfoSep2.Name = "mMenInfoSep2"; - this.mMenInfoSep2.Size = new System.Drawing.Size(187, 6); + this.mMenInfoSep2.Size = new System.Drawing.Size(227, 6); // // mMenInfoAbout // this.mMenInfoAbout.Image = global::mRemoteNG.Resources.mRemote; this.mMenInfoAbout.Name = "mMenInfoAbout"; - this.mMenInfoAbout.Size = new System.Drawing.Size(190, 22); + this.mMenInfoAbout.Size = new System.Drawing.Size(230, 26); this.mMenInfoAbout.Text = "About mRemoteNG"; this.mMenInfoAbout.Click += new System.EventHandler(this.mMenInfoAbout_Click); // @@ -660,7 +666,7 @@ namespace mRemoteNG.UI.Forms // lblQuickConnect // this.lblQuickConnect.Name = "lblQuickConnect"; - this.lblQuickConnect.Size = new System.Drawing.Size(55, 22); + this.lblQuickConnect.Size = new System.Drawing.Size(66, 22); this.lblQuickConnect.Text = "&Connect:"; this.lblQuickConnect.Click += new System.EventHandler(this.lblQuickConnect_Click); // @@ -680,23 +686,25 @@ namespace mRemoteNG.UI.Forms // tsContainer.ContentPanel // this.tsContainer.ContentPanel.Controls.Add(this.pnlDock); - this.tsContainer.ContentPanel.Size = new System.Drawing.Size(966, 498); + this.tsContainer.ContentPanel.Size = new System.Drawing.Size(1288, 541); this.tsContainer.Dock = System.Windows.Forms.DockStyle.Fill; this.tsContainer.Location = new System.Drawing.Point(0, 0); this.tsContainer.Name = "tsContainer"; - this.tsContainer.Size = new System.Drawing.Size(966, 523); + this.tsContainer.Size = new System.Drawing.Size(1288, 644); this.tsContainer.TabIndex = 17; this.tsContainer.Text = "ToolStripContainer1"; // // tsContainer.TopToolStripPanel // - this.tsContainer.TopToolStripPanel.Controls.Add(this.msMain); this.tsContainer.TopToolStripPanel.Controls.Add(this.tsQuickConnect); this.tsContainer.TopToolStripPanel.Controls.Add(this.tsExternalTools); + this.tsContainer.TopToolStripPanel.Controls.Add(this.tsMultiSSH); + this.tsContainer.TopToolStripPanel.Controls.Add(this.msMain); // // tsQuickConnect // this.tsQuickConnect.Dock = System.Windows.Forms.DockStyle.None; + this.tsQuickConnect.ImageScalingSize = new System.Drawing.Size(20, 20); this.tsQuickConnect.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.lblQuickConnect, this.cmbQuickConnect, @@ -705,7 +713,7 @@ namespace mRemoteNG.UI.Forms this.tsQuickConnect.Location = new System.Drawing.Point(msMain.Location.X + msMain.Width + 1, 0); this.tsQuickConnect.MaximumSize = new System.Drawing.Size(0, 25); this.tsQuickConnect.Name = "tsQuickConnect"; - this.tsQuickConnect.Size = new System.Drawing.Size(387, 25); + this.tsQuickConnect.Size = new System.Drawing.Size(417, 25); this.tsQuickConnect.TabIndex = 18; // // btnQuickConnect @@ -715,13 +723,14 @@ namespace mRemoteNG.UI.Forms this.btnQuickConnect.ImageTransparentColor = System.Drawing.Color.Magenta; this.btnQuickConnect.Margin = new System.Windows.Forms.Padding(0, 1, 3, 2); this.btnQuickConnect.Name = "btnQuickConnect"; - this.btnQuickConnect.Size = new System.Drawing.Size(84, 22); + this.btnQuickConnect.Size = new System.Drawing.Size(102, 22); this.btnQuickConnect.Text = "Connect"; this.btnQuickConnect.ButtonClick += new System.EventHandler(this.btnQuickConnect_ButtonClick); this.btnQuickConnect.DropDownItemClicked += new System.Windows.Forms.ToolStripItemClickedEventHandler(this.btnQuickConnect_DropDownItemClicked); // // mnuQuickConnectProtocol // + this.mnuQuickConnectProtocol.ImageScalingSize = new System.Drawing.Size(20, 20); this.mnuQuickConnectProtocol.Name = "mnuQuickConnectProtocol"; this.mnuQuickConnectProtocol.OwnerItem = this.btnQuickConnect; this.mnuQuickConnectProtocol.ShowCheckMargin = true; @@ -736,12 +745,13 @@ namespace mRemoteNG.UI.Forms this.btnConnections.ImageScaling = System.Windows.Forms.ToolStripItemImageScaling.None; this.btnConnections.ImageTransparentColor = System.Drawing.Color.Magenta; this.btnConnections.Name = "btnConnections"; - this.btnConnections.Size = new System.Drawing.Size(29, 22); + this.btnConnections.Size = new System.Drawing.Size(30, 22); this.btnConnections.Text = "Connections"; this.btnConnections.DropDownOpening += new System.EventHandler(this.btnConnections_DropDownOpening); // // mnuConnections // + this.mnuConnections.ImageScalingSize = new System.Drawing.Size(20, 20); this.mnuConnections.Name = "mnuConnections"; this.mnuConnections.OwnerItem = this.btnConnections; this.mnuConnections.Size = new System.Drawing.Size(61, 4); @@ -750,6 +760,7 @@ namespace mRemoteNG.UI.Forms // this.tsExternalTools.ContextMenuStrip = this.cMenExtAppsToolbar; this.tsExternalTools.Dock = System.Windows.Forms.DockStyle.None; + this.tsExternalTools.ImageScalingSize = new System.Drawing.Size(20, 20); this.tsExternalTools.Location = new System.Drawing.Point(tsQuickConnect.Location.X + tsQuickConnect.Width + 1, 0); this.tsExternalTools.MaximumSize = new System.Drawing.Size(0, 25); this.tsExternalTools.Name = "tsExternalTools"; @@ -758,20 +769,49 @@ namespace mRemoteNG.UI.Forms // // cMenExtAppsToolbar // + this.cMenExtAppsToolbar.ImageScalingSize = new System.Drawing.Size(20, 20); this.cMenExtAppsToolbar.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { this.cMenToolbarShowText}); this.cMenExtAppsToolbar.Name = "cMenToolbar"; - this.cMenExtAppsToolbar.Size = new System.Drawing.Size(129, 26); + this.cMenExtAppsToolbar.Size = new System.Drawing.Size(146, 30); // // cMenToolbarShowText // this.cMenToolbarShowText.Checked = true; this.cMenToolbarShowText.CheckState = System.Windows.Forms.CheckState.Checked; this.cMenToolbarShowText.Name = "cMenToolbarShowText"; - this.cMenToolbarShowText.Size = new System.Drawing.Size(128, 22); + this.cMenToolbarShowText.Size = new System.Drawing.Size(145, 26); this.cMenToolbarShowText.Text = "Show Text"; this.cMenToolbarShowText.Click += new System.EventHandler(this.cMenToolbarShowText_Click); // + // tsMultiSSH + // + this.tsMultiSSH.ImageScalingSize = new System.Drawing.Size(20, 20); + this.tsMultiSSH.Items.AddRange(new System.Windows.Forms.ToolStripItem[] { + this.lblMultiSSH, + this.txtMultiSSH}); + this.tsMultiSSH.Location = new System.Drawing.Point(tsQuickConnect.Location.X + tsQuickConnect.Width + 1, 0); + this.tsMultiSSH.MinimumSize = new System.Drawing.Size(300, 0); + this.tsMultiSSH.Name = "tsMultiSSH"; + this.tsMultiSSH.Size = new System.Drawing.Size(430, 25); + this.tsMultiSSH.TabIndex = 0; + this.tsMultiSSH.Dock = System.Windows.Forms.DockStyle.Right; + // + // lblMultiSSH + // + this.lblMultiSSH.Name = "lblMultiSSH"; + this.lblMultiSSH.Size = new System.Drawing.Size(77, 22); + this.lblMultiSSH.Text = "Multi SSH:"; + // + // txtMultiSSH + // + this.txtMultiSSH.Name = "txtMultiSSH"; + this.txtMultiSSH.Size = new System.Drawing.Size(300, 25); + this.txtMultiSSH.ToolTipText = "Press ENTER to send. Ctrl+C is sent immediately."; + this.txtMultiSSH.Enter += new System.EventHandler(this.txtMultiSSH_Enter); + this.txtMultiSSH.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txtMultiSSH_KeyDown); + this.txtMultiSSH.KeyUp += new System.Windows.Forms.KeyEventHandler(this.txtMultiSSH_KeyUp); + // // tmrAutoSave // this.tmrAutoSave.Interval = 10000; @@ -779,9 +819,9 @@ namespace mRemoteNG.UI.Forms // // frmMain // - this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); + this.AutoScaleDimensions = new System.Drawing.SizeF(8F, 16F); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; - this.ClientSize = new System.Drawing.Size(966, 523); + this.ClientSize = new System.Drawing.Size(1288, 644); this.Controls.Add(this.tsContainer); this.Icon = global::mRemoteNG.Resources.mRemote_Icon; this.MainMenuStrip = this.msMain; @@ -804,6 +844,8 @@ namespace mRemoteNG.UI.Forms this.tsQuickConnect.ResumeLayout(false); this.tsQuickConnect.PerformLayout(); this.cMenExtAppsToolbar.ResumeLayout(false); + this.tsMultiSSH.ResumeLayout(false); + this.tsMultiSSH.PerformLayout(); this.ResumeLayout(false); } @@ -847,11 +889,12 @@ namespace mRemoteNG.UI.Forms internal System.Windows.Forms.ToolStripMenuItem mMenToolsPortScan; internal System.Windows.Forms.ToolStrip tsQuickConnect; internal System.Windows.Forms.ToolStripMenuItem mMenViewQuickConnectToolbar; - internal System.Windows.Forms.ToolStripSeparator mMenSep3; + internal System.Windows.Forms.ToolStrip tsMultiSSH; + internal System.Windows.Forms.ToolStripMenuItem mMenViewMultiSSHToolbar; + internal System.Windows.Forms.ToolStripSeparator mMenSep3; internal System.Windows.Forms.ToolStripMenuItem mMenInfoDonate; internal System.Windows.Forms.ToolStripSeparator mMenViewSep3; internal ToolStripSplitButton btnQuickConnect; - internal System.Windows.Forms.ToolStripMenuItem mMenViewMultiPuttyCommand; internal System.Windows.Forms.ToolStripMenuItem mMenViewJumpTo; internal System.Windows.Forms.ToolStripMenuItem mMenViewJumpToConnectionsConfig; internal System.Windows.Forms.ToolStripMenuItem mMenViewJumpToErrorsInfos; @@ -883,5 +926,7 @@ namespace mRemoteNG.UI.Forms internal System.Windows.Forms.ToolStripMenuItem mMenFileImportFromPortScan; internal System.Windows.Forms.ToolStripMenuItem mMenFileImport; private System.ComponentModel.IContainer components; + private System.Windows.Forms.ToolStripLabel lblMultiSSH; + private System.Windows.Forms.ToolStripTextBox txtMultiSSH; } } diff --git a/mRemoteV1/UI/Forms/frmMain.cs b/mRemoteV1/UI/Forms/frmMain.cs index 316df31c..9b085fc4 100644 --- a/mRemoteV1/UI/Forms/frmMain.cs +++ b/mRemoteV1/UI/Forms/frmMain.cs @@ -46,9 +46,6 @@ namespace mRemoteNG.UI.Forms private ConnectionTreeWindow ConnectionTreeWindow { get; set; } private readonly IConnectionInitiator _connectionInitiator = new ConnectionInitiator(); - - - private frmMain() { _showFullPathInTitle = Settings.Default.ShowCompleteConsPathInTitle; @@ -253,6 +250,7 @@ namespace mRemoteNG.UI.Forms mMenViewResetLayout.Text = Language.strMenuResetLayout; mMenViewQuickConnectToolbar.Text = Language.strMenuQuickConnectToolbar; mMenViewExtAppsToolbar.Text = Language.strMenuExternalToolsToolbar; + mMenViewMultiSSHToolbar.Text = "Multi SSH Toolbar"; // TODO: Figure out how to put in language text mMenViewFullscreen.Text = Language.strMenuFullScreen; mMenTools.Text = Language.strMenuTools; @@ -300,9 +298,12 @@ namespace mRemoteNG.UI.Forms tsExternalTools.ForeColor = ThemeManager.ActiveTheme.ToolbarTextColor; tsQuickConnect.BackColor = ThemeManager.ActiveTheme.ToolbarBackgroundColor; tsQuickConnect.ForeColor = ThemeManager.ActiveTheme.ToolbarTextColor; - } - - private static void ApplyMenuColors(IEnumerable itemCollection) + tsMultiSSH.BackColor = ThemeManager.ActiveTheme.ToolbarBackgroundColor; + tsMultiSSH.ForeColor = ThemeManager.ActiveTheme.ToolbarTextColor; + + } + + private static void ApplyMenuColors(IEnumerable itemCollection) { foreach (ToolStripItem item in itemCollection) { @@ -705,10 +706,10 @@ namespace mRemoteNG.UI.Forms mMenViewConfig.Checked = !Windows.ConfigForm.IsHidden; mMenViewErrorsAndInfos.Checked = !Windows.ErrorsForm.IsHidden; mMenViewScreenshotManager.Checked = !Windows.ScreenshotForm.IsHidden; - mMenViewMultiPuttyCommand.Checked = !Windows.SSHCommandPanel.IsHidden; mMenViewExtAppsToolbar.Checked = tsExternalTools.Visible; mMenViewQuickConnectToolbar.Checked = tsQuickConnect.Visible; + mMenViewMultiSSHToolbar.Checked = tsMultiSSH.Visible; mMenViewConnectionPanels.DropDownItems.Clear(); @@ -784,20 +785,6 @@ namespace mRemoteNG.UI.Forms } } - private void mMenViewMultiPuttyCommand_Click(object sender, EventArgs e) - { - if (mMenViewMultiPuttyCommand.Checked == false) - { - Windows.SSHCommandPanel.Show(pnlDock); - mMenViewMultiPuttyCommand.Checked = true; - } - else - { - Windows.SSHCommandPanel.Hide(); - mMenViewMultiPuttyCommand.Checked = false; - } - } - private void mMenViewJumpToConnectionsConfig_Click(object sender, EventArgs e) { if (pnlDock.ActiveContent == Windows.TreePanel) @@ -858,6 +845,20 @@ namespace mRemoteNG.UI.Forms } } + private void mMenViewMultiSSHToolbar_Click(object sender, EventArgs e) + { + if (mMenViewMultiSSHToolbar.Checked == false) + { + tsMultiSSH.Visible = true; + mMenViewMultiSSHToolbar.Checked = true; + } + else + { + tsMultiSSH.Visible = false; + mMenViewMultiSSHToolbar.Checked = false; + } + } + private void mMenViewFullscreen_Click(object sender, EventArgs e) { _fullscreen.Value = !_fullscreen.Value; @@ -976,6 +977,106 @@ namespace mRemoteNG.UI.Forms } #endregion + #region Multi SSH + private ArrayList processHandlers = new ArrayList(); + private ArrayList previousCommands = new ArrayList(); + private int previousCommandIndex = 0; + + private void txtMultiSSH_Enter(object sender, EventArgs e) + { + var previouslyOpenedConnections = Runtime.ConnectionTreeModel.GetRecursiveChildList().Where(item => item.OpenConnections.Count > 0); + + processHandlers.Clear(); + foreach (ConnectionInfo connection in previouslyOpenedConnections) + { + foreach (ProtocolBase _base in connection.OpenConnections) + { + if (_base.GetType().IsSubclassOf(typeof(PuttyBase))) + { + processHandlers.Add((PuttyBase)_base); + } + } + } + } + + private void txtMultiSSH_KeyDown(object sender, KeyEventArgs e) + { + if (processHandlers.Count == 0) + { + e.SuppressKeyPress = true; + return; + } + + if (e.KeyCode == Keys.Up || e.KeyCode == Keys.Down) + { + e.SuppressKeyPress = true; + if (e.KeyCode == Keys.Up && previousCommandIndex - 1 >= 0) + { + previousCommandIndex -= 1; + } + + if (e.KeyCode == Keys.Down && previousCommandIndex + 1 < previousCommands.Count) + { + previousCommandIndex += 1; + } + + txtMultiSSH.Text = previousCommands[previousCommandIndex].ToString(); + txtMultiSSH.Select(txtMultiSSH.TextLength, 0); + } + + if (e.Control == true && e.KeyCode != Keys.V && e.Alt == false) + { + sendAllKey(NativeMethods.WM_KEYDOWN, e.KeyValue); + } + + if (e.KeyCode == Keys.Enter) + { + string strLine = txtMultiSSH.Text; + foreach (char chr1 in strLine) + { + sendAllKey(NativeMethods.WM_CHAR, Convert.ToByte(chr1)); + } + sendAllKey(NativeMethods.WM_KEYDOWN, 13); // Enter = char13 + } + } + + private void saveLastCommand() + { + if (txtMultiSSH.Text.Trim() != "") + { + previousCommands.Add(txtMultiSSH.Text.Trim()); + } + if (previousCommands.Count >= 100) + { + // Don't keep too many. TODO: make this configurable + previousCommands.RemoveAt(0); + } + + previousCommandIndex = previousCommands.Count - 1; + txtMultiSSH.Clear(); + } + + private void sendAllKey(int keyType, int keyData) + { + if (processHandlers.Count == 0) + { + return; + } + foreach (PuttyBase proc in processHandlers) + { + NativeMethods.PostMessage(proc.PuttyHandle, keyType, new IntPtr(keyData), new IntPtr(0)); + } + } + + private void txtMultiSSH_KeyUp(object sender, KeyEventArgs e) + { + if (e.KeyCode == Keys.Enter) + { + saveLastCommand(); + } + } + #endregion + #region Info private void mMenInfoHelp_Click(object sender, EventArgs e) { diff --git a/mRemoteV1/UI/Forms/frmMain.resx b/mRemoteV1/UI/Forms/frmMain.resx index f820bb6d..011612f2 100644 --- a/mRemoteV1/UI/Forms/frmMain.resx +++ b/mRemoteV1/UI/Forms/frmMain.resx @@ -118,24 +118,27 @@ System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - 17, 17 + 148, 17 - 112, 17 - - - 249, 17 - - - 447, 17 + 259, 17 - 591, 17 + 835, 17 - 724, 17 + 994, 17 + + + 17, 17 + + + 423, 17 + + + 663, 17 - 891, 17 + 1195, 17 \ No newline at end of file diff --git a/mRemoteV1/UI/Window/SSHCommandWIndow.Designer.cs b/mRemoteV1/UI/Window/SSHCommandWIndow.Designer.cs deleted file mode 100644 index 5a8649de..00000000 --- a/mRemoteV1/UI/Window/SSHCommandWIndow.Designer.cs +++ /dev/null @@ -1,75 +0,0 @@ -namespace mRemoteNG.UI.Window -{ - partial class SSHCommandWIndow - { - /// - /// Required designer variable. - /// - private System.ComponentModel.IContainer components = null; - - /// - /// Clean up any resources being used. - /// - /// true if managed resources should be disposed; otherwise, false. - protected override void Dispose(bool disposing) - { - if (disposing && (components != null)) - { - components.Dispose(); - } - base.Dispose(disposing); - } - - #region Windows Form Designer generated code - - /// - /// Required method for Designer support - do not modify - /// the contents of this method with the code editor. - /// - private void InitializeComponent() - { - this.txtSSHCommand = new System.Windows.Forms.RichTextBox(); - this.lstCommands = new System.Windows.Forms.ListBox(); - this.SuspendLayout(); - // - // txtSSHCommand - // - this.txtSSHCommand.Dock = System.Windows.Forms.DockStyle.Fill; - this.txtSSHCommand.Location = new System.Drawing.Point(0, 0); - this.txtSSHCommand.MinimumSize = new System.Drawing.Size(0, 150); - this.txtSSHCommand.Name = "txtSSHCommand"; - this.txtSSHCommand.Size = new System.Drawing.Size(821, 532); - this.txtSSHCommand.TabIndex = 0; - this.txtSSHCommand.Text = ""; - this.txtSSHCommand.Enter += new System.EventHandler(this.txtSSHCommand_Enter); - this.txtSSHCommand.KeyDown += new System.Windows.Forms.KeyEventHandler(this.txtSSHCommand_KeyDown); - this.txtSSHCommand.KeyUp += new System.Windows.Forms.KeyEventHandler(this.txtSSHCommand_KeyUp); - // - // lstCommands - // - this.lstCommands.Dock = System.Windows.Forms.DockStyle.Right; - this.lstCommands.FormattingEnabled = true; - this.lstCommands.ItemHeight = 16; - this.lstCommands.Location = new System.Drawing.Point(701, 0); - this.lstCommands.Name = "lstCommands"; - this.lstCommands.Size = new System.Drawing.Size(120, 532); - this.lstCommands.TabIndex = 1; - this.lstCommands.Visible = false; - // - // SSHCommandWIndow - // - this.ClientSize = new System.Drawing.Size(821, 532); - this.Controls.Add(this.lstCommands); - this.Controls.Add(this.txtSSHCommand); - this.Font = new System.Drawing.Font("Microsoft Sans Serif", 7.8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); - this.Name = "SSHCommandWIndow"; - this.ResumeLayout(false); - - } - - #endregion - - private System.Windows.Forms.RichTextBox txtSSHCommand; - private System.Windows.Forms.ListBox lstCommands; - } -} \ No newline at end of file diff --git a/mRemoteV1/UI/Window/SSHCommandWIndow.cs b/mRemoteV1/UI/Window/SSHCommandWIndow.cs deleted file mode 100644 index 922f92fc..00000000 --- a/mRemoteV1/UI/Window/SSHCommandWIndow.cs +++ /dev/null @@ -1,160 +0,0 @@ -using System; -using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Windows.Forms; -using WeifenLuo.WinFormsUI.Docking; -using mRemoteNG.Connection.Protocol; -using mRemoteNG.App; -using System.Collections; -using mRemoteNG.Connection; - -namespace mRemoteNG.UI.Window -{ - public partial class SSHCommandWIndow : BaseWindow - { - - public SSHCommandWIndow(DockContent panel) - { - InitializeComponent(); - - WindowType = WindowType.SSHCommandWindow; - DockPnl = panel; - - HideOnClose = true; - Icon = Resources.Screenshot_Icon; - Name = "SSHCommander"; - TabText = "Multi-SSH"; - Text = "Multi-SSH Commander"; - } - - #region Private Fields - private ArrayList processHandlers = new ArrayList(); - #endregion - - #region Public Methods - #region Event Handlers - private void SSHCommandWindow_Load(object sender, EventArgs e) - { - Control.CheckForIllegalCrossThreadCalls = false; - } - - #endregion - - private void txtSSHCommand_Enter(object sender, EventArgs e) - { - try - { - var connectionInfoList = Runtime.ConnectionTreeModel.GetRecursiveChildList(); - //.Where( node-> !(node is Container.ContainerInfo)); - var previouslyOpenedConnections = connectionInfoList.Where(item => item.OpenConnections.Count > 0); - - //var connectionInfoList = connectionTree.GetRootConnectionNode().GetRecursiveChildList().Where(node => !(node is ContainerInfo)); - //var previouslyOpenedConnections = connectionInfoList.Where(item => item.PleaseConnect); - //foreach (var connectionInfo in previouslyOpenedConnections) - //{ - // _connectionInitiator.OpenConnection(connectionInfo); - //} - - - - processHandlers.Clear(); - foreach (ConnectionInfo connection in previouslyOpenedConnections) - { - foreach (ProtocolBase _base in connection.OpenConnections) - { - if (_base.GetType().IsSubclassOf(typeof(PuttyBase))) - { - processHandlers.Add((PuttyBase)_base); - } - } - } - } - catch (Exception ex) - { - - } - } - - private void txtSSHCommand_KeyDown(object sender, KeyEventArgs e) - { - if (processHandlers.Count == 0) - { - e.SuppressKeyPress = true; - return; - } - - if (e.KeyCode == Keys.Up || e.KeyCode == Keys.Down) - { - e.SuppressKeyPress = true; - //string lastCommand = ""; - //if (lstCommands.SelectedIndex == lstCommands.Items.Count) - //{ - // lastCommand = lstCommands.Items[lstCommands.Items.Count].ToString(); - //} - - if (e.KeyCode == Keys.Up && lstCommands.SelectedIndex -1 > -1 && lstCommands.SelectedItem.ToString() == txtSSHCommand.Text) - { - lstCommands.SelectedIndex -= 1; - } - - if (e.KeyCode == Keys.Down && lstCommands.SelectedIndex + 1 < lstCommands.Items.Count) - { - lstCommands.SelectedIndex += 1; - } - - txtSSHCommand.Text = lstCommands.SelectedItem.ToString(); - txtSSHCommand.Select(txtSSHCommand.TextLength, 0); - } - - if (e.Control == true && e.KeyCode != Keys.V && e.Alt == false) - { - sendAllKey(NativeMethods.WM_KEYDOWN, e.KeyValue); - } - - if (e.KeyCode == Keys.Enter) - { - string strLine = txtSSHCommand.Text; - foreach (char chr1 in strLine) - { - sendAllKey(NativeMethods.WM_CHAR, Convert.ToByte(chr1)); - } - sendAllKey(NativeMethods.WM_KEYDOWN, 13); // Enter = char13 - } - } - - private void gotoEndOfText() - { - if (txtSSHCommand.Text.Trim() != "") - { - lstCommands.Items.Add(txtSSHCommand.Text.Trim()); - } - lstCommands.SelectedIndex = lstCommands.Items.Count - 1; - txtSSHCommand.Clear(); - } - - private void sendAllKey(int keyType, int keyData) - { - if (processHandlers.Count == 0) - { - return; - } - foreach (PuttyBase proc in processHandlers) - { - NativeMethods.PostMessage(proc.PuttyHandle, keyType, new IntPtr(keyData), new IntPtr(0)); - } - } - - private void txtSSHCommand_KeyUp(object sender, KeyEventArgs e) - { - if (e.KeyCode == Keys.Enter) - { - gotoEndOfText(); - } - } - } - #endregion -} diff --git a/mRemoteV1/UI/Window/SSHCommandWIndow.resx b/mRemoteV1/UI/Window/SSHCommandWIndow.resx deleted file mode 100644 index 1af7de15..00000000 --- a/mRemoteV1/UI/Window/SSHCommandWIndow.resx +++ /dev/null @@ -1,120 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - text/microsoft-resx - - - 2.0 - - - System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - - System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 - - \ No newline at end of file diff --git a/mRemoteV1/UI/WindowType.cs b/mRemoteV1/UI/WindowType.cs index 6ee9f730..3b320aaa 100644 --- a/mRemoteV1/UI/WindowType.cs +++ b/mRemoteV1/UI/WindowType.cs @@ -17,6 +17,5 @@ namespace mRemoteNG.UI PortScan = 14, UltraVNCSC = 16, ComponentsCheck = 17, - SSHCommandWindow = 18, } } \ No newline at end of file diff --git a/mRemoteV1/mRemoteV1.csproj b/mRemoteV1/mRemoteV1.csproj index 9d62f44d..22f9436f 100644 --- a/mRemoteV1/mRemoteV1.csproj +++ b/mRemoteV1/mRemoteV1.csproj @@ -498,12 +498,6 @@ Form - - Form - - - SSHCommandWIndow.cs - Form @@ -687,9 +681,6 @@ ScreenshotManagerWindow.cs Designer - - SSHCommandWIndow.cs - SSHTransferWindow.cs Designer