Encapsulate screen layout storage in ConnParams

Avoid direct access to the screen dimensions and layout so that we
can make sure it stays sane. This also makes sure the layout is
properly updated when we only get the screen dimensions from the
server.
diff --git a/common/rfb/SMsgWriter.cxx b/common/rfb/SMsgWriter.cxx
index 3da9413..96df653 100644
--- a/common/rfb/SMsgWriter.cxx
+++ b/common/rfb/SMsgWriter.cxx
@@ -49,8 +49,8 @@
 
 void SMsgWriter::writeServerInit()
 {
-  os->writeU16(cp->width);
-  os->writeU16(cp->height);
+  os->writeU16(cp->width());
+  os->writeU16(cp->height());
   cp->pf().write(os);
   os->writeString(cp->name());
   endMsg();
@@ -422,15 +422,15 @@
 
   // Send this before SetDesktopSize to make life easier on the clients
   if (needExtendedDesktopSize) {
-    writeExtendedDesktopSizeRect(0, 0, cp->width, cp->height,
-                                 cp->screenLayout);
+    writeExtendedDesktopSizeRect(0, 0, cp->width(), cp->height(),
+                                 cp->screenLayout());
     needExtendedDesktopSize = false;
   }
 
   // Some clients assume this is the last rectangle so don't send anything
   // more after this
   if (needSetDesktopSize) {
-    writeSetDesktopSizeRect(cp->width, cp->height);
+    writeSetDesktopSizeRect(cp->width(), cp->height());
     needSetDesktopSize = false;
   }
 }