Compare commits

...

30 Commits

Author SHA1 Message Date
Riley McArdle
0ff00e59ba Add setting for update channel. 2013-03-04 21:52:28 -06:00
Riley McArdle
850a342e38 Prepare CHANGELOG.TXT for release of 1.71 Beta 1. 2013-03-04 15:54:49 -06:00
Riley McArdle
1caba06aca Fix issue MR-362 - Rename 'Screenshot Manager' to 'Screenshots' on the View menu to match Panel name 2013-03-04 13:20:49 -06:00
Riley McArdle
a115196cee Disable Fullscreen item on tab context menu if redirect keys is enabled for RDP connection. Fix automatic RDP resize when redirect keys is enabled. Fix automatic RDP resize when SmartSize setting is changed. 2013-03-04 12:55:46 -06:00
Riley McArdle
5f451de94e Fix issue MR-352 - Passwords with " (quotation mark) and # (hash key) characters make mRemoteNG to open PuttyNG dialog 2013-03-02 01:41:00 -06:00
Riley McArdle
a4921fc564 Add automatic resizing of RDP connections when the window is resized or when toggling full screen mode. 2013-03-01 17:04:28 -06:00
Riley McArdle
7d1d03e8cd Fix connection bar being shown when connecting to an RDP connection with redirect key combinations enabled. 2013-02-28 22:46:07 -06:00
Riley McArdle
92c18a45ba Merge branch 'release/1.70' into develop 2013-02-28 14:57:41 -06:00
Riley McArdle
e1deaf73ea Fix issue MR-117 - Remote Session Info Window / Tab does not populate 2013-02-27 19:20:49 -06:00
Riley McArdle
7d6d602477 Merge branch 'release/1.70' into develop
Conflicts:
	CHANGELOG.TXT
2013-02-27 14:44:17 -06:00
Riley McArdle
0a7c88a853 Fix issue MR-339 - Connection group collapses with just one click 2013-02-27 14:39:27 -06:00
Riley McArdle
960ecba12a Fix tabs not closing on double-click when the active tab is a PuTTY connection. 2013-02-27 14:12:49 -06:00
Riley McArdle
3988820db9 Fix issue MR-342 - Incorrect view in config pane of new connection after viewing default inheritance 2013-02-26 21:06:47 -06:00
Riley McArdle
22ea7055c9 Fix issue MR-142 - Start of mRemoteNG takes about one minute and consumes excessive CPU 2013-02-26 20:46:49 -06:00
Riley McArdle
edba3fbea0 Merge branch 'release/1.70' into develop
Conflicts:
	CHANGELOG.TXT
	mRemoteV1/Forms/frmOptions.resx
	mRemoteV1/Forms/frmOptions.vb
2013-02-26 20:02:18 -06:00
Riley McArdle
51e4bc7eae Move search prompt to resource string. 2013-02-26 16:19:06 -06:00
Riley McArdle
3e680235ee Improve appearance and discoverability of the connection search box. 2013-02-26 16:13:45 -06:00
Riley McArdle
c218f0362e Merge branch 'release/1.70' into develop
Conflicts:
	CHANGELOG.TXT
2013-02-25 18:47:20 -06:00
Riley McArdle
a3c9c667b4 Add detection of newer versions of connection files and database schemata and refuse to open them to avoid data loss. 2013-02-24 16:46:37 -06:00
Riley McArdle
73f71050a0 Fix issue MR-332 - Can't select different tab with one click after disconnecting existing tab 2013-02-24 16:02:04 -06:00
Riley McArdle
94d901ec4c Increment version to 1.71. 2013-02-24 15:40:19 -06:00
Riley McArdle
9e67f36615 Fix issue MR-330 - Portable version saves log to user's profile folder 2013-02-24 15:38:48 -06:00
Riley McArdle
bf6f166d8f Add feature MR-329 - Create Option to disable the "Quick: " prefix 2013-02-24 13:15:44 -06:00
Riley McArdle
1de5ab43d6 Fix issue MR-67 - Sort does not recursively sort 2013-02-24 12:49:38 -06:00
Riley McArdle
39dd75dbde Fix issue MR-121 - Config pane not sorting properties correctly when switching between alphabetical and categorized view 2013-02-24 00:04:45 -06:00
Riley McArdle
b509f75c17 Fix issue MR-130 - Issues duplicating folders 2013-02-23 23:38:16 -06:00
Riley McArdle
877649b80a Fix issue MR-158 - Password field not accepting Pipe 2013-02-23 22:14:48 -06:00
Riley McArdle
b5846f2286 Fix issue MR-333 - Unnecessary prompt for 'close all open connections?' 2013-02-23 21:34:48 -06:00
Riley McArdle
80dd98e7fb Merge branch 'release/1.70' into develop 2013-02-23 21:03:21 -06:00
Riley McArdle
80f35cea71 Refactor Security.Crypt.Decrypt(). 2013-02-21 21:08:19 -06:00
27 changed files with 724 additions and 317 deletions

View File

@@ -1,10 +1,29 @@
1.71 Beta 1 (2013-03-04):
Added feature MR-329 - Create Option to disable the "Quick: " prefix
Fixed issue MR-67 - Sort does not recursively sort
Fixed issue MR-117 - Remote Session Info Window / Tab does not populate
Fixed issue MR-121 - Config pane not sorting properties correctly when switching between alphabetical and categorized view
Fixed issue MR-130 - Issues duplicating folders
Fixed issue MR-142 - Start of mRemoteNG takes about one minute and consumes excessive CPU
Fixed issue MR-158 - Password field not accepting Pipe
Fixed issue MR-330 - Portable version saves log to user's profile folder
Fixed issue MR-333 - Unnecessary prompt for 'close all open connections?'
Fixed issue MR-342 - Incorrect view in config pane of new connection after viewing default inheritance
Fixed issue MR-352 - Passwords with " (quotation mark) and # (hash key) characters make mRemoteNG to open PuttyNG dialog
Fixed issue MR-362 - Rename 'Screenshot Manager' to 'Screenshots' on the View menu to match Panel name
Added detection of newer versions of connection files and database schemata. mRemoteNG will now refuse to open them to avoid data loss.
Improved appearance and discoverability of the connection search box.
If RDC 7.0 or higher is installed, the connection bar is no longer briefly shown when connecting to an RDP connection with redirect key combinations enabled.
If RDC 8.0 or higher is installed, RDP connections automatically adjust their size when the window is resized or when toggling full screen mode.
1.70 Release Candidate 3 (XXXX-XX-XX):
Fixed issue MR-339 - Connection group collapses with just one click
Fixed issue MR-340 - Object reference not set to an instance of an object.
Fixed issue MR-344 - Move "Always show panel tabs" option
Fixed issue MR-350 - VerifyDatabaseVersion (Config.Connections.Save) failed. Version string portion was too short or too long.
Fixed tabs not closing on double-click when the active tab is a PuTTY connection.
1.70 (2013-02-25):
1.70 Release Candidate 2 (2013-02-25):
Fixed issue MR-332 - Can't select different tab with one click after disconnecting existing tab
Fixed issue MR-338 - PuTTYNG crashing on fresh install of mRemoteNG
Re-enabled PuTTYNG integration enhancements on Windows 8

View File

@@ -25,11 +25,18 @@ Namespace App
Public Class Update
Public Shared ReadOnly URL As String = "http://update.mremoteng.org/"
#If DEBUG Then
Public Shared ReadOnly File As String = "update-debug.txt"
#Else
Public Shared ReadOnly File As String = "update.txt"
#End If
Public Shared ReadOnly Property File As String
Get
Select Case My.Settings.UpdateChannel.ToLowerInvariant()
Case "beta"
Return "update-beta.txt"
Case "debug"
Return "update-debug.txt"
Case Else
Return "update.txt"
End Select
End Get
End Property
End Class
Public Class Connections

View File

@@ -1,7 +1,6 @@
Imports log4net
Imports mRemoteNG.Messages
Imports mRemoteNG.Connection
Imports mRemoteNG.Config.Settings
Imports mRemoteNG.Tools
Imports WeifenLuo.WinFormsUI.Docking
Imports System.IO
@@ -452,30 +451,55 @@ Namespace App
End Sub
Public Shared Sub CreateLogger()
log4net.Config.XmlConfigurator.Configure(New FileInfo("mRemoteNG.exe.config"))
Log = log4net.LogManager.GetLogger("mRemoteNG.Log")
Log.InfoFormat("{0} started.", My.Application.Info.ProductName)
Log.InfoFormat("Command Line: {0}", Environment.GetCommandLineArgs)
Try
Dim servicePack As Integer
For Each managementObject As ManagementObject In New ManagementObjectSearcher("SELECT * FROM Win32_OperatingSystem").Get()
servicePack = managementObject.GetPropertyValue("ServicePackMajorVersion")
If servicePack = 0 Then
Log.InfoFormat("{0} {1}", managementObject.GetPropertyValue("Caption").Trim, managementObject.GetPropertyValue("OSArchitecture"))
Else
Log.InfoFormat("{0} Service Pack {1} {2}", managementObject.GetPropertyValue("Caption").Trim, servicePack.ToString, managementObject.GetPropertyValue("OSArchitecture"))
End If
Next
Catch ex As Exception
Log.WarnFormat("Error retrieving operating system information from WMI. {0}", ex.Message)
End Try
Log.InfoFormat("Microsoft .NET Framework {0}", System.Environment.Version.ToString)
log4net.Config.XmlConfigurator.Configure()
Dim logFilePath As String
#If Not PORTABLE Then
Log.InfoFormat("{0} {1}", My.Application.Info.ProductName.ToString, My.Application.Info.Version.ToString)
logFilePath = Path.Combine(GetFolderPath(SpecialFolder.LocalApplicationData), Application.ProductName)
#Else
log.InfoFormat("{0} {1} {2}", My.Application.Info.ProductName.ToString, My.Application.Info.Version.ToString, My.Language.strLabelPortableEdition)
logFilePath = Application.StartupPath
#End If
Log.InfoFormat("System Culture: {0}/{1}", Threading.Thread.CurrentThread.CurrentUICulture.Name, Threading.Thread.CurrentThread.CurrentUICulture.NativeName)
Dim logFileName As String = Path.ChangeExtension(Application.ProductName, ".log")
Dim logFile As String = Path.Combine(logFilePath, logFileName)
Dim repository As Repository.ILoggerRepository = LogManager.GetRepository()
Dim appenders As Appender.IAppender() = repository.GetAppenders()
Dim fileAppender As Appender.FileAppender
For Each appender As Appender.IAppender In appenders
fileAppender = TryCast(appender, Appender.FileAppender)
If Not (fileAppender Is Nothing OrElse Not fileAppender.Name = "LogFileAppender") Then
fileAppender.File = logFile
fileAppender.ActivateOptions()
End If
Next
Log = LogManager.GetLogger("Logger")
If My.Settings.WriteLogFile Then
#If Not PORTABLE Then
Log.InfoFormat("{0} {1} starting.", Application.ProductName, Application.ProductVersion)
#Else
Log.InfoFormat("{0} {1} {2} starting.", Application.ProductName, Application.ProductVersion, My.Language.strLabelPortableEdition)
#End If
Log.InfoFormat("Command Line: {0}", Environment.GetCommandLineArgs)
Try
Dim servicePack As Integer
For Each managementObject As ManagementObject In New ManagementObjectSearcher("SELECT * FROM Win32_OperatingSystem").Get()
servicePack = managementObject.GetPropertyValue("ServicePackMajorVersion")
If servicePack = 0 Then
Log.InfoFormat("{0} {1}", managementObject.GetPropertyValue("Caption").Trim, managementObject.GetPropertyValue("OSArchitecture"))
Else
Log.InfoFormat("{0} Service Pack {1} {2}", managementObject.GetPropertyValue("Caption").Trim, servicePack.ToString, managementObject.GetPropertyValue("OSArchitecture"))
End If
Next
Catch ex As Exception
Log.WarnFormat("Error retrieving operating system information from WMI. {0}", ex.Message)
End Try
Log.InfoFormat("Microsoft .NET CLR {0}", Version.ToString)
Log.InfoFormat("System Culture: {0}/{1}", Thread.CurrentThread.CurrentUICulture.Name, Thread.CurrentThread.CurrentUICulture.NativeName)
End If
End Sub
Public Shared Sub UpdateCheck()
@@ -1482,7 +1506,12 @@ Namespace App
If Not String.IsNullOrEmpty(Uri.Host) Then
Dim newConnectionInfo As New Connection.Info
newConnectionInfo.Name = String.Format(My.Language.strQuick, Uri.Host)
If My.Settings.IdentifyQuickConnectTabs Then
newConnectionInfo.Name = String.Format(My.Language.strQuick, Uri.Host)
Else
newConnectionInfo.Name = Uri.Host
End If
newConnectionInfo.Protocol = Protocol
newConnectionInfo.Hostname = Uri.Host
If Uri.Port = -1 Then

