ui: vm-options: add spice enhancements
Signed-off-by: Aaron Lauterer <a.lauterer@proxmox.com>
This commit is contained in:
parent
c1025d7e31
commit
86b95e11cc
@ -334,6 +334,24 @@ Ext.define('PVE.Utils', { utilities: {
|
||||
}
|
||||
},
|
||||
|
||||
render_spice_enhancements: function(values) {
|
||||
let disabled = Proxmox.Utils.disabledText;
|
||||
|
||||
let props = PVE.Parser.parsePropertyString(values);
|
||||
if (Ext.Object.isEmpty(props)) {
|
||||
return disabled;
|
||||
}
|
||||
|
||||
let output = [];
|
||||
if (PVE.Parser.parseBoolean(props.foldersharing)) {
|
||||
output.push('Folder Sharing: ' + gettext('Enabled'));
|
||||
}
|
||||
if (props.videostreaming === 'all' || props.videostreaming === 'filter') {
|
||||
output.push('Video Streaming: ' + props.videostreaming);
|
||||
}
|
||||
return output.join(', ');
|
||||
},
|
||||
|
||||
// fixme: auto-generate this
|
||||
// for now, please keep in sync with PVE::Tools::kvmkeymaps
|
||||
kvm_keymaps: {
|
||||
|
@ -281,6 +281,20 @@ Ext.define('PVE.qemu.Options', {
|
||||
}
|
||||
} : undefined
|
||||
},
|
||||
spice_enhancements: {
|
||||
header: gettext('Spice Enhancements'),
|
||||
defaultValue: false,
|
||||
renderer: PVE.Utils.render_spice_enhancements,
|
||||
editor: caps.vms['VM.Config.Options'] ? {
|
||||
xtype: 'proxmoxWindowEdit',
|
||||
subject: gettext('Spice Enhancements'),
|
||||
onlineHelp: 'qm_spice_enhancements',
|
||||
items: {
|
||||
xtype: 'pveSpiceEnhancementSelector',
|
||||
name: 'spice_enhancements',
|
||||
}
|
||||
} : undefined
|
||||
},
|
||||
hookscript: {
|
||||
header: gettext('Hookscript')
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user