From 86f3232024329e1726b216c857b9667e79fa2913 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20S=2E=20Montero?= Date: Mon, 13 Jul 2009 11:31:48 +0000 Subject: [PATCH] Added Keymap to GRAPHICS Libvirt and Xen drivers git-svn-id: http://svn.opennebula.org/one/trunk@675 3034c82b-c49b-4eb3-8279-a7acafdc01c0 --- src/vmm/LibVirtDriver.cc | 7 +++++++ src/vmm/XenDriver.cc | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/src/vmm/LibVirtDriver.cc b/src/vmm/LibVirtDriver.cc index 630fd1d50d..5e5b87cab1 100644 --- a/src/vmm/LibVirtDriver.cc +++ b/src/vmm/LibVirtDriver.cc @@ -65,6 +65,7 @@ int LibVirtDriver::deployment_description( string listen = ""; string port = ""; string passwd = ""; + string keymap = ""; const VectorAttribute * input; @@ -420,6 +421,7 @@ int LibVirtDriver::deployment_description( listen = graphics->vector_value("LISTEN"); port = graphics->vector_value("PORT"); passwd = graphics->vector_value("PASSWD"); + keymap = graphics->vector_value("KEYMAP"); if ( type == "vnc" || type == "VNC" ) { @@ -440,6 +442,11 @@ int LibVirtDriver::deployment_description( file << " password='" << passwd << "'"; } + if ( !keymap.empty() ) + { + file << " keymap='" << keymap << "'"; + } + file << "/>" << endl; } else diff --git a/src/vmm/XenDriver.cc b/src/vmm/XenDriver.cc index 966147e0aa..465422bcda 100644 --- a/src/vmm/XenDriver.cc +++ b/src/vmm/XenDriver.cc @@ -62,6 +62,7 @@ int XenDriver::deployment_description( string listen = ""; string port = ""; string passwd = ""; + string keymap = ""; const VectorAttribute * raw; string data; @@ -343,6 +344,7 @@ int XenDriver::deployment_description( listen = graphics->vector_value("LISTEN"); port = graphics->vector_value("PORT"); passwd = graphics->vector_value("PASSWD"); + keymap = graphics->vector_value("KEYMAP"); if ( type == "vnc" || type == "VNC" ) { @@ -363,6 +365,11 @@ int XenDriver::deployment_description( file << ",vncpasswd=" << passwd; } + if ( !keymap.empty() ) + { + file << ",keymap=" << keymap ; + } + file <<"']" << endl; } else