Added the autoScaling mode implementation to the vncviewer.

git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@645 3789f03b-4d11-0410-bbf8-ca57d06f2519
diff --git a/win/vncviewer/CConn.cxx b/win/vncviewer/CConn.cxx
index 9f597ed..2fb8d2d 100644
--- a/win/vncviewer/CConn.cxx
+++ b/win/vncviewer/CConn.cxx
@@ -150,7 +150,12 @@
     window->setMenuKey(options.menuKey);
     window->setDisableWinKeys(options.disableWinKeys);
     window->setShowToolbar(options.showToolbar);
-    window->setDesktopScale(options.scale);
+    if (options.autoScaling) {
+      window->setAutoScaling(true);
+    } else {
+      window->setAutoScaling(false);
+      window->setDesktopScale(options.scale);
+    }
     if (!options.useLocalCursor)
       window->setCursor(0, 0, Point(), 0, 0);
   }
@@ -611,9 +616,9 @@
 
   // Show the window
   window = new DesktopWindow(this);
-  applyOptions(options);
   window->setName(cp.name());
   window->setSize(cp.width, cp.height);
+  applyOptions(options);
 
   // Save the server's current format
   serverDefaultPF = cp.pf();