diff --git a/Source/NETworkManager.Localization/Resources/Strings.Designer.cs b/Source/NETworkManager.Localization/Resources/Strings.Designer.cs
index a6e70ad0e0..9ddb2ab8bf 100644
--- a/Source/NETworkManager.Localization/Resources/Strings.Designer.cs
+++ b/Source/NETworkManager.Localization/Resources/Strings.Designer.cs
@@ -12279,7 +12279,25 @@ public static string VisualStyles {
return ResourceManager.GetString("VisualStyles", resourceCulture);
}
}
-
+
+ ///
+ /// Looks up a localized string similar to View only.
+ ///
+ public static string ViewOnly {
+ get {
+ return ResourceManager.GetString("ViewOnly", resourceCulture);
+ }
+ }
+
+ ///
+ /// Looks up a localized string similar to Block keyboard and mouse input to the remote session.
+ ///
+ public static string ViewOnlyDescription {
+ get {
+ return ResourceManager.GetString("ViewOnlyDescription", resourceCulture);
+ }
+ }
+
///
/// Looks up a localized string similar to VLAN.
///
diff --git a/Source/NETworkManager.Localization/Resources/Strings.resx b/Source/NETworkManager.Localization/Resources/Strings.resx
index 28fe9f6281..5f30429e61 100644
--- a/Source/NETworkManager.Localization/Resources/Strings.resx
+++ b/Source/NETworkManager.Localization/Resources/Strings.resx
@@ -2142,6 +2142,12 @@ is disabled!
Visual styles
+
+ View only
+
+
+ Block keyboard and mouse input to the remote session
+
Remote audio
diff --git a/Source/NETworkManager.Models/RemoteDesktop/RemoteDesktopSessionInfo.cs b/Source/NETworkManager.Models/RemoteDesktop/RemoteDesktopSessionInfo.cs
index 106a19b7be..965a5abfa7 100644
--- a/Source/NETworkManager.Models/RemoteDesktop/RemoteDesktopSessionInfo.cs
+++ b/Source/NETworkManager.Models/RemoteDesktop/RemoteDesktopSessionInfo.cs
@@ -16,6 +16,10 @@ public class RemoteDesktopSessionInfo
public int DesktopWidth { get; set; }
public int DesktopHeight { get; set; }
public int ColorDepth { get; set; }
+
+ // View only (block keyboard and mouse input to the remote session)
+ public bool ViewOnly { get; set; }
+
public bool EnableCredSspSupport { get; set; }
public uint AuthenticationLevel { get; set; }
public bool EnableGatewayServer { get; set; }
diff --git a/Source/NETworkManager.Profiles/Application/RemoteDesktop.cs b/Source/NETworkManager.Profiles/Application/RemoteDesktop.cs
index c8240d2a3f..304dfdd75f 100644
--- a/Source/NETworkManager.Profiles/Application/RemoteDesktop.cs
+++ b/Source/NETworkManager.Profiles/Application/RemoteDesktop.cs
@@ -26,6 +26,9 @@ public static RemoteDesktopSessionInfo CreateSessionInfo()
: SettingsManager.Current.RemoteDesktop_ScreenHeight,
ColorDepth = SettingsManager.Current.RemoteDesktop_ColorDepth,
+ // View only
+ ViewOnly = SettingsManager.Current.RemoteDesktop_ViewOnly,
+
// Authentication
EnableCredSspSupport = SettingsManager.Current.RemoteDesktop_EnableCredSspSupport,
AuthenticationLevel = SettingsManager.Current.RemoteDesktop_AuthenticationLevel,
@@ -128,6 +131,12 @@ public static RemoteDesktopSessionInfo CreateSessionInfo(ProfileInfo profile)
info.ColorDepth = group.RemoteDesktop_ColorDepth;
}
+ // View only
+ if (profile.RemoteDesktop_OverrideViewOnly)
+ info.ViewOnly = profile.RemoteDesktop_ViewOnly;
+ else if (group.RemoteDesktop_OverrideViewOnly)
+ info.ViewOnly = group.RemoteDesktop_ViewOnly;
+
// Authentication
if (profile.RemoteDesktop_OverrideCredSspSupport)
info.EnableCredSspSupport = profile.RemoteDesktop_EnableCredSspSupport;
diff --git a/Source/NETworkManager.Profiles/GroupInfo.cs b/Source/NETworkManager.Profiles/GroupInfo.cs
index 2598a48d05..4842bcccc2 100644
--- a/Source/NETworkManager.Profiles/GroupInfo.cs
+++ b/Source/NETworkManager.Profiles/GroupInfo.cs
@@ -60,6 +60,8 @@ public GroupInfo(GroupInfo group) : this(group.Name)
RemoteDesktop_ColorDepth = group.RemoteDesktop_ColorDepth;
RemoteDesktop_OverridePort = group.RemoteDesktop_OverridePort;
RemoteDesktop_Port = group.RemoteDesktop_Port;
+ RemoteDesktop_OverrideViewOnly = group.RemoteDesktop_OverrideViewOnly;
+ RemoteDesktop_ViewOnly = group.RemoteDesktop_ViewOnly;
RemoteDesktop_OverrideCredSspSupport = group.RemoteDesktop_OverrideCredSspSupport;
RemoteDesktop_EnableCredSspSupport = group.RemoteDesktop_EnableCredSspSupport;
RemoteDesktop_OverrideAuthenticationLevel = group.RemoteDesktop_OverrideAuthenticationLevel;
@@ -196,6 +198,8 @@ public GroupInfo(GroupInfo group) : this(group.Name)
public int RemoteDesktop_ColorDepth { get; set; } = GlobalStaticConfiguration.RemoteDesktop_ColorDepth;
public bool RemoteDesktop_OverridePort { get; set; }
public int RemoteDesktop_Port { get; set; } = GlobalStaticConfiguration.RemoteDesktop_Port;
+ public bool RemoteDesktop_OverrideViewOnly { get; set; }
+ public bool RemoteDesktop_ViewOnly { get; set; } = GlobalStaticConfiguration.RemoteDesktop_ViewOnly;
public bool RemoteDesktop_OverrideCredSspSupport { get; set; }
public bool RemoteDesktop_EnableCredSspSupport { get; set; }
public bool RemoteDesktop_OverrideAuthenticationLevel { get; set; }
diff --git a/Source/NETworkManager.Profiles/ProfileInfo.cs b/Source/NETworkManager.Profiles/ProfileInfo.cs
index 877d9c472f..3b36201016 100644
--- a/Source/NETworkManager.Profiles/ProfileInfo.cs
+++ b/Source/NETworkManager.Profiles/ProfileInfo.cs
@@ -100,6 +100,8 @@ public ProfileInfo(ProfileInfo profile)
RemoteDesktop_ColorDepth = profile.RemoteDesktop_ColorDepth;
RemoteDesktop_OverridePort = profile.RemoteDesktop_OverridePort;
RemoteDesktop_Port = profile.RemoteDesktop_Port;
+ RemoteDesktop_OverrideViewOnly = profile.RemoteDesktop_OverrideViewOnly;
+ RemoteDesktop_ViewOnly = profile.RemoteDesktop_ViewOnly;
RemoteDesktop_OverrideCredSspSupport = profile.RemoteDesktop_OverrideCredSspSupport;
RemoteDesktop_EnableCredSspSupport = profile.RemoteDesktop_EnableCredSspSupport;
RemoteDesktop_OverrideAuthenticationLevel = profile.RemoteDesktop_OverrideAuthenticationLevel;
@@ -345,6 +347,8 @@ public ProfileInfo(ProfileInfo profile)
public int RemoteDesktop_ColorDepth { get; set; } = GlobalStaticConfiguration.RemoteDesktop_ColorDepth;
public bool RemoteDesktop_OverridePort { get; set; }
public int RemoteDesktop_Port { get; set; } = GlobalStaticConfiguration.RemoteDesktop_Port;
+ public bool RemoteDesktop_OverrideViewOnly { get; set; }
+ public bool RemoteDesktop_ViewOnly { get; set; } = GlobalStaticConfiguration.RemoteDesktop_ViewOnly;
public bool RemoteDesktop_OverrideCredSspSupport { get; set; }
public bool RemoteDesktop_EnableCredSspSupport { get; set; }
public bool RemoteDesktop_OverrideAuthenticationLevel { get; set; }
diff --git a/Source/NETworkManager.Settings/GlobalStaticConfiguration.cs b/Source/NETworkManager.Settings/GlobalStaticConfiguration.cs
index ee66caad44..2d4c40b93f 100644
--- a/Source/NETworkManager.Settings/GlobalStaticConfiguration.cs
+++ b/Source/NETworkManager.Settings/GlobalStaticConfiguration.cs
@@ -182,6 +182,7 @@ public static class GlobalStaticConfiguration
public static int RemoteDesktop_ColorDepth => 32;
public static int RemoteDesktop_Port => 3389;
+ public static bool RemoteDesktop_ViewOnly => false;
public static bool RemoteDesktop_GatewayServerBypassLocalAddresses => true;
public static GatewayUserSelectedCredsSource RemoteDesktop_GatewayServerLogonMethod =>
diff --git a/Source/NETworkManager.Settings/SettingsInfo.cs b/Source/NETworkManager.Settings/SettingsInfo.cs
index 1a739e5724..dac5457ea4 100644
--- a/Source/NETworkManager.Settings/SettingsInfo.cs
+++ b/Source/NETworkManager.Settings/SettingsInfo.cs
@@ -2175,6 +2175,19 @@ public int RemoteDesktop_Port
}
} = GlobalStaticConfiguration.RemoteDesktop_Port;
+ public bool RemoteDesktop_ViewOnly
+ {
+ get;
+ set
+ {
+ if (value == field)
+ return;
+
+ field = value;
+ OnPropertyChanged();
+ }
+ } = GlobalStaticConfiguration.RemoteDesktop_ViewOnly;
+
public bool RemoteDesktop_EnableCredSspSupport
{
get;
diff --git a/Source/NETworkManager/Controls/DragablzTabHostWindow.xaml b/Source/NETworkManager/Controls/DragablzTabHostWindow.xaml
index a60f681974..784a51eae7 100644
--- a/Source/NETworkManager/Controls/DragablzTabHostWindow.xaml
+++ b/Source/NETworkManager/Controls/DragablzTabHostWindow.xaml
@@ -8,6 +8,7 @@
xmlns:dockablz="clr-namespace:Dragablz.Dockablz;assembly=Dragablz"
xmlns:localization="clr-namespace:NETworkManager.Localization.Resources;assembly=NETworkManager.Localization"
xmlns:controls="clr-namespace:NETworkManager.Controls"
+ xmlns:converters="clr-namespace:NETworkManager.Converters;assembly=NETworkManager.Converters"
xmlns:application="clr-namespace:NETworkManager.Models;assembly=NETworkManager.Models"
xmlns:iconPacks="http://metro.mahapps.com/winfx/xaml/iconpacks"
xmlns:wpfHelpers="clr-namespace:NETworkManager.Utilities.WPF;assembly=NETworkManager.Utilities.WPF"
@@ -18,6 +19,8 @@
d:DataContext="{d:DesignInstance controls:DragablzTabHostWindow}">
+
+
@@ -53,7 +56,8 @@
@@ -148,6 +178,15 @@
+
+
+
+
+