View File

@@ -5,6 +5,7 @@ Imports mRemoteNG.App.Runtime
Imports System.Data
Imports System.Data.SqlClient
Imports System.IO
Imports PSTaskDialog
Namespace Config
Namespace Connections
@@ -206,7 +207,12 @@ Namespace Config
sqlRd.Read()
End If
Me.confVersion = Convert.ToDouble(sqlRd.Item("confVersion"), CultureInfo.InvariantCulture)
confVersion = Convert.ToDouble(sqlRd.Item("confVersion"), CultureInfo.InvariantCulture)
Const maxSupportedSchemaVersion As Double = 2.4
If confVersion > maxSupportedSchemaVersion Then
cTaskDialog.ShowTaskDialogBox(frmMain, Application.ProductName, "Incompatible database schema", String.Format("The database schema on the server is not supported. Please upgrade to a newer version of {0}.", Application.ProductName), String.Format("Schema Version: {1}{0}Highest Supported Version: {2}", vbNewLine, confVersion.ToString(), maxSupportedSchemaVersion.ToString()), "", "", "", "", eTaskDialogButtons.OK, eSysIcons.Error, Nothing)
Throw New Exception(String.Format("Incompatible database schema (schema version {0}).", confVersion))
End If
Dim rootNode As TreeNode
rootNode = New TreeNode(sqlRd.Item("Name"))
@@ -235,6 +241,8 @@ Namespace Config
sqlRd.Close()
Windows.treeForm.tvConnections.BeginUpdate()
' SECTION 3. Populate the TreeView with the DOM nodes.
AddNodesFromSQL(rootNode)
'AddNodeFromXml(xDom.DocumentElement, Me._RootTreeNode)
@@ -248,6 +256,8 @@ Namespace Config
End If
Next
Windows.treeForm.tvConnections.EndUpdate()
'open connections from last mremote session
If My.Settings.OpenConsFromLastSession = True And My.Settings.NoReconnect = False Then
For Each conI As Connection.Info In Me._ConnectionList
@@ -265,10 +275,12 @@ Namespace Config
App.Runtime.IsConnectionsFileLoaded = True
'App.Runtime.Windows.treeForm.InitialRefresh()
sqlCon.Close()
Catch ex As Exception
MessageCollector.AddMessage(Messages.MessageClass.ErrorMsg, My.Language.strLoadFromSqlFailed & vbNewLine & ex.Message, True)
Finally
If sqlCon IsNot Nothing Then
sqlCon.Close()
End If
End Try
End Sub
@@ -644,6 +656,12 @@ Namespace Config
MessageCollector.AddMessage(Messages.MessageClass.WarningMsg, My.Language.strOldConffile)
End If
Const maxSupportedConfVersion As Double = 2.4
If confVersion > maxSupportedConfVersion Then
cTaskDialog.ShowTaskDialogBox(frmMain, Application.ProductName, "Incompatible connection file format", String.Format("The format of this connection file is not supported. Please upgrade to a newer version of {0}.", Application.ProductName), String.Format("{1}{0}File Format Version: {2}{0}Highest Supported Version: {3}", vbNewLine, ConnectionFileName, confVersion.ToString(), maxSupportedConfVersion.ToString()), "", "", "", "", eTaskDialogButtons.OK, eSysIcons.Error, Nothing)
Throw New Exception(String.Format("Incompatible connection file format (file format version {0}).", confVersion))
End If
' SECTION 2. Initialize the treeview control.
Dim rootNode As TreeNode
@@ -693,6 +711,8 @@ Namespace Config
Me._RootTreeNode.SelectedImageIndex = Images.Enums.TreeImage.Root
End If
Windows.treeForm.tvConnections.BeginUpdate()
' SECTION 3. Populate the TreeView with the DOM nodes.
AddNodeFromXML(xDom.DocumentElement, Me._RootTreeNode)
@@ -705,6 +725,8 @@ Namespace Config
End If
Next
Windows.treeForm.tvConnections.EndUpdate()
'open connections from last mremote session
If My.Settings.OpenConsFromLastSession = True And My.Settings.NoReconnect = False Then
For Each conI As Connection.Info In Me._ConnectionList

View File

@@ -17,14 +17,24 @@ Namespace Connection
End Set
End Property
Private _InterfaceControl As Connection.InterfaceControl
Public Property InterfaceControl() As Connection.InterfaceControl
Private WithEvents _connectionWindow As UI.Window.Connection
Public Property ConnectionWindow As UI.Window.Connection
Get
Return Me._InterfaceControl
Return _connectionWindow
End Get
Set(ByVal value As Connection.InterfaceControl)
Me._InterfaceControl = value
Set(value As UI.Window.Connection)
_connectionWindow = value
End Set
End Property
Private _interfaceControl As InterfaceControl
Public Property InterfaceControl() As InterfaceControl
Get
Return _interfaceControl
End Get
Set(ByVal value As InterfaceControl)
_interfaceControl = value
ConnectionWindow = TryCast(_interfaceControl.GetContainerControl(), UI.Window.Connection)
End Set
End Property
@@ -62,17 +72,29 @@ Namespace Connection
End Try
End Sub
Public Overridable Sub ResizeBegin(ByVal sender As System.Object, ByVal e As EventArgs) Handles _connectionWindow.ResizeBegin
End Sub
Public Overridable Sub Resize(ByVal sender As System.Object, ByVal e As EventArgs) Handles _connectionWindow.Resize
End Sub
Public Overridable Sub ResizeEnd(ByVal sender As System.Object, ByVal e As EventArgs) Handles _connectionWindow.ResizeEnd
End Sub
Public Overridable Function SetProps() As Boolean
Try
Me._InterfaceControl.Parent.Tag = Me._InterfaceControl
Me._InterfaceControl.Show()
Me._interfaceControl.Parent.Tag = Me._interfaceControl
Me._interfaceControl.Show()
If Me._Control IsNot Nothing Then
Me._Control.Name = Me._Name
Me._Control.Parent = Me._InterfaceControl
Me._Control.Location = Me._InterfaceControl.Location
Me._Control.Parent = Me._interfaceControl
Me._Control.Location = Me._interfaceControl.Location
Me._Control.Size = Me.InterfaceControl.Size
Me._Control.Anchor = Me._InterfaceControl.Anchor
Me._Control.Anchor = Me._interfaceControl.Anchor
End If
Return True
@@ -92,10 +114,6 @@ Namespace Connection
Me.Close()
End Sub
Public Overridable Sub Resize()
End Sub
Public Overridable Sub Close()
Dim t As New Thread(AddressOf CloseBG)
t.SetApartmentState(Threading.ApartmentState.STA)

View File

@@ -1,6 +1,7 @@
Imports mRemoteNG.App.Native
Imports System.Threading
Imports mRemoteNG.App.Runtime
Imports mRemoteNG.Tools
Namespace Connection
Namespace Protocol
@@ -86,8 +87,9 @@ Namespace Connection
Return Nothing
End If
IntAppProcessStartInfo.UseShellExecute = False
IntAppProcessStartInfo.FileName = _IntAppPath
IntAppProcessStartInfo.Arguments = Arguments
IntAppProcessStartInfo.Arguments = CommandLineArguments.EscapeBackslashes(Arguments)
IntAppProcess = Process.Start(IntAppProcessStartInfo)
IntAppProcess.EnableRaisingEvents = True
@@ -120,7 +122,7 @@ Namespace Connection
SetWindowLong(Me.IntAppHandle, 0, WS_VISIBLE)
ShowWindow(Me.IntAppHandle, SW_SHOWMAXIMIZED)
Resize()
Resize(Me, New EventArgs)
MyBase.Connect()
Return True
@@ -139,8 +141,9 @@ Namespace Connection
End Try
End Sub
Public Overrides Sub Resize()
Public Overrides Sub Resize(ByVal sender As Object, ByVal e As EventArgs)
Try
If InterfaceControl.Size = Size.Empty Then Return
MoveWindow(IntAppHandle, -SystemInformation.FrameBorderSize.Width, -(SystemInformation.CaptionHeight + SystemInformation.FrameBorderSize.Height), Me.InterfaceControl.Width + (SystemInformation.FrameBorderSize.Width * 2), Me.InterfaceControl.Height + SystemInformation.CaptionHeight + (SystemInformation.FrameBorderSize.Height * 2), True)
Catch ex As Exception
MessageCollector.AddMessage(Messages.MessageClass.ErrorMsg, My.Language.strIntAppResizeFailed & vbNewLine & ex.Message, True)

View File

