CP-36392: Refactor setter so that it actually refers to the field 'sendScanCodes'

Removed private method is only referenced within the public setter

Signed-off-by: Danilo Del Busso <Danilo.Del.Busso@citrix.com>
This commit is contained in:
Danilo Del Busso 2021-09-09 10:24:39 +01:00
parent 44c9416745
commit 6aedaa7742
No known key found for this signature in database
GPG Key ID: 55F556F9A25CB037

View File

@ -1384,30 +1384,24 @@ namespace XenAdmin.ConsoleView
set
{
Program.AssertOnEventThread();
SetSendScanCodes(value);
if (sendScanCodes == value)
return;
Log.InfoFormat("VNCGraphicsClient.SetSendScanCodes newSendScanCodes={0}", value);
if (!value)
{
InterceptKeys.releaseKeys();
}
else if (Focused)
{
InterceptKeys.grabKeys(this.keyScan, false);
}
sendScanCodes = value;
}
}
private void SetSendScanCodes(bool newSendScanCodes)
{
Program.AssertOnEventThread();
if (sendScanCodes == newSendScanCodes)
return;
Log.InfoFormat("VNCGraphicsClient.SetSendScanCodes newSendScanCodes={0}", newSendScanCodes);
if (!newSendScanCodes)
{
InterceptKeys.releaseKeys();
}
else if (Focused)
{
InterceptKeys.grabKeys(this.keyScan, false);
}
sendScanCodes = newSendScanCodes;
}
public bool Scaling
{
get