Stop requiring CConnection::serverInit() to be overridden
Add an explicit callback for subclasses to do their startup in. This
makes it easier to do proper ordering, and avoids mistakes.
diff --git a/vncviewer/CConn.cxx b/vncviewer/CConn.cxx
index fe8e6cf..23257ee 100644
--- a/vncviewer/CConn.cxx
+++ b/vncviewer/CConn.cxx
@@ -308,13 +308,11 @@
////////////////////// CConnection callback methods //////////////////////
-// serverInit() is called when the serverInit message has been received. At
+// initDone() is called when the serverInit message has been received. At
// this point we create the desktop window and display it. We also tell the
// server the pixel format and encodings to use and request the first update.
-void CConn::serverInit()
+void CConn::initDone()
{
- CConnection::serverInit();
-
// If using AutoSelect with old servers, start in FullColor
// mode. See comment in autoSelectFormatAndEncoding.
if (server.beforeVersion(3, 8) && autoSelect)
diff --git a/vncviewer/CConn.h b/vncviewer/CConn.h
index 5988a94..66ef1d0 100644
--- a/vncviewer/CConn.h
+++ b/vncviewer/CConn.h
@@ -51,7 +51,7 @@
static void socketEvent(FL_SOCKET fd, void *data);
// CConnection callback methods
- void serverInit();
+ void initDone();
void setDesktopSize(int w, int h);
void setExtendedDesktopSize(unsigned reason, unsigned result,