@@ -6,6 +6,8 @@ Imports System.Threading
Imports Microsoft.Win32
Imports System.Drawing
Imports mRemoteNG.App.Runtime
Imports System.Text.RegularExpressions
Imports mRemoteNG.Tools
Namespace Connection
Namespace Protocol
@@ -111,45 +113,53 @@ Namespace Connection
PuttyProcess = New Process
With PuttyProcess.StartInfo
.UseShellExecute = False
.FileName = _PuttyPath
Select Case _PuttyProtocol
Case Putty_Protocol.raw
.Arguments = "-load " & """" & PuttyEscapeArgument(InterfaceControl.Info.PuttySession) & """" & " -" & _PuttyProtocol.ToString & " -P " & InterfaceControl.Info.Port & " """ & InterfaceControl.Info.Hostname & """"
Case Putty_Protocol.rlogin
.Arguments = "-load " & """" & PuttyEscapeArgument(InterfaceControl.Info.PuttySession) & """" & " -" & _PuttyProtocol.ToString & " -P " & InterfaceControl.Info.Port & " """ & InterfaceControl.Info.Hostname & """"
Case Putty_Protocol.ssh
Dim userArgument As String = ""
Dim passwordArgument As String = ""
Dim arguments As New CommandLineArguments
arguments.EscapeForShell = False
arguments.Add("-load", InterfaceControl.Info.PuttySession)
arguments.Add("-" & _PuttyProtocol.ToString)
If _PuttyProtocol = Putty_Protocol.ssh Then
Dim username As String = ""
Dim password As String = ""
If Not String.IsNullOrEmpty(InterfaceControl.Info.Username) Then
username = InterfaceControl.Info.Username
Else
If My.Settings.EmptyCredentials = "windows" Then
userArgument = " -l """ & Environment.UserName & """"
username = Environment.UserName
ElseIf My.Settings.EmptyCredentials = "custom" Then
userArgument = " -l """ & My.Settings.DefaultUsername & """"
passwordArgument = " -pw """ & PuttyEscapeArgument(Security.Crypt.Decrypt(My.Settings.DefaultPassword, App.Info.General.EncryptionKey)) & """"
username = My.Settings.DefaultUsername
End If
End If
If InterfaceControl.Info.Username <> "" Then
userArgument = " -l """ & InterfaceControl.Info.Username & """"
If Not String.IsNullOrEmpty(InterfaceControl.Info.Password) Then
password = InterfaceControl.Info.Password
Else
If My.Settings.EmptyCredentials = "custom" Then
password = Security.Crypt.Decrypt(My.Settings.DefaultPassword, App.Info.General.EncryptionKey)
End If
End If
If InterfaceControl.Info.Password <> "" Then
passwordArgument = " -pw """ & PuttyEscapeArgument(InterfaceControl.Info.Password) & """"
End If
.Arguments = "-load " & """" & PuttyEscapeArgument(InterfaceControl.Info.PuttySession) & """" & " -" & _PuttyProtocol.ToString & " -" & _PuttySSHVersion & userArgument & passwordArgument & " -P " & InterfaceControl.Info.Port & " """ & InterfaceControl.Info.Hostname & """"
Case Putty_Protocol.telnet
.Arguments = "-load " & """" & PuttyEscapeArgument(InterfaceControl.Info.PuttySession) & """" & " -" & _PuttyProtocol.ToString & " -P " & InterfaceControl.Info.Port & " """ & InterfaceControl.Info.Hostname & """"
Case Putty_Protocol.serial
.Arguments = "-load " & """" & PuttyEscapeArgument(InterfaceControl.Info.PuttySession) & """" & " -" & _PuttyProtocol.ToString & " -P " & InterfaceControl.Info.Port & " """ & InterfaceControl.Info.Hostname & """"
End Select
If _isPuttyNg Then
.Arguments = .Arguments & " -hwndparent " & InterfaceControl.Handle.ToString()
arguments.Add("-" & _PuttySSHVersion)
arguments.Add("-l", username)
arguments.Add("-pw", password)
End If
arguments.Add("-P", InterfaceControl.Info.Port.ToString)
arguments.Add(InterfaceControl.Info.Hostname)
If _isPuttyNg Then
arguments.Add("-hwndparent", InterfaceControl.Handle.ToString())
End If
.Arguments = arguments.ToString
'REMOVE IN RELEASE!
'MessageCollector.AddMessage(MessageClass.InformationMsg, "PuTTY Arguments: " & .Arguments, True)
MessageCollector.AddMessage(MessageClass.InformationMsg, "PuTTY Arguments: " & .Arguments, True)
End With
PuttyProcess.EnableRaisingEvents = True
@@ -179,7 +189,7 @@ Namespace Connection
MessageCollector.AddMessage(MessageClass.InformationMsg, String.Format(My.Language.strPuttyTitle, PuttyProcess.MainWindowTitle), True)
MessageCollector.AddMessage(MessageClass.InformationMsg, String.Format(My.Language.strPuttyParentHandle, InterfaceControl.Parent.Handle.ToString), True)
Resize()
Resize(Me, New EventArgs)
MyBase.Connect()
Return True
@@ -189,14 +199,6 @@ Namespace Connection
End Try
End Function
' Due to the way PuTTY handles command line arguments, backslashes followed by a quotation mark will be removed.
' Since all the strings we send to PuTTY are surrounded by quotation marks, we need to escape any trailing
' backslashes by adding another. See split_into_argv() in WINDOWS\WINUTILS.C of the PuTTY source for more info.
Private Shared Function PuttyEscapeArgument(ByVal argument As String) As String
If argument.EndsWith("\") Then argument = argument & "\"
Return argument
End Function
Public Overrides Sub Focus()
Try
SetForegroundWindow(PuttyHandle)
@@ -205,10 +207,9 @@ Namespace Connection
End Try
End Sub
Public Overrides Sub Resize()
Public Overrides Sub Resize(ByVal sender As Object, ByVal e As EventArgs)
Try
If frmMain.WindowState = FormWindowState.Minimized Then Return
If InterfaceControl.Size = Size.Empty Then Return
MoveWindow(PuttyHandle, -SystemInformation.FrameBorderSize.Width, -(SystemInformation.CaptionHeight + SystemInformation.FrameBorderSize.Height), InterfaceControl.Width + (SystemInformation.FrameBorderSize.Width * 2), InterfaceControl.Height + SystemInformation.CaptionHeight + (SystemInformation.FrameBorderSize.Height * 2), True)
Catch ex As Exception
MessageCollector.AddMessage(Messages.MessageClass.ErrorMsg, My.Language.strPuttyResizeFailed & vbNewLine & ex.Message, True)

View File

@@ -12,23 +12,49 @@ Namespace Connection
Inherits Connection.Protocol.Base
#Region "Properties"
Private _SmartSize As Boolean
Public Property SmartSize() As Boolean
Get
Return Me.RDP.AdvancedSettings4.SmartSizing
Return RDP.AdvancedSettings4.SmartSizing
End Get
Set(ByVal value As Boolean)
Me.RDP.AdvancedSettings4.SmartSizing = value
RDP.AdvancedSettings4.SmartSizing = value
ReconnectForResize()
End Set
End Property
Private _Fullscreen As Boolean
Public Property Fullscreen() As Boolean
Get
Return Me.RDP.FullScreen
Return RDP.FullScreen
End Get
Set(ByVal value As Boolean)
Me.RDP.FullScreen = value
RDP.FullScreen = value
ReconnectForResize()
End Set
End Property
Private _redirectKeys As Boolean = False
Public Property RedirectKeys As Boolean
Get
Return _redirectKeys
End Get
Set(value As Boolean)
_redirectKeys = value
Try
If Not _redirectKeys Then Return
RDP.AdvancedSettings2.ContainerHandledFullScreen = 1
RDP.AdvancedSettings2.DisplayConnectionBar = False
RDP.AdvancedSettings2.PinConnectionBar = False
If RDPVersion >= Versions.RDC70 Then
Dim msRdpClientNonScriptable As MSTSCLib.IMsRdpClientNonScriptable5 = RDP.GetOcx()
msRdpClientNonScriptable.DisableConnectionBar = True
End If
RDP.FullScreen = True
Catch ex As Exception
MessageCollector.AddMessage(Messages.MessageClass.ErrorMsg, My.Language.strRdpSetRedirectKeysFailed & vbNewLine & ex.Message, True)
End Try
End Set
End Property
#End Region
@@ -87,7 +113,7 @@ Namespace Connection
Me.SetUseConsoleSession()
Me.SetPort()
Me.SetRedirectKeys()
RedirectKeys = Info.RedirectKeys
Me.SetRedirection()
Me.SetAuthenticationLevel()
Me.SetRDGateway()
@@ -156,14 +182,56 @@ Namespace Connection
End Try
End Sub
Public Overrides Sub Resize()
Control.Location = InterfaceControl.Location
Control.Size = InterfaceControl.Size
MyBase.Resize()
Private _controlBeginningSize As New Size
Public Overrides Sub ResizeBegin(ByVal sender As Object, ByVal e As EventArgs)
_controlBeginningSize = Control.Size
End Sub
Public Overrides Sub Resize(ByVal sender As Object, ByVal e As EventArgs)
If DoResize() And _controlBeginningSize.IsEmpty Then
ReconnectForResize()
End If
MyBase.Resize(sender, e)
End Sub
Public Overrides Sub ResizeEnd(ByVal sender As Object, ByVal e As EventArgs)
DoResize()
If Not Control.Size = _controlBeginningSize Then
ReconnectForResize()
End If
_controlBeginningSize = Size.Empty
End Sub
#End Region
#Region "Private Methods"
Private Function DoResize() As Boolean
Control.Location = InterfaceControl.Location
If Not Control.Size = InterfaceControl.Size And Not InterfaceControl.Size = Size.Empty Then
Control.Size = InterfaceControl.Size
Return True
Else
Return False
End If
End Function
Private Sub ReconnectForResize()
If RDPVersion < Versions.RDC80 Then Return
If Not (InterfaceControl.Info.Resolution = RDPResolutions.FitToWindow Or _
InterfaceControl.Info.Resolution = RDPResolutions.Fullscreen) Or _
SmartSize Then Return
Dim size As Size
If RedirectKeys Or Not Fullscreen Then
size = Control.Size
Else
size = Screen.FromControl(Control).Bounds.Size
End If
Dim msRdpClient8 As MSTSCLib.IMsRdpClient8 = RDP.GetOcx()
msRdpClient8.Reconnect(size.Width, size.Height)
End Sub
Private Sub SetRDGateway()
Try
If RDP.TransportSettings.GatewayIsSupported = 1 Then
@@ -310,19 +378,6 @@ Namespace Connection
End Try
End Sub
Private Sub SetRedirectKeys()
Try
If Me.Info.RedirectKeys Then
RDP.AdvancedSettings2.ContainerHandledFullScreen = 1
RDP.AdvancedSettings2.DisplayConnectionBar = False
RDP.AdvancedSettings2.PinConnectionBar = False
RDP.FullScreen = True
End If
Catch ex As Exception
MessageCollector.AddMessage(Messages.MessageClass.ErrorMsg, My.Language.strRdpSetRedirectKeysFailed & vbNewLine & ex.Message, True)
End Try
End Sub
Private Sub SetRedirection()
Try
RDP.AdvancedSettings2.RedirectDrives = Me.Info.RedirectDiskDrives
@@ -414,6 +469,7 @@ Namespace Connection
End Sub
Private Sub RDPEvent_OnLeaveFullscreenMode(ByVal sender As Object, ByVal e As System.EventArgs)
Fullscreen = False
RaiseEvent LeaveFullscreen(Me, e)
End Sub
#End Region
@@ -626,6 +682,8 @@ Namespace Connection
Public Class Versions
Public Shared RDC60 As New Version(6, 0, 6000)
Public Shared RDC61 As New Version(6, 0, 6001)
Public Shared RDC70 As New Version(6, 1, 7600)
Public Shared RDC80 As New Version(6, 2, 9200)
End Class
#Region "Terminal Sessions"
@@ -818,7 +876,6 @@ Namespace Connection
End If
End Sub
#End Region
End Class
End Namespace
End Namespace

View File

@@ -689,6 +689,7 @@ Partial Class frmMain
Me.tsExternalTools.Location = New System.Drawing.Point(39, 49)
Me.tsExternalTools.Name = "tsExtAppsToolbar"
Me.tsExternalTools.Size = New System.Drawing.Size(111, 25)
Me.tsExternalTools.MaximumSize = New System.Drawing.Size(0, 25)
Me.tsExternalTools.TabIndex = 17
'
'cMenExtAppsToolbar
@@ -712,6 +713,7 @@ Partial Class frmMain
Me.tsQuickConnect.Location = New System.Drawing.Point(3, 24)
Me.tsQuickConnect.Name = "tsQuickConnect"
Me.tsQuickConnect.Size = New System.Drawing.Size(331, 25)
Me.tsQuickConnect.MaximumSize = New System.Drawing.Size(0, 25)
Me.tsQuickConnect.TabIndex = 18
'
'btnQuickyPlay
@@ -741,6 +743,7 @@ Partial Class frmMain
Me.ToolStrip1.Location = New System.Drawing.Point(3, 74)
Me.ToolStrip1.Name = "ToolStrip1"
Me.ToolStrip1.Size = New System.Drawing.Size(264, 25)
Me.ToolStrip1.MaximumSize = New System.Drawing.Size(0, 25)
Me.ToolStrip1.TabIndex = 19
Me.ToolStrip1.Visible = False
'

View File

@@ -124,7 +124,7 @@ Public Class frmMain
mMenViewConfig.Text = My.Language.strMenuConfig
mMenViewSessions.Text = My.Language.strMenuSessions
mMenViewErrorsAndInfos.Text = My.Language.strMenuNotifications
mMenViewScreenshotManager.Text = My.Language.strMenuScreenshotManager
mMenViewScreenshotManager.Text = My.Language.strScreenshots
mMenViewJumpTo.Text = My.Language.strMenuJumpTo
mMenViewJumpToConnectionsConfig.Text = My.Language.strMenuConnectionsAndConfig
mMenViewJumpToSessionsScreenshots.Text = My.Language.strMenuSessionsAndScreenshots
@@ -167,8 +167,17 @@ Public Class frmMain
End Sub
Private Sub frmMain_FormClosing(ByVal sender As Object, ByVal e As System.Windows.Forms.FormClosingEventArgs) Handles Me.FormClosing
If WindowList IsNot Nothing Then
If My.Settings.ConfirmExit And WindowList.Count > 0 Then
If My.Settings.ConfirmExit And Not (WindowList Is Nothing OrElse WindowList.Count = 0) Then
Dim connectionWindow As UI.Window.Connection
Dim openConnections As Integer = 0
For Each window As UI.Window.Base In WindowList
connectionWindow = TryCast(window, UI.Window.Connection)
If connectionWindow IsNot Nothing Then
openConnections = openConnections + connectionWindow.TabController.TabPages.Count
End If
Next
If openConnections > 0 Then
Dim result As DialogResult = cTaskDialog.MessageBox(Me, My.Application.Info.ProductName, My.Language.strConfirmExitMainInstruction, "", "", "", My.Language.strCheckboxDoNotShowThisMessageAgain, eTaskDialogButtons.YesNo, eSysIcons.Question, Nothing)
If cTaskDialog.VerificationChecked Then
My.Settings.ConfirmExit = False
@@ -701,22 +710,32 @@ Public Class frmMain
#End Region
#Region "Window Overrides and DockPanel Stuff"
Private Sub frmMain_Resize(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Resize
If Me.WindowState = FormWindowState.Minimized Then
Private _inSizeMove As Boolean = False
Private Sub frmMain_ResizeBegin(ByVal sender As Object, ByVal e As EventArgs) Handles Me.ResizeBegin
_inSizeMove = True
End Sub
Private Sub frmMain_Resize(ByVal sender As Object, ByVal e As EventArgs) Handles Me.Resize
If WindowState = FormWindowState.Minimized Then
If My.Settings.MinimizeToTray Then
If App.Runtime.NotificationAreaIcon Is Nothing Then
App.Runtime.NotificationAreaIcon = New Tools.Controls.NotificationAreaIcon()
If NotificationAreaIcon Is Nothing Then
NotificationAreaIcon = New Tools.Controls.NotificationAreaIcon()
End If
Me.Hide()
Hide()
End If
Else
PreviousWindowState = Me.WindowState
PreviousWindowState = WindowState
End If
End Sub
Private _inMouseActivate As Boolean = False
Private _inSizeMove As Boolean = False
Private Sub frmMain_ResizeEnd(ByVal sender As Object, ByVal e As EventArgs) Handles Me.ResizeEnd
_inSizeMove = False
' This handles activations from clicks that started a size/move operation
ActivateConnection()
End Sub
Private _inMouseActivate As Boolean = False
Protected Overloads Overrides Sub WndProc(ByRef m As Message)
Try
#If Config = "Debug" Then
@@ -749,13 +768,6 @@ Public Class frmMain
' This handles activations from clicks that did not start a size/move operation
ActivateConnection()
Case WM_ENTERSIZEMOVE
_inSizeMove = True
Case WM_EXITSIZEMOVE
_inSizeMove = False
' This handles activations from clicks that started a size/move operation
ActivateConnection()
Case WM_WINDOWPOSCHANGED
' Ignore this message if the window wasn't activated
Dim windowPos As WINDOWPOS = Marshal.PtrToStructure(m.LParam, GetType(WINDOWPOS))

View File

@@ -110,6 +110,7 @@ Public Class frmOptions
Friend WithEvents lblSQLDatabaseName As System.Windows.Forms.Label
Friend WithEvents txtSQLDatabaseName As System.Windows.Forms.TextBox
Friend WithEvents chkAlwaysShowPanelTabs As System.Windows.Forms.CheckBox
Friend WithEvents chkIdentifyQuickConnectTabs As System.Windows.Forms.CheckBox
Private components As System.ComponentModel.IContainer
Private Sub InitializeComponent()
@@ -198,8 +199,9 @@ Public Class frmOptions
Me.tcTabControl = New System.Windows.Forms.TabControl()
Me.tabStartupExit = New System.Windows.Forms.TabPage()
Me.tabAppearance = New System.Windows.Forms.TabPage()
Me.tabTabsAndPanels = New System.Windows.Forms.TabPage()
Me.chkAlwaysShowPanelTabs = New System.Windows.Forms.CheckBox()
Me.tabTabsAndPanels = New System.Windows.Forms.TabPage()
Me.chkIdentifyQuickConnectTabs = New System.Windows.Forms.CheckBox()
Me.tabConnections = New System.Windows.Forms.TabPage()
Me.pnlDefaultCredentials = New System.Windows.Forms.Panel()
Me.radCredentialsCustom = New System.Windows.Forms.RadioButton()
@@ -746,7 +748,7 @@ Public Class frmOptions
'chkAlwaysShowPanelSelectionDlg
'
Me.chkAlwaysShowPanelSelectionDlg.AutoSize = True
Me.chkAlwaysShowPanelSelectionDlg.Location = New System.Drawing.Point(3, 118)
Me.chkAlwaysShowPanelSelectionDlg.Location = New System.Drawing.Point(3, 141)
Me.chkAlwaysShowPanelSelectionDlg.Name = "chkAlwaysShowPanelSelectionDlg"
Me.chkAlwaysShowPanelSelectionDlg.Size = New System.Drawing.Size(317, 17)
Me.chkAlwaysShowPanelSelectionDlg.TabIndex = 4
@@ -766,7 +768,7 @@ Public Class frmOptions
'chkDoubleClickClosesTab
'
Me.chkDoubleClickClosesTab.AutoSize = True
Me.chkDoubleClickClosesTab.Location = New System.Drawing.Point(3, 95)
Me.chkDoubleClickClosesTab.Location = New System.Drawing.Point(3, 118)
Me.chkDoubleClickClosesTab.Name = "chkDoubleClickClosesTab"
Me.chkDoubleClickClosesTab.Size = New System.Drawing.Size(159, 17)
Me.chkDoubleClickClosesTab.TabIndex = 3
@@ -797,7 +799,7 @@ Public Class frmOptions
'
Me.chkMCWarnings.AutoSize = True
Me.chkMCWarnings.Enabled = False
Me.chkMCWarnings.Location = New System.Drawing.Point(19, 233)
Me.chkMCWarnings.Location = New System.Drawing.Point(19, 256)
Me.chkMCWarnings.Name = "chkMCWarnings"
Me.chkMCWarnings.Size = New System.Drawing.Size(71, 17)
Me.chkMCWarnings.TabIndex = 8
@@ -808,7 +810,7 @@ Public Class frmOptions
'
Me.chkMCErrors.AutoSize = True
Me.chkMCErrors.Enabled = False
Me.chkMCErrors.Location = New System.Drawing.Point(19, 256)
Me.chkMCErrors.Location = New System.Drawing.Point(19, 279)
Me.chkMCErrors.Name = "chkMCErrors"
Me.chkMCErrors.Size = New System.Drawing.Size(53, 17)
Me.chkMCErrors.TabIndex = 9
@@ -819,7 +821,7 @@ Public Class frmOptions
'
Me.chkMCInformation.AutoSize = True
Me.chkMCInformation.Enabled = False
Me.chkMCInformation.Location = New System.Drawing.Point(19, 210)
Me.chkMCInformation.Location = New System.Drawing.Point(19, 233)
Me.chkMCInformation.Name = "chkMCInformation"
Me.chkMCInformation.Size = New System.Drawing.Size(83, 17)
Me.chkMCInformation.TabIndex = 7
@@ -829,7 +831,7 @@ Public Class frmOptions
'lblSwitchToErrorsAndInfos
'
Me.lblSwitchToErrorsAndInfos.AutoSize = True
Me.lblSwitchToErrorsAndInfos.Location = New System.Drawing.Point(3, 190)
Me.lblSwitchToErrorsAndInfos.Location = New System.Drawing.Point(3, 213)
Me.lblSwitchToErrorsAndInfos.Name = "lblSwitchToErrorsAndInfos"
Me.lblSwitchToErrorsAndInfos.Size = New System.Drawing.Size(159, 13)
Me.lblSwitchToErrorsAndInfos.TabIndex = 6
@@ -838,7 +840,7 @@ Public Class frmOptions
'chkUseOnlyErrorsAndInfosPanel
'
Me.chkUseOnlyErrorsAndInfosPanel.AutoSize = True
Me.chkUseOnlyErrorsAndInfosPanel.Location = New System.Drawing.Point(3, 165)
Me.chkUseOnlyErrorsAndInfosPanel.Location = New System.Drawing.Point(3, 188)
Me.chkUseOnlyErrorsAndInfosPanel.Name = "chkUseOnlyErrorsAndInfosPanel"
Me.chkUseOnlyErrorsAndInfosPanel.Size = New System.Drawing.Size(278, 17)
Me.chkUseOnlyErrorsAndInfosPanel.TabIndex = 5
@@ -1021,9 +1023,20 @@ Public Class frmOptions
Me.tabAppearance.Text = "Appearance"
Me.tabAppearance.UseVisualStyleBackColor = True
'
'chkAlwaysShowPanelTabs
'
Me.chkAlwaysShowPanelTabs.AutoSize = True
Me.chkAlwaysShowPanelTabs.Location = New System.Drawing.Point(3, 3)
Me.chkAlwaysShowPanelTabs.Name = "chkAlwaysShowPanelTabs"
Me.chkAlwaysShowPanelTabs.Size = New System.Drawing.Size(139, 17)
Me.chkAlwaysShowPanelTabs.TabIndex = 7
Me.chkAlwaysShowPanelTabs.Text = "Always show panel tabs"
Me.chkAlwaysShowPanelTabs.UseVisualStyleBackColor = True
'
'tabTabsAndPanels
'
Me.tabTabsAndPanels.Controls.Add(Me.chkAlwaysShowPanelTabs)
Me.tabTabsAndPanels.Controls.Add(Me.chkIdentifyQuickConnectTabs)
Me.tabTabsAndPanels.Controls.Add(Me.chkUseOnlyErrorsAndInfosPanel)
Me.tabTabsAndPanels.Controls.Add(Me.chkOpenNewTabRightOfSelected)
Me.tabTabsAndPanels.Controls.Add(Me.lblSwitchToErrorsAndInfos)
@@ -1041,15 +1054,15 @@ Public Class frmOptions
Me.tabTabsAndPanels.Text = "Tabs & Panels"
Me.tabTabsAndPanels.UseVisualStyleBackColor = True
'
'chkAlwaysShowPanelTabs
'chkIdentifyQuickConnectTabs
'
Me.chkAlwaysShowPanelTabs.AutoSize = True
Me.chkAlwaysShowPanelTabs.Location = New System.Drawing.Point(3, 3)
Me.chkAlwaysShowPanelTabs.Name = "chkAlwaysShowPanelTabs"
Me.chkAlwaysShowPanelTabs.Size = New System.Drawing.Size(139, 17)
Me.chkAlwaysShowPanelTabs.TabIndex = 7
Me.chkAlwaysShowPanelTabs.Text = "Always show panel tabs"
Me.chkAlwaysShowPanelTabs.UseVisualStyleBackColor = True
Me.chkIdentifyQuickConnectTabs.AutoSize = True
Me.chkIdentifyQuickConnectTabs.Location = New System.Drawing.Point(3, 95)
Me.chkIdentifyQuickConnectTabs.Name = "chkIdentifyQuickConnectTabs"
Me.chkIdentifyQuickConnectTabs.Size = New System.Drawing.Size(293, 17)
Me.chkIdentifyQuickConnectTabs.TabIndex = 10
Me.chkIdentifyQuickConnectTabs.Text = Global.mRemoteNG.My.Language.strIdentifyQuickConnectTabs
Me.chkIdentifyQuickConnectTabs.UseVisualStyleBackColor = True
'
'tabConnections
'
@@ -1439,6 +1452,7 @@ Public Class frmOptions
Me.chkOpenNewTabRightOfSelected.Checked = My.Settings.OpenTabsRightOfSelected
Me.chkShowLogonInfoOnTabs.Checked = My.Settings.ShowLogonInfoOnTabs
Me.chkShowProtocolOnTabs.Checked = My.Settings.ShowProtocolOnTabs
chkIdentifyQuickConnectTabs.Checked = Settings.IdentifyQuickConnectTabs
Me.chkShowFullConnectionsFilePathInTitle.Checked = My.Settings.ShowCompleteConsPathInTitle
Me.chkDoubleClickClosesTab.Checked = My.Settings.DoubleClickOnTabClosesIt
Me.chkAlwaysShowPanelSelectionDlg.Checked = My.Settings.AlwaysShowPanelSelectionDlg
@@ -1561,6 +1575,7 @@ Public Class frmOptions
My.Settings.OpenTabsRightOfSelected = Me.chkOpenNewTabRightOfSelected.Checked
My.Settings.ShowLogonInfoOnTabs = Me.chkShowLogonInfoOnTabs.Checked
My.Settings.ShowProtocolOnTabs = Me.chkShowProtocolOnTabs.Checked
Settings.IdentifyQuickConnectTabs = chkIdentifyQuickConnectTabs.Checked
My.Settings.DoubleClickOnTabClosesIt = Me.chkDoubleClickClosesTab.Checked
My.Settings.AlwaysShowPanelSelectionDlg = Me.chkAlwaysShowPanelSelectionDlg.Checked
@@ -1735,6 +1750,7 @@ Public Class frmOptions
chkAlwaysShowPanelTabs.Text = My.Language.strAlwaysShowPanelTabs
chkShowDescriptionTooltipsInTree.Text = My.Language.strShowDescriptionTooltips
chkShowProtocolOnTabs.Text = My.Language.strShowProtocolOnTabs
chkIdentifyQuickConnectTabs.Text = Language.strIdentifyQuickConnectTabs
chkShowLogonInfoOnTabs.Text = My.Language.strShowLogonInfoOnTabs
chkOpenNewTabRightOfSelected.Text = My.Language.strOpenNewTabRight
chkAlwaysShowPanelSelectionDlg.Text = My.Language.strAlwaysShowPanelSelection
@@ -1912,4 +1928,9 @@ Public Class frmOptions
End If
End Sub
#End Region
Private Sub lblProxyPort_Click(sender As System.Object, e As System.EventArgs) Handles lblProxyPort.Click
End Sub
End Class

View File

@@ -1951,6 +1951,15 @@ Namespace My
End Get
End Property
'''<summary>
''' Looks up a localized string similar to Identify quick connect tabs by adding the prefix &quot;Quick:&quot;.
'''</summary>
Friend Shared ReadOnly Property strIdentifyQuickConnectTabs() As String
Get
Return ResourceManager.GetString("strIdentifyQuickConnectTabs", resourceCulture)
End Get
End Property
'''<summary>
''' Looks up a localized string similar to Import from Active Directory.
'''</summary>
@@ -5024,6 +5033,15 @@ Namespace My
End Get
End Property
'''<summary>
''' Looks up a localized string similar to Search.
'''</summary>
Friend Shared ReadOnly Property strSearchPrompt() As String
Get
Return ResourceManager.GetString("strSearchPrompt", resourceCulture)
End Get
End Property
'''<summary>
''' Looks up a localized string similar to Send To....
'''</summary>

View File

@@ -2061,4 +2061,10 @@ mRemoteNG will now quit and begin with the installation.</value>
<data name="strAlwaysShowPanelTabs" xml:space="preserve">
<value>Always show panel tabs</value>
</data>
<data name="strIdentifyQuickConnectTabs" xml:space="preserve">
<value>Identify quick connect tabs by adding the prefix "Quick:"</value>
</data>
<data name="strSearchPrompt" xml:space="preserve">
<value>Search</value>
</data>
</root>

View File

@@ -32,6 +32,6 @@ Imports System.Runtime.InteropServices
' by using the '*' as shown below:
' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("1.70.*")>
<Assembly: AssemblyVersion("1.71.*")>
<Assembly: NeutralResourcesLanguageAttribute("en")>

View File

@@ -2321,6 +2321,30 @@ Namespace My
Me("AlwaysShowPanelTabs") = value
End Set
End Property
<Global.System.Configuration.UserScopedSettingAttribute(), _
Global.System.Configuration.SettingsProviderAttribute(GetType(mRemoteNG.Config.Settings.Providers.ChooseProvider)), _
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.Configuration.DefaultSettingValueAttribute("False"), _
Global.System.Configuration.SettingsManageabilityAttribute(Global.System.Configuration.SettingsManageability.Roaming)> _
Public Property IdentifyQuickConnectTabs() As Boolean
Get
Return CType(Me("IdentifyQuickConnectTabs"),Boolean)
End Get
Set
Me("IdentifyQuickConnectTabs") = value
End Set
End Property
<Global.System.Configuration.ApplicationScopedSettingAttribute(), _
Global.System.Configuration.SettingsProviderAttribute(GetType(mRemoteNG.Config.Settings.Providers.ChooseProvider)), _
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.Configuration.DefaultSettingValueAttribute("release")> _
Public ReadOnly Property UpdateChannel() As String
Get
Return CType(Me("UpdateChannel"),String)
End Get
End Property
End Class
End Namespace

View File

@@ -527,5 +527,11 @@
<Setting Name="AlwaysShowPanelTabs" Provider="mRemoteNG.Config.Settings.Providers.ChooseProvider" Roaming="true" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">False</Value>
</Setting>
<Setting Name="IdentifyQuickConnectTabs" Provider="mRemoteNG.Config.Settings.Providers.ChooseProvider" Roaming="true" Type="System.Boolean" Scope="User">
<Value Profile="(Default)">False</Value>
</Setting>
<Setting Name="UpdateChannel" Provider="mRemoteNG.Config.Settings.Providers.ChooseProvider" Type="System.String" Scope="Application">
<Value Profile="(Default)">release</Value>
</Setting>
</Settings>
</SettingsFile>

View File

@@ -43,36 +43,38 @@ Namespace Security
Return StrToEncrypt
End Function
Public Shared Function Decrypt(ByVal StrToDecrypt As String, ByVal StrSecret As String) As String
If StrToDecrypt = "" Or StrSecret = "" Then
Return StrToDecrypt
Public Shared Function Decrypt(ByVal ciphertextBase64 As String, ByVal password As String) As String
If String.IsNullOrEmpty(ciphertextBase64) Or String.IsNullOrEmpty(password) Then
Return ciphertextBase64
End If
Try
Dim rd As New RijndaelManaged
Dim rijndaelIvLength As Integer = 16
Dim md5 As New MD5CryptoServiceProvider
Dim key() As Byte = md5.ComputeHash(Encoding.UTF8.GetBytes(StrSecret))
Dim plaintext As String
md5.Clear()
Using rijndaelManaged As New RijndaelManaged
Using md5 As New MD5CryptoServiceProvider
Dim key() As Byte = md5.ComputeHash(Encoding.UTF8.GetBytes(password))
rijndaelManaged.Key = key
End Using
Dim encdata() As Byte = Convert.FromBase64String(StrToDecrypt)
Dim ms As New MemoryStream(encdata)
Dim iv(15) As Byte
Dim ciphertext() As Byte = Convert.FromBase64String(ciphertextBase64)
ms.Read(iv, 0, rijndaelIvLength)
rd.IV = iv
rd.Key = key
Using memoryStream As New MemoryStream(ciphertext)
Const ivLength As Integer = 16
Dim iv(ivLength - 1) As Byte
memoryStream.Read(iv, 0, ivLength)
rijndaelManaged.IV = iv
Dim cs As New CryptoStream(ms, rd.CreateDecryptor, CryptoStreamMode.Read)
Using cryptoStream As New CryptoStream(memoryStream, rijndaelManaged.CreateDecryptor, CryptoStreamMode.Read)
Using streamReader As New StreamReader(cryptoStream, System.Text.Encoding.UTF8, True)
plaintext = streamReader.ReadToEnd()
End Using
rijndaelManaged.Clear()
End Using ' cryptoStream
End Using ' memoryStream
End Using ' rijndaelManaged
Dim data(ms.Length - rijndaelIvLength) As Byte
Dim i As Integer = cs.Read(data, 0, data.Length)
cs.Close()
rd.Clear()
Return System.Text.Encoding.UTF8.GetString(data, 0, i)
Return plaintext
Catch ex As Exception
' Ignore CryptographicException "Padding is invalid and cannot be removed." when password is incorrect.
If Not TypeOf ex Is CryptographicException Then
@@ -80,7 +82,7 @@ Namespace Security
End If
End Try
Return StrToDecrypt
Return ciphertextBase64
End Function
End Class
End Namespace

View File

@@ -10,7 +10,7 @@ Namespace Security
Public Class Impersonator
#Region "Logon API"
Private Const LOGON32_PROVIDER_DEFAULT As Integer = 0
Private Const LOGON32_LOGON_INTERACTIVE As Integer = 2 ' This parameter causes LogonUser to create a primary token.
Private Const LOGON32_LOGON_NEW_CREDENTIALS As Integer = 9
Private Const SecurityImpersonation As Integer = 2
@@ -37,7 +37,6 @@ Namespace Security
#End Region
Private tokenHandle As New IntPtr(0)
Private dupeTokenHandle As New IntPtr(0)
Private impersonatedUser As WindowsImpersonationContext = Nothing
' GetErrorMessage formats and returns an error message corresponding to the input errorCode.
@@ -59,9 +58,8 @@ Namespace Security
If Not (impersonatedUser Is Nothing) Then Throw New Exception("Already impersonating a user.")
tokenHandle = IntPtr.Zero
dupeTokenHandle = IntPtr.Zero
Dim returnValue As Integer = LogonUser(UserName, DomainName, Password, LOGON32_LOGON_INTERACTIVE, LOGON32_PROVIDER_DEFAULT, tokenHandle)
Dim returnValue As Integer = LogonUser(UserName, DomainName, Password, LOGON32_LOGON_NEW_CREDENTIALS, LOGON32_PROVIDER_DEFAULT, tokenHandle)
If 0 = returnValue Then
Dim errCode As Integer = Marshal.GetLastWin32Error()
@@ -70,17 +68,8 @@ Namespace Security
Throw exLogon
End If
returnValue = DuplicateToken(tokenHandle, SecurityImpersonation, dupeTokenHandle)
If 0 = returnValue Then
CloseHandle(tokenHandle)
Throw New ApplicationException("Error trying to duplicate handle.")
End If
' The token that is passed to the following constructor must
' be a primary token in order to use it for impersonation.
Dim newId As New WindowsIdentity(dupeTokenHandle)
Dim newId As New WindowsIdentity(tokenHandle)
impersonatedUser = newId.Impersonate()
Catch ex As Exception
MessageCollector.AddMessage(Messages.MessageClass.WarningMsg, "Starting Impersonation failed (Sessions feature will not work)" & vbNewLine & ex.Message, True)
End Try
@@ -98,7 +87,6 @@ Namespace Security
Finally
If Not System.IntPtr.op_Equality(tokenHandle, IntPtr.Zero) Then CloseHandle(tokenHandle)
If Not System.IntPtr.op_Equality(dupeTokenHandle, IntPtr.Zero) Then CloseHandle(dupeTokenHandle)
impersonatedUser = Nothing
End Try

View File

@@ -0,0 +1,94 @@
Imports System.Text.RegularExpressions
Namespace Tools
' Adapted from http://qntm.org/cmd
Public Class CommandLineArguments
#Region "Protected Fields"
Protected Arguments As New List(Of Argument)
#End Region
#Region "Public Properties"
Public Property EscapeForShell As Boolean
#End Region
#Region "Public Methods"
Public Sub Add(ByVal argument As String, Optional ByVal forceQuotes As Boolean = False)
Arguments.Add(New Argument(argument, False, forceQuotes))
End Sub
Public Sub Add(ByVal ParamArray argumentArray As String())
For Each argument As String In argumentArray
Add(argument)
Next
End Sub
Public Sub AddFileName(ByVal fileName As String, Optional ByVal forceQuotes As Boolean = False)
Arguments.Add(New Argument(fileName, True, forceQuotes))
End Sub
Public Overrides Function ToString() As String
Dim processedArguments As New List(Of String)
For Each argument As Argument In Arguments
processedArguments.Add(ProcessArgument(argument, EscapeForShell))
Next
Return String.Join(" ", processedArguments.ToArray())
End Function
Public Shared Function PrefixFileName(ByVal argument As String) As String
If argument.StartsWith("-") Then argument = ".\" & argument
Return argument
End Function
Public Shared Function EscapeBackslashes(ByVal argument As String) As String
' Sequence of backslashes followed by a double quote:
' double up all the backslashes and escape the double quote
Return Regex.Replace(argument, "(\\*)""", "$1$1\""")
End Function
Public Shared Function QuoteArgument(ByVal argument As String, Optional ByVal forceQuotes As Boolean = False) As String
If Not forceQuotes And Not String.IsNullOrEmpty(argument) And Not argument.Contains(" ") Then Return argument
' Sequence of backslashes followed by the end of the string
' (which will become a double quote):
' double up all the backslashes
argument = Regex.Replace(argument, "(\\*)$", "$1$1")
Return """" & argument & """"
End Function
Public Shared Function EscapeShellMetacharacters(ByVal argument As String) As String
Return Regex.Replace(argument, "([()%!^""<>&|])", "^$1")
End Function
#End Region
#Region "Protected Methods"
Protected Shared Function ProcessArgument(ByVal argument As Argument, Optional ByVal escapeForShell As Boolean = False) As String
Dim text As String = argument.Text
If argument.IsFileName Then text = PrefixFileName(text)
text = EscapeBackslashes(text)
text = QuoteArgument(text, argument.ForceQuotes)
If escapeForShell Then text = EscapeShellMetacharacters(text)
Return text
End Function
#End Region
#Region "Protected Classes"
Protected Class Argument
Public Sub New(ByVal text As String, Optional ByVal isFileName As Boolean = False, Optional ByVal forceQuotes As Boolean = False)
Me.Text = text
Me.IsFileName = isFileName
Me.ForceQuotes = forceQuotes
End Sub
Public Property Text As String
Public Property IsFileName As Boolean
Public Property ForceQuotes As Boolean
End Class
#End Region
End Class
End Namespace

