mirror of
https://github.com/xcp-ng/xenadmin.git
synced 2025-01-20 15:29:26 +01:00
CP-21130: Move the test for InvernessOrGreater outside the VNCGraphicsClient class
- This is needed because this class is shared with the VNCControl solution which doesn't have access to the Helpers class Signed-off-by: Mihaela Stoica <mihaela.stoica@citrix.com>
This commit is contained in:
parent
30b83bc0b1
commit
4bf86842ba
@ -156,6 +156,8 @@ namespace XenAdmin.ConsoleView
|
||||
|
||||
public event EventHandler DesktopResized = null;
|
||||
|
||||
public bool UseQemuExtKeyEncoding { set; private get; }
|
||||
|
||||
public VNCGraphicsClient(ContainerControl parent)
|
||||
{
|
||||
Program.AssertOnEventThread();
|
||||
@ -964,7 +966,7 @@ namespace XenAdmin.ConsoleView
|
||||
|
||||
foreach (int key in pressedScans)
|
||||
{
|
||||
this.vncStream.keyScanEvent(false, key, -1, Helpers.InvernessOrGreater(this.SourceVM.Connection));
|
||||
this.vncStream.keyScanEvent(false, key, -1, UseQemuExtKeyEncoding);
|
||||
}
|
||||
});
|
||||
|
||||
@ -1312,7 +1314,7 @@ namespace XenAdmin.ConsoleView
|
||||
{
|
||||
DoIfConnected(delegate()
|
||||
{
|
||||
this.vncStream.keyScanEvent(pressed, scanCode, keySym, Helpers.InvernessOrGreater(this.SourceVM.Connection));
|
||||
this.vncStream.keyScanEvent(pressed, scanCode, keySym, UseQemuExtKeyEncoding);
|
||||
});
|
||||
}
|
||||
|
||||
|
@ -1117,6 +1117,7 @@ namespace XenAdmin.ConsoleView
|
||||
v.SendScanCodes = UseSource && !this.sourceIsPV;
|
||||
v.SourceVM = sourceVM;
|
||||
v.Console = console;
|
||||
v.UseQemuExtKeyEncoding = sourceVM != null && Helpers.InvernessOrGreater(sourceVM.Connection);
|
||||
v.connect(stream, this.vncPassword);
|
||||
}
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user