diff options
Diffstat (limited to 'java/com/tigervnc/vncviewer/CConn.java')
-rw-r--r-- | java/com/tigervnc/vncviewer/CConn.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/java/com/tigervnc/vncviewer/CConn.java b/java/com/tigervnc/vncviewer/CConn.java index ec52f6e9..5ce1c2f7 100644 --- a/java/com/tigervnc/vncviewer/CConn.java +++ b/java/com/tigervnc/vncviewer/CConn.java @@ -1002,6 +1002,14 @@ public class CConn extends CConnection implements if (desktop != null) desktop.setScaledSize(); } + if (viewer.desktopSize.getValue() != null && + viewer.desktopSize.getValue().split("x").length == 2) { + options.desktopSize.setSelected(true); + String desktopWidth = viewer.desktopSize.getValue().split("x")[0]; + options.desktopWidth.setText(desktopWidth); + String desktopHeight = viewer.desktopSize.getValue().split("x")[1]; + options.desktopHeight.setText(desktopHeight); + } } public void getOptions() { @@ -1200,6 +1208,11 @@ public class CConn extends CConnection implements Security.DisableSecType(Security.secTypeX509Ident); } } + if (options.desktopSize.isSelected()) { + String desktopSize = + options.desktopWidth.getText() + "x" + options.desktopHeight.getText(); + viewer.desktopSize.setParam(desktopSize); + } if (options.fullScreen.isSelected() ^ fullScreen) toggleFullScreen(); } |