View File

@@ -223,39 +223,26 @@ Namespace Tools
Public Class TreeNodeSorter
Implements IComparer
Private _nodeToSort As TreeNode
Private _sortType As SortType
Public Property Sorting As System.Windows.Forms.SortOrder
Public Sub New(ByVal node As TreeNode, ByVal sortType As SortType)
Public Sub New(Optional ByVal sortOrder As SortOrder = SortOrder.None)
MyBase.New()
Me._nodeToSort = node
Me._sortType = sortType
Sorting = sortOrder
End Sub
Public Function Compare(ByVal x As Object, ByVal y As Object) As Integer Implements IComparer.Compare
Dim tx As TreeNode = CType(x, TreeNode)
Dim ty As TreeNode = CType(y, TreeNode)
If ((tx.Parent Is Me._nodeToSort) AndAlso (ty.Parent Is Me._nodeToSort)) Then
' Ascending
If (Me._sortType = SortType.Ascending) Then
Select Case Sorting
Case SortOrder.Ascending
Return String.Compare(tx.Text, ty.Text)
End If
' Descending
If (Me._sortType = SortType.Descending) Then
Case SortOrder.Descending
Return String.Compare(ty.Text, tx.Text)
End If
End If
Return 0
Case Else
Return 0
End Select
End Function
Public Enum SortType
Ascending = 0
Descending = 1
End Enum
End Class
End Class
End Namespace

