Skip to content

Commit

Permalink
Add ability to disable remote-viewer kiosk mode
Browse files Browse the repository at this point in the history
  • Loading branch information
jpattWPC committed Oct 13, 2023
1 parent cd83be7 commit 9d75402
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion dist/vdiclient.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"upgrade_guid" : "46cbad92-353e-4b28-9bee-83950991dad8",
"version" : "1.2.05",
"version" : "1.2.06",
"product_name" : "VDI Client",
"manufacturer" : "Josh Patten",
"name" : "VDI Client",
Expand Down
2 changes: 2 additions & 0 deletions vdiclient.ini.example
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ logo = vdiclient.png
kiosk = False
# Enable/Disable Fullscreen mode (not applicable in Kiosk mode)
fullscreen = True
# Disable viewer_kiosk mode if kiosk is set to true, this allows overriding remote_viewer kiosk mode
#viewer_kiosk = False
# Enable displaying SPICE ini file before opening virt-viewer
inidebug = False
# Select which guest types to display. Acceptable values: both, lxc, qemu
Expand Down
5 changes: 4 additions & 1 deletion vdiclient.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ class G:
totp = False
imagefile = None
kiosk = False
viewer_kiosk = True
fullscreen = True
verify_ssl = True
icon = None
Expand Down Expand Up @@ -96,6 +97,8 @@ def loadconfig(config_location = None):
G.imagefile = config['General']['logo']
if 'kiosk' in config['General']:
G.kiosk = config['General'].getboolean('kiosk')
if 'viewer_kiosk' in config['General']:
G.viewer_kiosk = config['General'].getboolean('viewer_kiosk')
if 'fullscreen' in config['General']:
G.fullscreen = config['General'].getboolean('fullscreen')
if 'inidebug' in config['General']:
Expand Down Expand Up @@ -396,7 +399,7 @@ def vmaction(vmnode, vmid, vmtype, action='connect'):
closed = iniwin(inistring)
connpop = win_popup(f'Connecting to {vmstatus["name"]}...')
pcmd = [G.vvcmd]
if G.kiosk:
if G.kiosk and G.viewer_kiosk:
pcmd.append('--kiosk')
pcmd.append('--kiosk-quit')
pcmd.append('on-disconnect')
Expand Down

0 comments on commit 9d75402

Please sign in to comment.