From 0c049cf3cb2adde76abe46f8cde692b841cf95e7 Mon Sep 17 00:00:00 2001 From: Jonathan Bauer Date: Thu, 16 Jan 2020 13:25:45 +0100 Subject: [run-virt/vbox-src] initial multi-monitor support --- .../openslx/vmchooser/run-virt.d/setup_virtual_floppy.inc | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'core/modules/run-virt/data/opt/openslx/vmchooser/run-virt.d/setup_virtual_floppy.inc') diff --git a/core/modules/run-virt/data/opt/openslx/vmchooser/run-virt.d/setup_virtual_floppy.inc b/core/modules/run-virt/data/opt/openslx/vmchooser/run-virt.d/setup_virtual_floppy.inc index c077bb42..f589d2b6 100644 --- a/core/modules/run-virt/data/opt/openslx/vmchooser/run-virt.d/setup_virtual_floppy.inc +++ b/core/modules/run-virt/data/opt/openslx/vmchooser/run-virt.d/setup_virtual_floppy.inc @@ -112,10 +112,17 @@ setup_virtual_floppy() { ${RESOLUTION} EOF - cat > "${FLOPPYDIR}/openslx.ini" <<-EOF - [openslx] + ( + echo '[openslx]' + # Ugly hack for multi-monitor support with virtualbox. + # The guest additions properly set up the resolutions of multiple + # monitor, thus we need to disable the resolution feature of + # the openslx.exe as it would break what virtualbox did. + if [ "$PLUGIN_ID" = "vmware" ] || [ "$PLUGIN_ID" = "virtualbox" -a "$DISPLAY_COUNT" -eq 1 ]; then + echo "resolution=$RESOLUTION" + fi + cat <<-EOF username=${UNAME} - resolution=${RESOLUTION} createMissingRemap=${SHARE_CREATE_MISSING_REMAP} remapMode=${SHARE_REMAP_MODE_INI} homeDrive=${SHARE_HOME_DRIVE} @@ -133,7 +140,7 @@ setup_virtual_floppy() { media=${SHARE_MEDIA} other=${SHARE_OTHER} EOF - + ) > "${FLOPPYDIR}/openslx.ini" ln -n -s "${VMCHOOSER_DIR}/data/openslx.exe" "${FLOPPYDIR}/openslx.exe" # If we have a kerberos ticket, copy that one too (TODO: Copy keytab too?) if [ -n "$KRB5CCNAME" ]; then -- cgit v1.2.3-55-g7522