Reviewed-by: Paulo Vital <pvital(a)linux.vnet.ibm.com>
On Apr 07 04:07PM, Jose Ricardo Ziviani wrote:
Signed-off-by: Jose Ricardo Ziviani
<joserz(a)linux.vnet.ibm.com>
---
ui/js/src/kimchi.template_edit_main.js | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/ui/js/src/kimchi.template_edit_main.js
b/ui/js/src/kimchi.template_edit_main.js
index eda83b2..de72452 100644
--- a/ui/js/src/kimchi.template_edit_main.js
+++ b/ui/js/src/kimchi.template_edit_main.js
@@ -65,14 +65,22 @@ kimchi.template_edit_main = function() {
$('#template-edit-memory-textbox').val(template.memory.current);
$('#template-edit-max-memory-textbox').val(template.memory.maxmemory);
- $('#template-edit-graphics').append('<option
value="vnc" selected="selected">VNC</option>');
+ if (template.graphics.type == 'vnc') {
+ $('#template-edit-graphics').append('<option
value="vnc" selected="selected">VNC</option>');
+ } else {
+ $('#template-edit-graphics').append('<option
value="vnc">VNC</option>');
+ }
var enableSpice = function() {
if (kimchi.capabilities == undefined) {
setTimeout(enableSpice, 2000);
return;
}
if (kimchi.capabilities.qemu_spice == true) {
- $('#template-edit-graphics').append('<option
value="spice">Spice</option>');
+ if (template.graphics.type == 'spice') {
+ $('#template-edit-graphics').append('<option
value="spice" selected="selected">Spice</option>');
+ } else {
+ $('#template-edit-graphics').append('<option
value="spice">Spice</option>');
+ }
}
};
var isImageBasedTemplate = function() {
--
1.9.1
_______________________________________________
Kimchi-devel mailing list
Kimchi-devel(a)ovirt.org
http://lists.ovirt.org/mailman/listinfo/kimchi-devel
--
Paulo Ricardo Paz Vital
Linux Technology Center, IBM Systems
http://www.ibm.com/linux/ltc/