mirror of
https://github.com/mRemoteNG/mRemoteNG.git
synced 2026-02-17 22:11:48 +08:00
Window -> Segoe UI
and cleanup
This commit is contained in:
@@ -29,7 +29,7 @@ namespace mRemoteNG.UI.Window
|
||||
}
|
||||
#endregion
|
||||
|
||||
internal new void ApplyTheme()
|
||||
internal void ApplyTheme()
|
||||
{
|
||||
_themeManager = ThemeManager.getInstance();
|
||||
if (!_themeManager.ThemingActive) return;
|
||||
@@ -37,21 +37,34 @@ namespace mRemoteNG.UI.Window
|
||||
ForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("Dialog_Foreground");
|
||||
}
|
||||
|
||||
|
||||
|
||||
#region Private Methods
|
||||
/*
|
||||
private void Base_Load(object sender, EventArgs e)
|
||||
{
|
||||
FrmMain.Default.ShowHidePanelTabs();
|
||||
}
|
||||
*/
|
||||
|
||||
/*
|
||||
private void Base_FormClosed(object sender, System.Windows.Forms.FormClosedEventArgs e)
|
||||
{
|
||||
FrmMain.Default.ShowHidePanelTabs(this);
|
||||
}
|
||||
*/
|
||||
/*
|
||||
private void Base_Load(object sender, EventArgs e)
|
||||
{
|
||||
FrmMain.Default.ShowHidePanelTabs();
|
||||
}
|
||||
*/
|
||||
|
||||
/*
|
||||
private void Base_FormClosed(object sender, System.Windows.Forms.FormClosedEventArgs e)
|
||||
{
|
||||
FrmMain.Default.ShowHidePanelTabs(this);
|
||||
}
|
||||
*/
|
||||
#endregion
|
||||
}
|
||||
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// BaseWindow
|
||||
//
|
||||
this.ClientSize = new System.Drawing.Size(284, 261);
|
||||
this.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.Name = "BaseWindow";
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
120
mRemoteV1/UI/Window/BaseWindow.resx
Normal file
120
mRemoteV1/UI/Window/BaseWindow.resx
Normal file
@@ -0,0 +1,120 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<root>
|
||||
<!--
|
||||
Microsoft ResX Schema
|
||||
|
||||
Version 2.0
|
||||
|
||||
The primary goals of this format is to allow a simple XML format
|
||||
that is mostly human readable. The generation and parsing of the
|
||||
various data types are done through the TypeConverter classes
|
||||
associated with the data types.
|
||||
|
||||
Example:
|
||||
|
||||
... ado.net/XML headers & schema ...
|
||||
<resheader name="resmimetype">text/microsoft-resx</resheader>
|
||||
<resheader name="version">2.0</resheader>
|
||||
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
|
||||
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
|
||||
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
|
||||
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
|
||||
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
|
||||
<value>[base64 mime encoded serialized .NET Framework object]</value>
|
||||
</data>
|
||||
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
|
||||
<comment>This is a comment</comment>
|
||||
</data>
|
||||
|
||||
There are any number of "resheader" rows that contain simple
|
||||
name/value pairs.
|
||||
|
||||
Each data row contains a name, and value. The row also contains a
|
||||
type or mimetype. Type corresponds to a .NET class that support
|
||||
text/value conversion through the TypeConverter architecture.
|
||||
Classes that don't support this are serialized and stored with the
|
||||
mimetype set.
|
||||
|
||||
The mimetype is used for serialized objects, and tells the
|
||||
ResXResourceReader how to depersist the object. This is currently not
|
||||
extensible. For a given mimetype the value must be set accordingly:
|
||||
|
||||
Note - application/x-microsoft.net.object.binary.base64 is the format
|
||||
that the ResXResourceWriter will generate, however the reader can
|
||||
read any of the formats listed below.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.binary.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.soap.base64
|
||||
value : The object must be serialized with
|
||||
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
|
||||
: and then encoded with base64 encoding.
|
||||
|
||||
mimetype: application/x-microsoft.net.object.bytearray.base64
|
||||
value : The object must be serialized into a byte array
|
||||
: using a System.ComponentModel.TypeConverter
|
||||
: and then encoded with base64 encoding.
|
||||
-->
|
||||
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
|
||||
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
|
||||
<xsd:element name="root" msdata:IsDataSet="true">
|
||||
<xsd:complexType>
|
||||
<xsd:choice maxOccurs="unbounded">
|
||||
<xsd:element name="metadata">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" use="required" type="xsd:string" />
|
||||
<xsd:attribute name="type" type="xsd:string" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="assembly">
|
||||
<xsd:complexType>
|
||||
<xsd:attribute name="alias" type="xsd:string" />
|
||||
<xsd:attribute name="name" type="xsd:string" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="data">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
|
||||
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
|
||||
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
|
||||
<xsd:attribute ref="xml:space" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
<xsd:element name="resheader">
|
||||
<xsd:complexType>
|
||||
<xsd:sequence>
|
||||
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
|
||||
</xsd:sequence>
|
||||
<xsd:attribute name="name" type="xsd:string" use="required" />
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:choice>
|
||||
</xsd:complexType>
|
||||
</xsd:element>
|
||||
</xsd:schema>
|
||||
<resheader name="resmimetype">
|
||||
<value>text/microsoft-resx</value>
|
||||
</resheader>
|
||||
<resheader name="version">
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
</root>
|
||||
@@ -344,7 +344,7 @@ namespace mRemoteNG.UI.Window
|
||||
this.chkAlwaysShow.FlatStyle = System.Windows.Forms.FlatStyle.Flat;
|
||||
this.chkAlwaysShow.Location = new System.Drawing.Point(12, 814);
|
||||
this.chkAlwaysShow.Name = "chkAlwaysShow";
|
||||
this.chkAlwaysShow.Size = new System.Drawing.Size(185, 17);
|
||||
this.chkAlwaysShow.Size = new System.Drawing.Size(200, 17);
|
||||
this.chkAlwaysShow.TabIndex = 51;
|
||||
this.chkAlwaysShow.Text = "Always show this screen at startup";
|
||||
this.chkAlwaysShow.UseVisualStyleBackColor = true;
|
||||
@@ -374,6 +374,7 @@ namespace mRemoteNG.UI.Window
|
||||
this.Controls.Add(this.pnlChecks);
|
||||
this.Controls.Add(this.chkAlwaysShow);
|
||||
this.Controls.Add(this.btnCheckAgain);
|
||||
this.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.Icon = global::mRemoteNG.Resources.ComponentsCheck_Icon;
|
||||
this.Name = "ComponentsCheckWindow";
|
||||
this.TabText = "Components Check";
|
||||
|
||||
@@ -46,7 +46,7 @@ namespace mRemoteNG.UI.Window
|
||||
private AbstractConnectionRecord _selectedTreeNode;
|
||||
public AbstractConnectionRecord SelectedTreeNode
|
||||
{
|
||||
get { return _selectedTreeNode; }
|
||||
get => _selectedTreeNode;
|
||||
set
|
||||
{
|
||||
_selectedTreeNode = value;
|
||||
@@ -207,11 +207,8 @@ namespace mRemoteNG.UI.Window
|
||||
#region Public Properties
|
||||
public bool PropertiesVisible
|
||||
{
|
||||
get
|
||||
{
|
||||
return _btnShowProperties.Checked;
|
||||
}
|
||||
set
|
||||
get => _btnShowProperties.Checked;
|
||||
set
|
||||
{
|
||||
_btnShowProperties.Checked = value;
|
||||
if (!value) return;
|
||||
@@ -223,11 +220,8 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
public bool InheritanceVisible
|
||||
{
|
||||
get
|
||||
{
|
||||
return _btnShowInheritance.Checked;
|
||||
}
|
||||
set
|
||||
get => _btnShowInheritance.Checked;
|
||||
set
|
||||
{
|
||||
_btnShowInheritance.Checked = value;
|
||||
if (!value) return;
|
||||
@@ -239,11 +233,8 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
public bool DefaultPropertiesVisible
|
||||
{
|
||||
get
|
||||
{
|
||||
return _btnShowDefaultProperties.Checked;
|
||||
}
|
||||
set
|
||||
get => _btnShowDefaultProperties.Checked;
|
||||
set
|
||||
{
|
||||
_btnShowDefaultProperties.Checked = value;
|
||||
if (!value) return;
|
||||
@@ -255,8 +246,8 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
public bool DefaultInheritanceVisible
|
||||
{
|
||||
get { return _btnShowDefaultInheritance.Checked; }
|
||||
set
|
||||
get => _btnShowDefaultInheritance.Checked;
|
||||
set
|
||||
{
|
||||
_btnShowDefaultInheritance.Checked = value;
|
||||
if (!value) return;
|
||||
@@ -432,14 +423,11 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
_btnIcon.Image = null;
|
||||
|
||||
var gridObjectAsConnectionInfo = propertyGridObject as ConnectionInfo;
|
||||
if (gridObjectAsConnectionInfo != null) //CONNECTION INFO
|
||||
if (propertyGridObject is ConnectionInfo gridObjectAsConnectionInfo) //CONNECTION INFO
|
||||
{
|
||||
var gridObjectAsContainerInfo = propertyGridObject as ContainerInfo;
|
||||
if (gridObjectAsContainerInfo != null) //CONTAINER
|
||||
if (propertyGridObject is ContainerInfo gridObjectAsContainerInfo) //CONTAINER
|
||||
{
|
||||
var gridObjectAsRootNodeInfo = propertyGridObject as RootNodeInfo;
|
||||
if (gridObjectAsRootNodeInfo != null) // ROOT
|
||||
if (propertyGridObject is RootNodeInfo gridObjectAsRootNodeInfo) // ROOT
|
||||
{
|
||||
// ReSharper disable once SwitchStatementMissingSomeCases
|
||||
switch (gridObjectAsRootNodeInfo.Type)
|
||||
@@ -617,20 +605,18 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
private new void ApplyTheme()
|
||||
{
|
||||
if (Themes.ThemeManager.getInstance().ThemingActive)
|
||||
{
|
||||
_pGrid.BackColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("TextBox_Background");
|
||||
_pGrid.ForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("TextBox_Foreground");
|
||||
_pGrid.ViewBackColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Background");
|
||||
_pGrid.ViewForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Foreground");
|
||||
_pGrid.LineColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Border");
|
||||
_pGrid.HelpBackColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("TextBox_Background");
|
||||
_pGrid.HelpForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("TextBox_Foreground");
|
||||
_pGrid.CategoryForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Header_Foreground");
|
||||
_pGrid.CommandsDisabledLinkColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Disabled_Foreground");
|
||||
_pGrid.CommandsBackColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Disabled_Background");
|
||||
_pGrid.CommandsForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Disabled_Foreground");
|
||||
}
|
||||
if (!ThemeManager.getInstance().ThemingActive) return;
|
||||
_pGrid.BackColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("TextBox_Background");
|
||||
_pGrid.ForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("TextBox_Foreground");
|
||||
_pGrid.ViewBackColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Background");
|
||||
_pGrid.ViewForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Foreground");
|
||||
_pGrid.LineColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Border");
|
||||
_pGrid.HelpBackColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("TextBox_Background");
|
||||
_pGrid.HelpForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("TextBox_Foreground");
|
||||
_pGrid.CategoryForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Header_Foreground");
|
||||
_pGrid.CommandsDisabledLinkColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Disabled_Foreground");
|
||||
_pGrid.CommandsBackColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Disabled_Background");
|
||||
_pGrid.CommandsForeColor = _themeManager.ActiveTheme.ExtendedPalette.getColor("List_Item_Disabled_Foreground");
|
||||
}
|
||||
|
||||
private void AddToolStripItems()
|
||||
@@ -716,8 +702,7 @@ namespace mRemoteNG.UI.Window
|
||||
private void UpdateConnectionInfoNode(PropertyValueChangedEventArgs e)
|
||||
{
|
||||
Debug.WriteLine("update config");
|
||||
var selectedGridObject = _pGrid.SelectedObject as ConnectionInfo;
|
||||
if (selectedGridObject == null) return;
|
||||
if (!(_pGrid.SelectedObject is ConnectionInfo selectedGridObject)) return;
|
||||
if (e.ChangedItem.Label == Language.strPropertyNameProtocol)
|
||||
{
|
||||
selectedGridObject.SetDefaultPort();
|
||||
@@ -748,8 +733,7 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
private void UpdateRootInfoNode(PropertyValueChangedEventArgs e)
|
||||
{
|
||||
var rootInfo = _pGrid.SelectedObject as RootNodeInfo;
|
||||
if (rootInfo == null)
|
||||
if (!(_pGrid.SelectedObject is RootNodeInfo rootInfo))
|
||||
return;
|
||||
|
||||
if (e.ChangedItem.PropertyDescriptor?.Name != "Password")
|
||||
@@ -795,8 +779,7 @@ namespace mRemoteNG.UI.Window
|
||||
try
|
||||
{
|
||||
var strHide = new List<string>();
|
||||
var o = _pGrid.SelectedObject as RootNodeInfo;
|
||||
if (o != null)
|
||||
if (_pGrid.SelectedObject is RootNodeInfo o)
|
||||
{
|
||||
var rootInfo = o;
|
||||
if (rootInfo.Type == RootNodeType.PuttySessions)
|
||||
@@ -1456,8 +1439,7 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
private void btnShowProperties_Click(object sender, EventArgs e)
|
||||
{
|
||||
var o = _pGrid.SelectedObject as ConnectionInfoInheritance;
|
||||
if (o != null)
|
||||
if (_pGrid.SelectedObject is ConnectionInfoInheritance o)
|
||||
{
|
||||
if (_pGrid.SelectedObject is DefaultConnectionInheritance)
|
||||
{
|
||||
@@ -1633,8 +1615,7 @@ namespace mRemoteNG.UI.Window
|
||||
{
|
||||
_btnHostStatus.Image = Resources.HostStatus_Check;
|
||||
// To check status, ConnectionInfo must be an mRemoteNG.Connection.Info that is not a container
|
||||
var info = connectionInfo as ConnectionInfo;
|
||||
if (info == null) return;
|
||||
if (!(connectionInfo is ConnectionInfo info)) return;
|
||||
if (info.IsContainer) return;
|
||||
|
||||
_btnHostStatus.Tag = "checking";
|
||||
|
||||
@@ -59,10 +59,7 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
private void PlaceSearchBar(bool placeSearchBarAboveConnectionTree)
|
||||
{
|
||||
if (placeSearchBarAboveConnectionTree)
|
||||
tableLayoutPanel1.Dock = DockStyle.Top;
|
||||
else
|
||||
tableLayoutPanel1.Dock = DockStyle.Bottom;
|
||||
tableLayoutPanel1.Dock = placeSearchBarAboveConnectionTree ? DockStyle.Top : DockStyle.Bottom;
|
||||
}
|
||||
|
||||
|
||||
@@ -219,29 +216,32 @@ namespace mRemoteNG.UI.Window
|
||||
private void txtSearch_KeyDown(object sender, KeyEventArgs e)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (e.KeyCode == Keys.Escape)
|
||||
{
|
||||
e.Handled = true;
|
||||
olvConnections.Focus();
|
||||
}
|
||||
else if (e.KeyCode == Keys.Up)
|
||||
{
|
||||
var match = olvConnections.NodeSearcher.PreviousMatch();
|
||||
JumpToNode(match);
|
||||
e.Handled = true;
|
||||
}
|
||||
else if (e.KeyCode == Keys.Down)
|
||||
{
|
||||
var match = olvConnections.NodeSearcher.NextMatch();
|
||||
JumpToNode(match);
|
||||
e.Handled = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
tvConnections_KeyDown(sender, e);
|
||||
}
|
||||
}
|
||||
{
|
||||
switch (e.KeyCode)
|
||||
{
|
||||
case Keys.Escape:
|
||||
e.Handled = true;
|
||||
olvConnections.Focus();
|
||||
break;
|
||||
case Keys.Up:
|
||||
{
|
||||
var match = olvConnections.NodeSearcher.PreviousMatch();
|
||||
JumpToNode(match);
|
||||
e.Handled = true;
|
||||
break;
|
||||
}
|
||||
case Keys.Down:
|
||||
{
|
||||
var match = olvConnections.NodeSearcher.NextMatch();
|
||||
JumpToNode(match);
|
||||
e.Handled = true;
|
||||
break;
|
||||
}
|
||||
default:
|
||||
tvConnections_KeyDown(sender, e);
|
||||
break;
|
||||
}
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
Runtime.MessageCollector.AddExceptionStackTrace("txtSearch_KeyDown (UI.Window.ConnectionTreeWindow) failed", ex);
|
||||
|
||||
@@ -18,7 +18,6 @@ using mRemoteNG.UI.Forms;
|
||||
using mRemoteNG.UI.Forms.Input;
|
||||
using mRemoteNG.UI.TaskDialog;
|
||||
using WeifenLuo.WinFormsUI.Docking;
|
||||
using Message = System.Windows.Forms.Message;
|
||||
using TabControl = Crownwood.Magic.Controls.TabControl;
|
||||
using TabPage = Crownwood.Magic.Controls.TabPage;
|
||||
|
||||
@@ -177,16 +176,16 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
private new void ApplyTheme()
|
||||
{
|
||||
if(ThemeManager.getInstance().ThemingActive)
|
||||
if (!ThemeManager.getInstance().ThemingActive) return;
|
||||
base.ApplyTheme();
|
||||
vsToolStripExtender = new VisualStudioToolStripExtender(components)
|
||||
{
|
||||
base.ApplyTheme();
|
||||
this.vsToolStripExtender = new WeifenLuo.WinFormsUI.Docking.VisualStudioToolStripExtender(this.components);
|
||||
vsToolStripExtender.DefaultRenderer = _toolStripProfessionalRenderer;
|
||||
vsToolStripExtender.SetStyle(cmenTab, ThemeManager.getInstance().ActiveTheme.Version, ThemeManager.getInstance().ActiveTheme.Theme);
|
||||
TabController.BackColor = ThemeManager.getInstance().ActiveTheme.ExtendedPalette.getColor("Tab_Item_Background");
|
||||
TabController.TextColor = ThemeManager.getInstance().ActiveTheme.ExtendedPalette.getColor("Tab_Item_Foreground");
|
||||
TabController.TextInactiveColor = ThemeManager.getInstance().ActiveTheme.ExtendedPalette.getColor("Tab_Item_Disabled_Foreground");
|
||||
}
|
||||
DefaultRenderer = _toolStripProfessionalRenderer
|
||||
};
|
||||
vsToolStripExtender.SetStyle(cmenTab, ThemeManager.getInstance().ActiveTheme.Version, ThemeManager.getInstance().ActiveTheme.Theme);
|
||||
TabController.BackColor = ThemeManager.getInstance().ActiveTheme.ExtendedPalette.getColor("Tab_Item_Background");
|
||||
TabController.TextColor = ThemeManager.getInstance().ActiveTheme.ExtendedPalette.getColor("Tab_Item_Foreground");
|
||||
TabController.TextInactiveColor = ThemeManager.getInstance().ActiveTheme.ExtendedPalette.getColor("Tab_Item_Disabled_Foreground");
|
||||
}
|
||||
|
||||
private bool _documentHandlersAdded;
|
||||
@@ -421,14 +420,7 @@ namespace mRemoteNG.UI.Window
|
||||
cmenTabTransferFile.Visible = true;
|
||||
}
|
||||
|
||||
if (interfaceControl.Protocol is PuttyBase)
|
||||
{
|
||||
cmenTabPuttySettings.Visible = true;
|
||||
}
|
||||
else
|
||||
{
|
||||
cmenTabPuttySettings.Visible = false;
|
||||
}
|
||||
cmenTabPuttySettings.Visible = interfaceControl.Protocol is PuttyBase;
|
||||
|
||||
AddExternalApps();
|
||||
}
|
||||
@@ -447,8 +439,7 @@ namespace mRemoteNG.UI.Window
|
||||
if (!(TabController.SelectedTab?.Tag is InterfaceControl)) return;
|
||||
var interfaceControl = (InterfaceControl)TabController.SelectedTab?.Tag;
|
||||
|
||||
var protocol = interfaceControl.Protocol as RdpProtocol;
|
||||
if (protocol != null)
|
||||
if (interfaceControl.Protocol is RdpProtocol protocol)
|
||||
{
|
||||
var rdp = protocol;
|
||||
rdp.ToggleSmartSize();
|
||||
@@ -469,8 +460,7 @@ namespace mRemoteNG.UI.Window
|
||||
{
|
||||
try
|
||||
{
|
||||
var interfaceControl = TabController.SelectedTab?.Tag as InterfaceControl;
|
||||
if (interfaceControl == null) return;
|
||||
if (!(TabController.SelectedTab?.Tag is InterfaceControl interfaceControl)) return;
|
||||
|
||||
if (interfaceControl.Info.Protocol == ProtocolType.SSH1 | interfaceControl.Info.Protocol == ProtocolType.SSH2)
|
||||
SshTransferFile();
|
||||
@@ -523,8 +513,7 @@ namespace mRemoteNG.UI.Window
|
||||
try
|
||||
{
|
||||
var interfaceControl = TabController.SelectedTab?.Tag as InterfaceControl;
|
||||
var vnc = interfaceControl?.Protocol as ProtocolVNC;
|
||||
if (vnc == null) return;
|
||||
if (!(interfaceControl?.Protocol is ProtocolVNC vnc)) return;
|
||||
cmenTabViewOnly.Checked = !cmenTabViewOnly.Checked;
|
||||
vnc.ToggleViewOnly();
|
||||
}
|
||||
@@ -617,7 +606,7 @@ namespace mRemoteNG.UI.Window
|
||||
}
|
||||
|
||||
//add ext apps
|
||||
foreach (ExternalTool externalTool in Runtime.ExternalToolsService.ExternalTools)
|
||||
foreach (var externalTool in Runtime.ExternalToolsService.ExternalTools)
|
||||
{
|
||||
var nItem = new ToolStripMenuItem
|
||||
{
|
||||
@@ -755,8 +744,7 @@ namespace mRemoteNG.UI.Window
|
||||
{
|
||||
try
|
||||
{
|
||||
var interfaceControl = TabController.SelectedTab?.Tag as InterfaceControl;
|
||||
if (interfaceControl == null) return;
|
||||
if (!(TabController.SelectedTab?.Tag is InterfaceControl interfaceControl)) return;
|
||||
_connectionInitiator.OpenConnection(interfaceControl.Info, ConnectionInfo.Force.DoNotJump);
|
||||
_ignoreChangeSelectedTabClick = false;
|
||||
}
|
||||
@@ -770,8 +758,7 @@ namespace mRemoteNG.UI.Window
|
||||
{
|
||||
try
|
||||
{
|
||||
var interfaceControl = TabController.SelectedTab?.Tag as InterfaceControl;
|
||||
if (interfaceControl == null) return;
|
||||
if (!(TabController.SelectedTab?.Tag is InterfaceControl interfaceControl)) return;
|
||||
interfaceControl.Protocol.Close();
|
||||
_connectionInitiator.OpenConnection(interfaceControl.Info, ConnectionInfo.Force.DoNotJump);
|
||||
}
|
||||
@@ -786,9 +773,9 @@ namespace mRemoteNG.UI.Window
|
||||
try
|
||||
{
|
||||
var title = TabController.SelectedTab.Title;
|
||||
using (FrmInputBox frmInputBox = new FrmInputBox(Language.strNewTitle, Language.strNewTitle + ":", ref title))
|
||||
using (var frmInputBox = new FrmInputBox(Language.strNewTitle, Language.strNewTitle + ":", ref title))
|
||||
{
|
||||
DialogResult dr = frmInputBox.ShowDialog();
|
||||
var dr = frmInputBox.ShowDialog();
|
||||
if (dr == DialogResult.OK && !string.IsNullOrEmpty(frmInputBox.returnValue))
|
||||
TabController.SelectedTab.Title = frmInputBox.returnValue;// newTitle.Replace("&", "&&");
|
||||
}
|
||||
@@ -811,8 +798,7 @@ namespace mRemoteNG.UI.Window
|
||||
public void Prot_Event_Closed(object sender)
|
||||
{
|
||||
var protocolBase = sender as ProtocolBase;
|
||||
var tabPage = protocolBase?.InterfaceControl.Parent as TabPage;
|
||||
if (tabPage != null)
|
||||
if (protocolBase?.InterfaceControl.Parent is TabPage tabPage)
|
||||
CloseTab(tabPage);
|
||||
}
|
||||
#endregion
|
||||
|
||||
@@ -9,6 +9,7 @@ using mRemoteNG.App;
|
||||
using mRemoteNG.Messages;
|
||||
using mRemoteNG.UI.Forms;
|
||||
using mRemoteNG.Themes;
|
||||
using Message = mRemoteNG.Messages.Message;
|
||||
|
||||
namespace mRemoteNG.UI.Window
|
||||
{
|
||||
@@ -305,8 +306,7 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
foreach (ListViewItem item in items)
|
||||
{
|
||||
var message = item.Tag as Messages.Message;
|
||||
if (message == null)
|
||||
if (!(item.Tag is Message message))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
@@ -314,11 +314,10 @@ namespace mRemoteNG.UI.Window
|
||||
if (e.Column != WaitForExitColumnHeader)
|
||||
return;
|
||||
|
||||
var rowItemAsExternalTool = e.Model as ExternalTool;
|
||||
if (rowItemAsExternalTool == null || !rowItemAsExternalTool.TryIntegrate)
|
||||
if (!(e.Model is ExternalTool rowItemAsExternalTool) || !rowItemAsExternalTool.TryIntegrate)
|
||||
return;
|
||||
|
||||
e.Text = string.Format("'{0}' cannot be enabled if '{1}' is enabled", Language.strCheckboxWaitForExit, Language.strTryIntegrate);
|
||||
e.Text = $"'{Language.strCheckboxWaitForExit}' cannot be enabled if '{Language.strTryIntegrate}' is enabled";
|
||||
}
|
||||
#endregion
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@ namespace mRemoteNG.UI.Window
|
||||
#region Form Init
|
||||
|
||||
private TreeView tvIndex;
|
||||
internal ImageList imgListHelp;
|
||||
private ImageList imgListHelp;
|
||||
private System.ComponentModel.Container components;
|
||||
private SplitContainer pnlSplitter;
|
||||
private Label lblDocName;
|
||||
@@ -20,147 +20,15 @@ namespace mRemoteNG.UI.Window
|
||||
|
||||
private void InitializeComponent()
|
||||
{
|
||||
components = new System.ComponentModel.Container();
|
||||
Load += Help_Load;
|
||||
Shown += Help_Shown;
|
||||
var TreeNode1 = new TreeNode("Introduction");
|
||||
var TreeNode2 = new TreeNode("Prerequisites");
|
||||
var TreeNode3 = new TreeNode("Installation");
|
||||
var TreeNode4 = new TreeNode("Configuration");
|
||||
var TreeNode5 = new TreeNode("SQL Configuration");
|
||||
var TreeNode6 = new TreeNode("Command-Line Switches");
|
||||
var TreeNode7 = new TreeNode("Getting Started", new[] {TreeNode2, TreeNode3, TreeNode4, TreeNode5, TreeNode6});
|
||||
var TreeNode8 = new TreeNode("Main Menu");
|
||||
var TreeNode9 = new TreeNode("Connections");
|
||||
var TreeNode10 = new TreeNode("Config");
|
||||
var TreeNode11 = new TreeNode("Errors and Infos");
|
||||
var TreeNode12 = new TreeNode("Save As / Export");
|
||||
var TreeNode14 = new TreeNode("Screenshot Manager");
|
||||
var TreeNode15 = new TreeNode("Connection");
|
||||
var TreeNode16 = new TreeNode("Options");
|
||||
var TreeNode17 = new TreeNode("Update");
|
||||
var TreeNode18 = new TreeNode("SSH File Transfer");
|
||||
var TreeNode19 = new TreeNode("Quick Connect");
|
||||
var TreeNode20 = new TreeNode("Import From Active Directory");
|
||||
var TreeNode21 = new TreeNode("External Applications");
|
||||
var TreeNode22 = new TreeNode("Port Scan");
|
||||
var TreeNode23 = new TreeNode("User Interface", new[] {TreeNode8, TreeNode9, TreeNode10, TreeNode11, TreeNode12, TreeNode14, TreeNode15, TreeNode16, TreeNode17, TreeNode18, TreeNode19, TreeNode20, TreeNode21, TreeNode22});
|
||||
var TreeNode24 = new TreeNode("Quick Reference");
|
||||
var TreeNode25 = new TreeNode("Help", new[] {TreeNode1, TreeNode7, TreeNode23, TreeNode24});
|
||||
wbHelp = new WebBrowser();
|
||||
wbHelp.DocumentTitleChanged += wbHelp_DocumentTitleChanged;
|
||||
tvIndex = new TreeView();
|
||||
tvIndex.NodeMouseClick += tvIndex_NodeMouseClick;
|
||||
tvIndex.AfterSelect += tvIndex_AfterSelect;
|
||||
imgListHelp = new ImageList(components);
|
||||
pnlSplitter = new SplitContainer();
|
||||
lblDocName = new Label();
|
||||
pnlSplitter.Panel1.SuspendLayout();
|
||||
pnlSplitter.Panel2.SuspendLayout();
|
||||
pnlSplitter.SuspendLayout();
|
||||
SuspendLayout();
|
||||
//
|
||||
//wbHelp
|
||||
//
|
||||
wbHelp.Anchor = AnchorStyles.Top | AnchorStyles.Bottom
|
||||
| AnchorStyles.Left
|
||||
| AnchorStyles.Right;
|
||||
wbHelp.Location = new System.Drawing.Point(1, 36);
|
||||
wbHelp.MinimumSize = new System.Drawing.Size(20, 20);
|
||||
wbHelp.Name = "wbHelp";
|
||||
wbHelp.ScriptErrorsSuppressed = true;
|
||||
wbHelp.Size = new System.Drawing.Size(327, 286);
|
||||
wbHelp.TabIndex = 1;
|
||||
//
|
||||
//tvIndex
|
||||
//
|
||||
tvIndex.Anchor = AnchorStyles.Top | AnchorStyles.Bottom
|
||||
| AnchorStyles.Left
|
||||
| AnchorStyles.Right;
|
||||
tvIndex.BorderStyle = BorderStyle.None;
|
||||
tvIndex.HideSelection = false;
|
||||
tvIndex.Location = new System.Drawing.Point(1, 1);
|
||||
tvIndex.Name = "tvIndex";
|
||||
TreeNode1.Tag = "Introduction";
|
||||
TreeNode2.Tag = "Prerequisites";
|
||||
TreeNode3.Tag = "Installation";
|
||||
TreeNode4.Tag = "Configuration";
|
||||
TreeNode5.Tag = "ConfigurationSQL";
|
||||
TreeNode6.Tag = "CMDSwitches";
|
||||
TreeNode8.Tag = "MainMenu";
|
||||
TreeNode9.Tag = "Connections";
|
||||
TreeNode10.Tag = "Config";
|
||||
TreeNode11.Tag = "ErrorsAndInfos";
|
||||
TreeNode12.Tag = "SaveAsExport";
|
||||
TreeNode14.Tag = "ScreenshotManager";
|
||||
TreeNode15.Tag = "Connection";
|
||||
TreeNode16.Tag = "Options";
|
||||
TreeNode17.Tag = "Update";
|
||||
TreeNode18.Tag = "SSHFileTransfer";
|
||||
TreeNode19.Tag = "QuickConnect";
|
||||
TreeNode20.Tag = "ImportFromAD";
|
||||
TreeNode21.Tag = "ExternalTools";
|
||||
TreeNode22.Tag = "PortScan";
|
||||
TreeNode24.Tag = "QuickReference";
|
||||
TreeNode25.Tag = "Index";
|
||||
tvIndex.Nodes.AddRange(new[] {TreeNode25});
|
||||
tvIndex.ShowRootLines = false;
|
||||
tvIndex.Size = new System.Drawing.Size(207, 321);
|
||||
tvIndex.TabIndex = 0;
|
||||
//
|
||||
//imgListHelp
|
||||
//
|
||||
imgListHelp.ColorDepth = ColorDepth.Depth32Bit;
|
||||
imgListHelp.ImageSize = new System.Drawing.Size(16, 16);
|
||||
imgListHelp.TransparentColor = System.Drawing.Color.Transparent;
|
||||
//
|
||||
//pnlSplitter
|
||||
//
|
||||
pnlSplitter.Anchor = AnchorStyles.Top | AnchorStyles.Bottom
|
||||
| AnchorStyles.Left
|
||||
| AnchorStyles.Right;
|
||||
pnlSplitter.FixedPanel = FixedPanel.Panel1;
|
||||
pnlSplitter.Location = new System.Drawing.Point(0, 0);
|
||||
pnlSplitter.Name = "pnlSplitter";
|
||||
//
|
||||
//pnlSplitter.Panel1
|
||||
//
|
||||
pnlSplitter.Panel1.Controls.Add(tvIndex);
|
||||
//
|
||||
//pnlSplitter.Panel2
|
||||
//
|
||||
pnlSplitter.Panel2.Controls.Add(lblDocName);
|
||||
pnlSplitter.Panel2.Controls.Add(wbHelp);
|
||||
pnlSplitter.Size = new System.Drawing.Size(542, 323);
|
||||
pnlSplitter.SplitterDistance = 209;
|
||||
pnlSplitter.TabIndex = 2;
|
||||
//
|
||||
//lblDocName
|
||||
//
|
||||
lblDocName.Anchor = AnchorStyles.Top | AnchorStyles.Left
|
||||
| AnchorStyles.Right;
|
||||
lblDocName.BackColor = System.Drawing.Color.DimGray;
|
||||
lblDocName.Font = new System.Drawing.Font("Segoe UI", 12.0F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, Convert.ToByte(0));
|
||||
lblDocName.ForeColor = System.Drawing.Color.White;
|
||||
lblDocName.Location = new System.Drawing.Point(1, 1);
|
||||
lblDocName.Name = "lblDocName";
|
||||
lblDocName.Size = new System.Drawing.Size(327, 35);
|
||||
lblDocName.TabIndex = 2;
|
||||
lblDocName.Text = @"Introduction";
|
||||
lblDocName.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
|
||||
//
|
||||
//Help
|
||||
//
|
||||
ClientSize = new System.Drawing.Size(542, 323);
|
||||
Controls.Add(pnlSplitter);
|
||||
Icon = Resources.Help_Icon;
|
||||
TabText = @"Help";
|
||||
Text = @"Help";
|
||||
pnlSplitter.Panel1.ResumeLayout(false);
|
||||
pnlSplitter.Panel2.ResumeLayout(false);
|
||||
pnlSplitter.ResumeLayout(false);
|
||||
ResumeLayout(false);
|
||||
|
||||
this.SuspendLayout();
|
||||
//
|
||||
// HelpWindow
|
||||
//
|
||||
this.ClientSize = new System.Drawing.Size(284, 261);
|
||||
this.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.Name = "HelpWindow";
|
||||
this.ResumeLayout(false);
|
||||
|
||||
}
|
||||
#endregion
|
||||
|
||||
|
||||
@@ -112,15 +112,12 @@
|
||||
<value>2.0</value>
|
||||
</resheader>
|
||||
<resheader name="reader">
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<resheader name="writer">
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<metadata name="imgListHelp.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
|
||||
<value>19, 14</value>
|
||||
</metadata>
|
||||
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<metadata name="$this.TrayHeight" type="System.Int32, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
|
||||
<value>48</value>
|
||||
</metadata>
|
||||
</root>
|
||||
10
mRemoteV1/UI/Window/PortScanWindow.Designer.cs
generated
10
mRemoteV1/UI/Window/PortScanWindow.Designer.cs
generated
@@ -84,6 +84,7 @@ namespace mRemoteNG.UI.Window
|
||||
//
|
||||
// ipStart
|
||||
//
|
||||
this.ipStart.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.ipStart.Location = new System.Drawing.Point(133, 3);
|
||||
this.ipStart.Name = "ipStart";
|
||||
this.ipStart.Size = new System.Drawing.Size(124, 18);
|
||||
@@ -92,6 +93,7 @@ namespace mRemoteNG.UI.Window
|
||||
//
|
||||
// ipEnd
|
||||
//
|
||||
this.ipEnd.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.ipEnd.Location = new System.Drawing.Point(133, 27);
|
||||
this.ipEnd.Name = "ipEnd";
|
||||
this.ipEnd.Size = new System.Drawing.Size(124, 18);
|
||||
@@ -355,7 +357,7 @@ namespace mRemoteNG.UI.Window
|
||||
this.portEnd.Name = "portEnd";
|
||||
this.portEnd.Size = new System.Drawing.Size(67, 22);
|
||||
this.portEnd.TabIndex = 4;
|
||||
this.portScanToolTip.SetToolTip(this.portEnd, Language.strPortScanSinglePort);
|
||||
this.portScanToolTip.SetToolTip(this.portEnd, global::mRemoteNG.Language.strPortScanSinglePort);
|
||||
this.portEnd.Value = new decimal(new int[] {
|
||||
65535,
|
||||
0,
|
||||
@@ -375,7 +377,7 @@ namespace mRemoteNG.UI.Window
|
||||
this.portStart.Name = "portStart";
|
||||
this.portStart.Size = new System.Drawing.Size(67, 22);
|
||||
this.portStart.TabIndex = 3;
|
||||
this.portScanToolTip.SetToolTip(this.portStart, Language.strPortScanSinglePort);
|
||||
this.portScanToolTip.SetToolTip(this.portStart, global::mRemoteNG.Language.strPortScanSinglePort);
|
||||
this.portStart.Enter += new System.EventHandler(this.portStart_Enter);
|
||||
//
|
||||
// pnlIp
|
||||
@@ -432,7 +434,7 @@ namespace mRemoteNG.UI.Window
|
||||
this.ngCheckFirstPort.Size = new System.Drawing.Size(72, 17);
|
||||
this.ngCheckFirstPort.TabIndex = 17;
|
||||
this.ngCheckFirstPort.Text = "First Port";
|
||||
this.portScanToolTip.SetToolTip(this.ngCheckFirstPort, Language.strPortScanSinglePort);
|
||||
this.portScanToolTip.SetToolTip(this.ngCheckFirstPort, global::mRemoteNG.Language.strPortScanSinglePort);
|
||||
this.ngCheckFirstPort.UseVisualStyleBackColor = true;
|
||||
this.ngCheckFirstPort.CheckedChanged += new System.EventHandler(this.NgCheckFirstPort_CheckedChanged);
|
||||
//
|
||||
@@ -445,7 +447,7 @@ namespace mRemoteNG.UI.Window
|
||||
this.ngCheckLastPort.Size = new System.Drawing.Size(70, 17);
|
||||
this.ngCheckLastPort.TabIndex = 18;
|
||||
this.ngCheckLastPort.Text = "Last Port";
|
||||
this.portScanToolTip.SetToolTip(this.ngCheckLastPort, Language.strPortScanSinglePort);
|
||||
this.portScanToolTip.SetToolTip(this.ngCheckLastPort, global::mRemoteNG.Language.strPortScanSinglePort);
|
||||
this.ngCheckLastPort.UseVisualStyleBackColor = true;
|
||||
this.ngCheckLastPort.CheckedChanged += new System.EventHandler(this.NgCheckLastPort_CheckedChanged);
|
||||
//
|
||||
|
||||
@@ -23,127 +23,128 @@ namespace mRemoteNG.UI.Window
|
||||
internal SaveFileDialog dlgSaveSingleImage;
|
||||
internal FolderBrowserDialog dlgSaveAllImages;
|
||||
|
||||
internal FlowLayoutPanel flpScreenshots;
|
||||
private WeifenLuo.WinFormsUI.Docking.VisualStudioToolStripExtender vsToolStripExtender;
|
||||
private FlowLayoutPanel flpScreenshots;
|
||||
private VisualStudioToolStripExtender vsToolStripExtender;
|
||||
private readonly ToolStripRenderer _toolStripProfessionalRenderer = new ToolStripProfessionalRenderer();
|
||||
|
||||
private void InitializeComponent()
|
||||
{
|
||||
this.components = new System.ComponentModel.Container();
|
||||
this.flpScreenshots = new System.Windows.Forms.FlowLayoutPanel();
|
||||
this.msMain = new System.Windows.Forms.MenuStrip();
|
||||
this.mMenFile = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.mMenFileSaveAll = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.mMenFileRemoveAll = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.cMenScreenshot = new System.Windows.Forms.ContextMenuStrip(this.components);
|
||||
this.cMenScreenshotCopy = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.cMenScreenshotSave = new System.Windows.Forms.ToolStripMenuItem();
|
||||
this.dlgSaveSingleImage = new System.Windows.Forms.SaveFileDialog();
|
||||
this.dlgSaveAllImages = new System.Windows.Forms.FolderBrowserDialog();
|
||||
this.msMain.SuspendLayout();
|
||||
this.cMenScreenshot.SuspendLayout();
|
||||
this.SuspendLayout();
|
||||
components = new System.ComponentModel.Container();
|
||||
flpScreenshots = new FlowLayoutPanel();
|
||||
msMain = new MenuStrip();
|
||||
mMenFile = new ToolStripMenuItem();
|
||||
mMenFileSaveAll = new ToolStripMenuItem();
|
||||
mMenFileRemoveAll = new ToolStripMenuItem();
|
||||
cMenScreenshot = new ContextMenuStrip(components);
|
||||
cMenScreenshotCopy = new ToolStripMenuItem();
|
||||
cMenScreenshotSave = new ToolStripMenuItem();
|
||||
dlgSaveSingleImage = new SaveFileDialog();
|
||||
dlgSaveAllImages = new FolderBrowserDialog();
|
||||
msMain.SuspendLayout();
|
||||
cMenScreenshot.SuspendLayout();
|
||||
SuspendLayout();
|
||||
//
|
||||
// flpScreenshots
|
||||
//
|
||||
this.flpScreenshots.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)
|
||||
| System.Windows.Forms.AnchorStyles.Left)
|
||||
| System.Windows.Forms.AnchorStyles.Right)));
|
||||
this.flpScreenshots.AutoScroll = true;
|
||||
this.flpScreenshots.Location = new System.Drawing.Point(0, 26);
|
||||
this.flpScreenshots.Name = "flpScreenshots";
|
||||
this.flpScreenshots.Size = new System.Drawing.Size(542, 296);
|
||||
this.flpScreenshots.TabIndex = 0;
|
||||
flpScreenshots.Anchor = AnchorStyles.Top | AnchorStyles.Bottom
|
||||
| AnchorStyles.Left
|
||||
| AnchorStyles.Right;
|
||||
flpScreenshots.AutoScroll = true;
|
||||
flpScreenshots.Location = new Point(0, 26);
|
||||
flpScreenshots.Name = "flpScreenshots";
|
||||
flpScreenshots.Size = new Size(542, 296);
|
||||
flpScreenshots.TabIndex = 0;
|
||||
//
|
||||
// msMain
|
||||
//
|
||||
this.msMain.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.msMain.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.mMenFile});
|
||||
this.msMain.Location = new System.Drawing.Point(0, 0);
|
||||
this.msMain.Name = "msMain";
|
||||
this.msMain.RenderMode = System.Windows.Forms.ToolStripRenderMode.Professional;
|
||||
this.msMain.Size = new System.Drawing.Size(542, 24);
|
||||
this.msMain.TabIndex = 1;
|
||||
this.msMain.Text = "MenuStrip1";
|
||||
msMain.Font = new Font("Segoe UI", 8.25F, FontStyle.Regular, GraphicsUnit.Point, 0);
|
||||
msMain.Items.AddRange(new ToolStripItem[] {
|
||||
mMenFile});
|
||||
msMain.Location = new Point(0, 0);
|
||||
msMain.Name = "msMain";
|
||||
msMain.RenderMode = ToolStripRenderMode.Professional;
|
||||
msMain.Size = new Size(542, 24);
|
||||
msMain.TabIndex = 1;
|
||||
msMain.Text = "MenuStrip1";
|
||||
//
|
||||
// mMenFile
|
||||
//
|
||||
this.mMenFile.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.mMenFileSaveAll,
|
||||
this.mMenFileRemoveAll});
|
||||
this.mMenFile.Image = global::mRemoteNG.Resources.File;
|
||||
this.mMenFile.Name = "mMenFile";
|
||||
this.mMenFile.Size = new System.Drawing.Size(53, 20);
|
||||
this.mMenFile.Text = "&File";
|
||||
this.mMenFile.DropDownOpening += new System.EventHandler(this.mMenFile_DropDownOpening);
|
||||
mMenFile.DropDownItems.AddRange(new ToolStripItem[] {
|
||||
mMenFileSaveAll,
|
||||
mMenFileRemoveAll});
|
||||
mMenFile.Image = Resources.File;
|
||||
mMenFile.Name = "mMenFile";
|
||||
mMenFile.Size = new Size(53, 20);
|
||||
mMenFile.Text = "&File";
|
||||
mMenFile.DropDownOpening += mMenFile_DropDownOpening;
|
||||
//
|
||||
// mMenFileSaveAll
|
||||
//
|
||||
this.mMenFileSaveAll.Image = global::mRemoteNG.Resources.Screenshot_Save;
|
||||
this.mMenFileSaveAll.Name = "mMenFileSaveAll";
|
||||
this.mMenFileSaveAll.Size = new System.Drawing.Size(130, 22);
|
||||
this.mMenFileSaveAll.Text = "Save All";
|
||||
this.mMenFileSaveAll.Click += new System.EventHandler(this.mMenFileSaveAll_Click);
|
||||
mMenFileSaveAll.Image = Resources.Screenshot_Save;
|
||||
mMenFileSaveAll.Name = "mMenFileSaveAll";
|
||||
mMenFileSaveAll.Size = new Size(130, 22);
|
||||
mMenFileSaveAll.Text = "Save All";
|
||||
mMenFileSaveAll.Click += mMenFileSaveAll_Click;
|
||||
//
|
||||
// mMenFileRemoveAll
|
||||
//
|
||||
this.mMenFileRemoveAll.Image = global::mRemoteNG.Resources.Screenshot_Delete;
|
||||
this.mMenFileRemoveAll.Name = "mMenFileRemoveAll";
|
||||
this.mMenFileRemoveAll.Size = new System.Drawing.Size(130, 22);
|
||||
this.mMenFileRemoveAll.Text = "Remove All";
|
||||
this.mMenFileRemoveAll.Click += new System.EventHandler(this.mMenFileRemoveAll_Click);
|
||||
mMenFileRemoveAll.Image = Resources.Screenshot_Delete;
|
||||
mMenFileRemoveAll.Name = "mMenFileRemoveAll";
|
||||
mMenFileRemoveAll.Size = new Size(130, 22);
|
||||
mMenFileRemoveAll.Text = "Remove All";
|
||||
mMenFileRemoveAll.Click += mMenFileRemoveAll_Click;
|
||||
//
|
||||
// cMenScreenshot
|
||||
//
|
||||
this.cMenScreenshot.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
|
||||
this.cMenScreenshotCopy,
|
||||
this.cMenScreenshotSave});
|
||||
this.cMenScreenshot.Name = "cMenScreenshot";
|
||||
this.cMenScreenshot.Size = new System.Drawing.Size(103, 48);
|
||||
cMenScreenshot.Items.AddRange(new ToolStripItem[] {
|
||||
cMenScreenshotCopy,
|
||||
cMenScreenshotSave});
|
||||
cMenScreenshot.Name = "cMenScreenshot";
|
||||
cMenScreenshot.Size = new Size(103, 48);
|
||||
//
|
||||
// cMenScreenshotCopy
|
||||
//
|
||||
this.cMenScreenshotCopy.Image = global::mRemoteNG.Resources.Screenshot_Copy;
|
||||
this.cMenScreenshotCopy.Name = "cMenScreenshotCopy";
|
||||
this.cMenScreenshotCopy.Size = new System.Drawing.Size(102, 22);
|
||||
this.cMenScreenshotCopy.Text = "Copy";
|
||||
this.cMenScreenshotCopy.Click += new System.EventHandler(this.cMenScreenshotCopy_Click);
|
||||
cMenScreenshotCopy.Image = Resources.Screenshot_Copy;
|
||||
cMenScreenshotCopy.Name = "cMenScreenshotCopy";
|
||||
cMenScreenshotCopy.Size = new Size(102, 22);
|
||||
cMenScreenshotCopy.Text = "Copy";
|
||||
cMenScreenshotCopy.Click += cMenScreenshotCopy_Click;
|
||||
//
|
||||
// cMenScreenshotSave
|
||||
//
|
||||
this.cMenScreenshotSave.Image = global::mRemoteNG.Resources.Screenshot_Save;
|
||||
this.cMenScreenshotSave.Name = "cMenScreenshotSave";
|
||||
this.cMenScreenshotSave.Size = new System.Drawing.Size(102, 22);
|
||||
this.cMenScreenshotSave.Text = "Save";
|
||||
this.cMenScreenshotSave.Click += new System.EventHandler(this.cMenScreenshotSave_Click);
|
||||
cMenScreenshotSave.Image = Resources.Screenshot_Save;
|
||||
cMenScreenshotSave.Name = "cMenScreenshotSave";
|
||||
cMenScreenshotSave.Size = new Size(102, 22);
|
||||
cMenScreenshotSave.Text = "Save";
|
||||
cMenScreenshotSave.Click += cMenScreenshotSave_Click;
|
||||
//
|
||||
// dlgSaveSingleImage
|
||||
//
|
||||
this.dlgSaveSingleImage.Filter = "Graphics Interchange Format File (.gif)|*.gif|Joint Photographic Experts Group Fi" +
|
||||
dlgSaveSingleImage.Filter = "Graphics Interchange Format File (.gif)|*.gif|Joint Photographic Experts Group Fi" +
|
||||
"le (.jpeg)|*.jpeg|Joint Photographic Experts Group File (.jpg)|*.jpg|Portable Ne" +
|
||||
"twork Graphics File (.png)|*.png";
|
||||
this.dlgSaveSingleImage.FilterIndex = 4;
|
||||
dlgSaveSingleImage.FilterIndex = 4;
|
||||
//
|
||||
// ScreenshotManagerWindow
|
||||
//
|
||||
this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
|
||||
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi;
|
||||
this.ClientSize = new System.Drawing.Size(542, 323);
|
||||
this.Controls.Add(this.flpScreenshots);
|
||||
this.Controls.Add(this.msMain);
|
||||
this.HideOnClose = true;
|
||||
this.Icon = global::mRemoteNG.Resources.Screenshot_Icon;
|
||||
this.MainMenuStrip = this.msMain;
|
||||
this.Name = "ScreenshotManagerWindow";
|
||||
this.TabText = "Screenshots";
|
||||
this.Text = "Screenshots";
|
||||
this.Load += new System.EventHandler(this.ScreenshotManager_Load);
|
||||
this.msMain.ResumeLayout(false);
|
||||
this.msMain.PerformLayout();
|
||||
this.cMenScreenshot.ResumeLayout(false);
|
||||
this.ResumeLayout(false);
|
||||
this.PerformLayout();
|
||||
AutoScaleDimensions = new SizeF(96F, 96F);
|
||||
AutoScaleMode = AutoScaleMode.Dpi;
|
||||
ClientSize = new Size(542, 323);
|
||||
Controls.Add(flpScreenshots);
|
||||
Controls.Add(msMain);
|
||||
Font = new Font("Segoe UI", 8.25F, FontStyle.Regular, GraphicsUnit.Point, 0);
|
||||
HideOnClose = true;
|
||||
Icon = Resources.Screenshot_Icon;
|
||||
MainMenuStrip = msMain;
|
||||
Name = "ScreenshotManagerWindow";
|
||||
TabText = "Screenshots";
|
||||
Text = "Screenshots";
|
||||
Load += ScreenshotManager_Load;
|
||||
msMain.ResumeLayout(false);
|
||||
msMain.PerformLayout();
|
||||
cMenScreenshot.ResumeLayout(false);
|
||||
ResumeLayout(false);
|
||||
PerformLayout();
|
||||
|
||||
}
|
||||
#endregion
|
||||
@@ -152,19 +153,19 @@ namespace mRemoteNG.UI.Window
|
||||
private void ScreenshotManager_Load(object sender, EventArgs e)
|
||||
{
|
||||
ApplyTheme();
|
||||
Themes.ThemeManager.getInstance().ThemeChanged += ApplyTheme;
|
||||
ThemeManager.getInstance().ThemeChanged += ApplyTheme;
|
||||
ApplyLanguage();
|
||||
}
|
||||
|
||||
private new void ApplyTheme()
|
||||
{
|
||||
if (ThemeManager.getInstance().ThemingActive)
|
||||
if (!ThemeManager.getInstance().ThemingActive) return;
|
||||
base.ApplyTheme();
|
||||
vsToolStripExtender = new VisualStudioToolStripExtender(components)
|
||||
{
|
||||
base.ApplyTheme();
|
||||
this.vsToolStripExtender = new WeifenLuo.WinFormsUI.Docking.VisualStudioToolStripExtender(this.components);
|
||||
vsToolStripExtender.DefaultRenderer = _toolStripProfessionalRenderer;
|
||||
vsToolStripExtender.SetStyle(cMenScreenshot, ThemeManager.getInstance().ActiveTheme.Version, ThemeManager.getInstance().ActiveTheme.Theme);
|
||||
}
|
||||
DefaultRenderer = _toolStripProfessionalRenderer
|
||||
};
|
||||
vsToolStripExtender.SetStyle(cMenScreenshot, ThemeManager.getInstance().ActiveTheme.Version, ThemeManager.getInstance().ActiveTheme.Theme);
|
||||
}
|
||||
private void ApplyLanguage()
|
||||
{
|
||||
|
||||
@@ -59,6 +59,7 @@ namespace mRemoteNG.UI.Window
|
||||
this.ClientSize = new System.Drawing.Size(446, 362);
|
||||
this.Controls.Add(this.pnlContainer);
|
||||
this.Controls.Add(this.tsMain);
|
||||
this.Font = new System.Drawing.Font("Segoe UI", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
|
||||
this.Icon = global::mRemoteNG.Resources.UVNC_SC_Icon;
|
||||
this.Name = "UltraVNCWindow";
|
||||
this.TabText = "UltraVNC SC";
|
||||
|
||||
@@ -987,6 +987,9 @@
|
||||
<DependentUpon>ActiveDirectoryImportWindow.cs</DependentUpon>
|
||||
<SubType>Designer</SubType>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="UI\Window\BaseWindow.resx">
|
||||
<DependentUpon>BaseWindow.cs</DependentUpon>
|
||||
</EmbeddedResource>
|
||||
<EmbeddedResource Include="UI\Window\ComponentsCheckWindow.resx">
|
||||
<DependentUpon>ComponentsCheckWindow.cs</DependentUpon>
|
||||
<SubType>Designer</SubType>
|
||||
|
||||
Reference in New Issue
Block a user