View File

@@ -117,21 +117,21 @@ Namespace Tools
_ConnectionInfo = ConnectionInfo
Dim p As New Process()
Dim pI As New ProcessStartInfo()
Dim process As New Process()
With process.StartInfo
.UseShellExecute = False
.FileName = ParseText(_FileName)
pI.FileName = ParseText(_FileName)
pI.Arguments = ParseText(_Arguments)
.Arguments = CommandLineArguments.EscapeBackslashes(_Arguments)
End With
p.StartInfo = pI
p.Start()
process.Start()
If _WaitForExit Then
p.WaitForExit()
process.WaitForExit()
End If
Return p
Return process
Catch ex As Exception
MessageCollector.AddMessage(Messages.MessageClass.ErrorMsg, "Couldn't start external application." & vbNewLine & ex.Message)
Return Nothing

View File

@@ -319,6 +319,10 @@ Namespace Tree
oldTreeNode.Parent.Nodes.Insert(oldTreeNode.Index + 1, newTreeNode)
TreeView.SelectedNode = newTreeNode
Else
Dim parentContainerInfo As Container.Info = TryCast(parentNode.Tag, Container.Info)
If parentContainerInfo IsNot Nothing Then
newConnectionInfo.Parent = parentContainerInfo
End If
parentNode.Nodes.Add(newTreeNode)
End If
ElseIf GetNodeType(oldTreeNode) = Type.Container Then
@@ -497,27 +501,52 @@ Namespace Tree
TreeView.EndUpdate()
End Sub
Public Shared Sub Sort(ByVal treeNode As TreeNode, ByVal sortType As Tools.Controls.TreeNodeSorter.SortType)
Try
TreeView.BeginUpdate()
If treeNode Is Nothing Then
Public Shared Sub Sort(ByVal treeNode As TreeNode, ByVal sorting As System.Windows.Forms.SortOrder)
If TreeView Is Nothing Then Return
TreeView.BeginUpdate()
If treeNode Is Nothing Then
If TreeView.Nodes.Count > 0 Then
treeNode = TreeView.Nodes.Item(0)
ElseIf Tree.Node.GetNodeType(treeNode) = Type.Connection Then
treeNode = treeNode.Parent
Else
Return
End If
ElseIf GetNodeType(treeNode) = Type.Connection Then
treeNode = treeNode.Parent
If treeNode Is Nothing Then Return
End If
Dim ns As New Tools.Controls.TreeNodeSorter(treeNode, sortType)
Sort(treeNode, New Tools.Controls.TreeNodeSorter(sorting))
TreeView.TreeViewNodeSorter = ns
TreeView.Sort()
TreeView.EndUpdate()
End Sub
For Each childNode As TreeNode In treeNode.Nodes
If GetNodeType(childNode) = Type.Container Then Sort(childNode, sortType)
' Adapted from http://www.codeproject.com/Tips/252234/ASP-NET-TreeView-Sort
Private Shared Sub Sort(ByVal treeNode As TreeNode, ByVal nodeSorter As Tools.Controls.TreeNodeSorter)
For Each childNode As TreeNode In treeNode.Nodes
Sort(childNode, nodeSorter)
Next
Try
Dim sortedNodes As New List(Of TreeNode)
Dim currentNode As TreeNode = Nothing
While (treeNode.Nodes.Count > 0)
For Each childNode As TreeNode In treeNode.Nodes
If (currentNode Is Nothing OrElse nodeSorter.Compare(childNode, currentNode) < 0) Then
currentNode = childNode
End If
Next
treeNode.Nodes.Remove(currentNode)
sortedNodes.Add(currentNode)
currentNode = Nothing
End While
For Each childNode As TreeNode In sortedNodes
treeNode.Nodes.Add(childNode)
Next
Catch ex As Exception
MessageCollector.AddMessage(Messages.MessageClass.ErrorMsg, "Sort nodes failed" & vbNewLine & ex.Message, True)
Finally
TreeView.EndUpdate()
End Try
End Sub

View File

@@ -390,6 +390,8 @@ Namespace UI
Me.btnIcon.Enabled = True
Me.btnHostStatus.Enabled = True
ElseIf Me.DefaultInheritanceVisible Then 'Default Inhertiance selected
pGrid.SelectedObject = Obj
Me.btnShowProperties.Enabled = True
Me.btnShowInheritance.Enabled = True
Me.btnShowDefaultProperties.Enabled = False
@@ -607,6 +609,12 @@ Namespace UI
End Try
End Sub
Private Sub pGrid_PropertySortChanged(ByVal sender As Object, ByVal e As EventArgs) Handles pGrid.PropertySortChanged
If pGrid.PropertySort = PropertySort.CategorizedAlphabetical Then
pGrid.PropertySort = PropertySort.Categorized
End If
End Sub
Private Sub ShowHideGridItems()
Try
Dim strHide As New List(Of String)

View File

@@ -292,6 +292,30 @@ Namespace UI
ApplyLanguage()
End Sub
Private _documentHandlersAdded As Boolean = False
Private _floatHandlersAdded As Boolean = False
Private Sub Connection_DockStateChanged(ByVal sender As System.Object, ByVal e As EventArgs) Handles Me.DockStateChanged
If DockState = DockState.Float Then
If _documentHandlersAdded Then
RemoveHandler frmMain.ResizeBegin, AddressOf Connection_ResizeBegin
RemoveHandler frmMain.ResizeEnd, AddressOf Connection_ResizeEnd
_documentHandlersAdded = False
End If
AddHandler DockHandler.FloatPane.FloatWindow.ResizeBegin, AddressOf Connection_ResizeBegin
AddHandler DockHandler.FloatPane.FloatWindow.ResizeEnd, AddressOf Connection_ResizeEnd
_floatHandlersAdded = True
ElseIf DockState = DockState.Document Then
If _floatHandlersAdded Then
RemoveHandler DockHandler.FloatPane.FloatWindow.ResizeBegin, AddressOf Connection_ResizeBegin
RemoveHandler DockHandler.FloatPane.FloatWindow.ResizeEnd, AddressOf Connection_ResizeEnd
_floatHandlersAdded = False
End If
AddHandler frmMain.ResizeBegin, AddressOf Connection_ResizeBegin
AddHandler frmMain.ResizeEnd, AddressOf Connection_ResizeEnd
_documentHandlersAdded = True
End If
End Sub
Private Sub ApplyLanguage()
cmenTabFullscreen.Text = My.Language.strMenuFullScreenRDP
cmenTabSmartSize.Text = My.Language.strMenuSmartSize
@@ -335,19 +359,14 @@ Namespace UI
End Try
End Sub
Private Sub Connection_Resize(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Resize
Try
For Each tabP As Magic.Controls.TabPage In Me.TabController.TabPages
If tabP.Tag IsNot Nothing Then
If TypeOf tabP.Tag Is mRemoteNG.Connection.InterfaceControl Then
Dim IC As mRemoteNG.Connection.InterfaceControl = tabP.Tag
IC.Protocol.Resize()
End If
End If
Next
Catch ex As Exception
MessageCollector.AddMessage(Messages.MessageClass.ErrorMsg, "Connection_Resize (UI.Window.Connections) failed" & vbNewLine & ex.Message, True)
End Try
Public Shadows Event ResizeBegin As EventHandler
Private Sub Connection_ResizeBegin(ByVal sender As System.Object, ByVal e As EventArgs)
RaiseEvent ResizeBegin(Me, e)
End Sub
Public Shadows Event ResizeEnd As EventHandler
Public Sub Connection_ResizeEnd(ByVal sender As System.Object, ByVal e As EventArgs)
RaiseEvent ResizeEnd(sender, e)
End Sub
#End Region
@@ -424,15 +443,20 @@ Namespace UI
End If
If IC.Info.Protocol = mRemoteNG.Connection.Protocol.Protocols.RDP Then
Me.cmenTabFullscreen.Enabled = True
Me.cmenTabSmartSize.Enabled = True
Dim rdp As mRemoteNG.Connection.Protocol.RDP = IC.Protocol
Me.cmenTabSmartSize.Checked = rdp.SmartSize
Me.cmenTabFullscreen.Checked = rdp.Fullscreen
If rdp.RedirectKeys Then
cmenTabFullscreen.Enabled = False
Else
cmenTabFullscreen.Enabled = True
cmenTabFullscreen.Checked = rdp.Fullscreen
End If
cmenTabSmartSize.Enabled = True
cmenTabSmartSize.Checked = rdp.SmartSize
Else
Me.cmenTabFullscreen.Enabled = False
Me.cmenTabSmartSize.Enabled = False
cmenTabFullscreen.Enabled = False
cmenTabSmartSize.Enabled = False
End If
If IC.Info.Protocol = mRemoteNG.Connection.Protocol.Protocols.VNC Then

View File

@@ -1,4 +1,5 @@
Imports mRemoteNG.Connection
Imports mRemoteNG.My
Imports WeifenLuo.WinFormsUI.Docking
Imports mRemoteNG.App.Runtime
@@ -53,51 +54,51 @@ Namespace UI
Friend WithEvents mMenAddFolder As System.Windows.Forms.ToolStripMenuItem
Public WithEvents tvConnections As System.Windows.Forms.TreeView
Private Sub InitializeComponent()
Me.components = New System.ComponentModel.Container
Me.components = New System.ComponentModel.Container()
Dim TreeNode1 As System.Windows.Forms.TreeNode = New System.Windows.Forms.TreeNode("Connections")
Me.tvConnections = New System.Windows.Forms.TreeView
Me.tvConnections = New System.Windows.Forms.TreeView()
Me.cMenTree = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.cMenTreeAddConnection = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeAddFolder = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeSep1 = New System.Windows.Forms.ToolStripSeparator
Me.cMenTreeConnect = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeConnectWithOptions = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeConnectWithOptionsConnectToConsoleSession = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeConnectWithOptionsDontConnectToConsoleSession = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeConnectWithOptionsConnectInFullscreen = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeConnectWithOptionsChoosePanelBeforeConnecting = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeDisconnect = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeSep2 = New System.Windows.Forms.ToolStripSeparator
Me.cMenTreeToolsTransferFile = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeToolsImportExport = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeToolsImportExportExportmRemoteXML = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeToolsImportExportImportmRemoteXML = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeToolsImportExportSep1 = New System.Windows.Forms.ToolStripSeparator
Me.cMenTreeToolsImportExportImportFromAD = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeToolsImportExportImportFromRDPFiles = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeToolsImportExportImportFromPortScan = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeToolsSort = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeToolsSortAscending = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeToolsSortDescending = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeToolsExternalApps = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeSep3 = New System.Windows.Forms.ToolStripSeparator
Me.cMenTreeDuplicate = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeRename = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeDelete = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeSep4 = New System.Windows.Forms.ToolStripSeparator
Me.cMenTreeMoveUp = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeMoveDown = New System.Windows.Forms.ToolStripMenuItem
Me.cMenTreeAddConnection = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeAddFolder = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeSep1 = New System.Windows.Forms.ToolStripSeparator()
Me.cMenTreeConnect = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeConnectWithOptions = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeConnectWithOptionsConnectToConsoleSession = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeConnectWithOptionsDontConnectToConsoleSession = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeConnectWithOptionsConnectInFullscreen = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeConnectWithOptionsChoosePanelBeforeConnecting = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeDisconnect = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeSep2 = New System.Windows.Forms.ToolStripSeparator()
Me.cMenTreeToolsTransferFile = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeToolsImportExport = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeToolsImportExportExportmRemoteXML = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeToolsImportExportImportmRemoteXML = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeToolsImportExportSep1 = New System.Windows.Forms.ToolStripSeparator()
Me.cMenTreeToolsImportExportImportFromAD = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeToolsImportExportImportFromRDPFiles = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeToolsImportExportImportFromPortScan = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeToolsSort = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeToolsSortAscending = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeToolsSortDescending = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeToolsExternalApps = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeSep3 = New System.Windows.Forms.ToolStripSeparator()
Me.cMenTreeDuplicate = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeRename = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeDelete = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeSep4 = New System.Windows.Forms.ToolStripSeparator()
Me.cMenTreeMoveUp = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTreeMoveDown = New System.Windows.Forms.ToolStripMenuItem()
Me.imgListTree = New System.Windows.Forms.ImageList(Me.components)
Me.pnlConnections = New System.Windows.Forms.Panel
Me.PictureBox1 = New System.Windows.Forms.PictureBox
Me.txtSearch = New System.Windows.Forms.TextBox
Me.msMain = New System.Windows.Forms.MenuStrip
Me.mMenAddConnection = New System.Windows.Forms.ToolStripMenuItem
Me.mMenAddFolder = New System.Windows.Forms.ToolStripMenuItem
Me.mMenView = New System.Windows.Forms.ToolStripMenuItem
Me.mMenViewExpandAllFolders = New System.Windows.Forms.ToolStripMenuItem
Me.mMenViewCollapseAllFolders = New System.Windows.Forms.ToolStripMenuItem
Me.mMenSortAscending = New System.Windows.Forms.ToolStripMenuItem
Me.pnlConnections = New System.Windows.Forms.Panel()
Me.PictureBox1 = New System.Windows.Forms.PictureBox()
Me.txtSearch = New System.Windows.Forms.TextBox()
Me.msMain = New System.Windows.Forms.MenuStrip()
Me.mMenAddConnection = New System.Windows.Forms.ToolStripMenuItem()
Me.mMenAddFolder = New System.Windows.Forms.ToolStripMenuItem()
Me.mMenView = New System.Windows.Forms.ToolStripMenuItem()
Me.mMenViewExpandAllFolders = New System.Windows.Forms.ToolStripMenuItem()
Me.mMenViewCollapseAllFolders = New System.Windows.Forms.ToolStripMenuItem()
Me.mMenSortAscending = New System.Windows.Forms.ToolStripMenuItem()
Me.cMenTree.SuspendLayout()
Me.pnlConnections.SuspendLayout()
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()
@@ -108,8 +109,8 @@ Namespace UI
'
Me.tvConnections.AllowDrop = True
Me.tvConnections.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
Or System.Windows.Forms.AnchorStyles.Left) _
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Or System.Windows.Forms.AnchorStyles.Left) _
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.tvConnections.BorderStyle = System.Windows.Forms.BorderStyle.None
Me.tvConnections.ContextMenuStrip = Me.cMenTree
Me.tvConnections.HideSelection = False
@@ -122,7 +123,7 @@ Namespace UI
TreeNode1.Text = "Connections"
Me.tvConnections.Nodes.AddRange(New System.Windows.Forms.TreeNode() {TreeNode1})
Me.tvConnections.SelectedImageIndex = 0
Me.tvConnections.Size = New System.Drawing.Size(192, 407)
Me.tvConnections.Size = New System.Drawing.Size(192, 410)
Me.tvConnections.TabIndex = 20
'
'cMenTree
@@ -157,7 +158,7 @@ Namespace UI
Me.cMenTreeConnect.Image = Global.mRemoteNG.My.Resources.Resources.Play
Me.cMenTreeConnect.Name = "cMenTreeConnect"
Me.cMenTreeConnect.ShortcutKeys = CType(((System.Windows.Forms.Keys.Control Or System.Windows.Forms.Keys.Shift) _
Or System.Windows.Forms.Keys.C), System.Windows.Forms.Keys)
Or System.Windows.Forms.Keys.C), System.Windows.Forms.Keys)
Me.cMenTreeConnect.Size = New System.Drawing.Size(186, 22)
Me.cMenTreeConnect.Text = "Connect"
'
@@ -348,8 +349,8 @@ Namespace UI
'pnlConnections
'
Me.pnlConnections.Anchor = CType((((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Bottom) _
Or System.Windows.Forms.AnchorStyles.Left) _
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Or System.Windows.Forms.AnchorStyles.Left) _
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.pnlConnections.Controls.Add(Me.PictureBox1)
Me.pnlConnections.Controls.Add(Me.txtSearch)
Me.pnlConnections.Controls.Add(Me.tvConnections)
@@ -362,7 +363,7 @@ Namespace UI
'
Me.PictureBox1.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
Me.PictureBox1.Image = Global.mRemoteNG.My.Resources.Resources.Search
Me.PictureBox1.Location = New System.Drawing.Point(0, 411)
Me.PictureBox1.Location = New System.Drawing.Point(2, 412)
Me.PictureBox1.Name = "PictureBox1"
Me.PictureBox1.Size = New System.Drawing.Size(16, 16)
Me.PictureBox1.SizeMode = System.Windows.Forms.PictureBoxSizeMode.AutoSize
@@ -372,13 +373,15 @@ Namespace UI
'txtSearch
'
Me.txtSearch.Anchor = CType(((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left) _
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.txtSearch.BorderStyle = System.Windows.Forms.BorderStyle.None
Me.txtSearch.Location = New System.Drawing.Point(21, 412)
Me.txtSearch.ForeColor = System.Drawing.SystemColors.GrayText
Me.txtSearch.Location = New System.Drawing.Point(19, 413)
Me.txtSearch.Name = "txtSearch"
Me.txtSearch.Size = New System.Drawing.Size(169, 13)
Me.txtSearch.Size = New System.Drawing.Size(171, 13)
Me.txtSearch.TabIndex = 30
Me.txtSearch.TabStop = False
Me.txtSearch.Text = "Search"
'
'msMain
'
@@ -462,6 +465,10 @@ Namespace UI
#Region "Form Stuff"
Private Sub Tree_Load(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Load
ApplyLanguage()
txtSearch.Multiline = True
txtSearch.MinimumSize = New Size(0, 14)
txtSearch.Size = New Size(txtSearch.Size.Width, 14)
txtSearch.Multiline = False
End Sub
Private Sub ApplyLanguage()
@@ -495,6 +502,7 @@ Namespace UI
mMenViewExpandAllFolders.Text = My.Language.strExpandAllFolders
mMenViewCollapseAllFolders.Text = My.Language.strCollapseAllFolders
mMenSortAscending.ToolTipText = My.Language.strSortAsc
txtSearch.Text = Language.strSearchPrompt
TabText = My.Language.strConnections
Text = My.Language.strConnections
End Sub
@@ -934,24 +942,24 @@ Namespace UI
Me.ImportFromPortScan()
End Sub
Private Sub mMenSortAscending_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles mMenSortAscending.Click
Me.tvConnections.BeginUpdate()
mRemoteNG.Tree.Node.Sort(Me.tvConnections.Nodes.Item(0), Tools.Controls.TreeNodeSorter.SortType.Ascending)
Me.tvConnections.EndUpdate()
Private Sub mMenSortAscending_Click(ByVal sender As System.Object, ByVal e As EventArgs) Handles mMenSortAscending.Click
tvConnections.BeginUpdate()
mRemoteNG.Tree.Node.Sort(tvConnections.Nodes.Item(0), System.Windows.Forms.SortOrder.Ascending)
tvConnections.EndUpdate()
SaveConnectionsBG()
End Sub
Private Sub cMenTreeToolsSortAscending_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cMenTreeToolsSortAscending.Click
Me.tvConnections.BeginUpdate()
mRemoteNG.Tree.Node.Sort(Me.tvConnections.SelectedNode, Tools.Controls.TreeNodeSorter.SortType.Ascending)
Me.tvConnections.EndUpdate()
Private Sub cMenTreeToolsSortAscending_Click(ByVal sender As System.Object, ByVal e As EventArgs) Handles cMenTreeToolsSortAscending.Click
tvConnections.BeginUpdate()
mRemoteNG.Tree.Node.Sort(tvConnections.SelectedNode, System.Windows.Forms.SortOrder.Ascending)
tvConnections.EndUpdate()
SaveConnectionsBG()
End Sub
Private Sub cMenTreeToolsSortDescending_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles cMenTreeToolsSortDescending.Click
Me.tvConnections.BeginUpdate()
mRemoteNG.Tree.Node.Sort(Me.tvConnections.SelectedNode, Tools.Controls.TreeNodeSorter.SortType.Descending)
Me.tvConnections.EndUpdate()
Private Sub cMenTreeToolsSortDescending_Click(ByVal sender As System.Object, ByVal e As EventArgs) Handles cMenTreeToolsSortDescending.Click
tvConnections.BeginUpdate()
mRemoteNG.Tree.Node.Sort(tvConnections.SelectedNode, System.Windows.Forms.SortOrder.Descending)
tvConnections.EndUpdate()
SaveConnectionsBG()
End Sub
@@ -1202,6 +1210,20 @@ Namespace UI
#End Region
#Region "Search"
Private Sub txtSearch_GotFocus(ByVal sender As Object, ByVal e As EventArgs) Handles txtSearch.GotFocus
txtSearch.ForeColor = SystemColors.WindowText
If txtSearch.Text = Language.strSearchPrompt Then
txtSearch.Text = ""
End If
End Sub
Private Sub txtSearch_LostFocus(ByVal sender As Object, ByVal e As EventArgs) Handles txtSearch.LostFocus
If txtSearch.Text = "" Then
txtSearch.ForeColor = SystemColors.GrayText
txtSearch.Text = Language.strSearchPrompt
End If
End Sub
Private Sub txtSearch_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles txtSearch.KeyDown
Try
If e.KeyCode = Keys.Escape Then

View File

@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<configuration>
<configSections>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net-net-1.0"/>
<section name="log4net" type="log4net.Config.Log4NetConfigurationSectionHandler, log4net"/>
<sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<section name="mRemoteNG.My.MySettings" type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false"/>
</sectionGroup>
@@ -10,7 +10,7 @@
</sectionGroup>
</configSections>
<log4net>
<logger name="mRemoteNG.Log">
<logger name="Logger">
<level value="INFO"/>
</logger>
@@ -565,6 +565,9 @@
<setting name="AlwaysShowPanelTabs" serializeAs="String">
<value>False</value>
</setting>
<setting name="IdentifyQuickConnectTabs" serializeAs="String">
<value>False</value>
</setting>
</mRemoteNG.My.MySettings>
</userSettings>
<applicationSettings>
@@ -572,6 +575,9 @@
<setting name="SupportedUICultures" serializeAs="String">
<value>de,en,en-US,es-AR,es,fr,it,nl,pt,pl,ru,uk,zh-CN</value>
</setting>
<setting name="UpdateChannel" serializeAs="String">
<value>release</value>
</setting>
</mRemoteNG.My.MySettings>
</applicationSettings>
<startup><supportedRuntime version="v2.0.50727"/></startup></configuration>

View File

@@ -213,6 +213,7 @@
<Compile Include="Connection\Connection.Protocol.VNC.vb" />
<Compile Include="Connection\Connection.PuttySession.vb" />
<Compile Include="Connection\Connection.QuickConnect.vb" />
<Compile Include="Tools\CommandLineArguments.vb" />
<Compile Include="Container\Container.Info.vb" />
<Compile Include="Container\Container.List.vb" />
<Compile Include="Credential\Credential.Info.vb" />