diff options
author | Pierre Ossman <ossman@cendio.se> | 2009-03-20 10:02:31 +0000 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2009-03-20 10:02:31 +0000 |
commit | e49a7bf7aa8caa6bd47feff3e581aff65ce9f6b0 (patch) | |
tree | de5ae4d3c6e6789fea99d11bdb4e0ec525ec4fb3 | |
parent | ce8088bdda24e6130c40b745cc46d4e161c57765 (diff) | |
download | tigervnc-e49a7bf7aa8caa6bd47feff3e581aff65ce9f6b0.tar.gz tigervnc-e49a7bf7aa8caa6bd47feff3e581aff65ce9f6b0.zip |
Move the SetDesktopName parser into CMsgReaderV3 to keep with the separation
of old and new features.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3696 3789f03b-4d11-0410-bbf8-ca57d06f2519
-rw-r--r-- | common/rfb/CMsgReader.cxx | 13 | ||||
-rw-r--r-- | common/rfb/CMsgReader.h | 1 | ||||
-rw-r--r-- | common/rfb/CMsgReaderV3.cxx | 14 | ||||
-rw-r--r-- | common/rfb/CMsgReaderV3.h | 3 |
4 files changed, 16 insertions, 15 deletions
diff --git a/common/rfb/CMsgReader.cxx b/common/rfb/CMsgReader.cxx index 488f549c..a78a1a03 100644 --- a/common/rfb/CMsgReader.cxx +++ b/common/rfb/CMsgReader.cxx @@ -138,19 +138,6 @@ void CMsgReader::readSetCursor(int width, int height, const Point& hotspot) handler->setCursor(width, height, hotspot, data.buf, mask.buf); } -void CMsgReader::readSetDesktopName(int x, int y, int w, int h) -{ - char* name = is->readString(); - - if (x || y || w || h) { - fprintf(stderr, "Ignoring DesktopName rect with non-zero position/size\n"); - } else { - handler->setName(name); - } - - delete [] name; -} - rdr::U8* CMsgReader::getImageBuf(int required, int requested, int* nPixels) { int requiredBytes = required * (handler->cp.pf().bpp / 8); diff --git a/common/rfb/CMsgReader.h b/common/rfb/CMsgReader.h index ebf69da1..7a611fc8 100644 --- a/common/rfb/CMsgReader.h +++ b/common/rfb/CMsgReader.h @@ -60,7 +60,6 @@ namespace rfb { virtual void readCopyRect(const Rect& r); virtual void readSetCursor(int width, int height, const Point& hotspot); - virtual void readSetDesktopName(int x, int y, int w, int h); CMsgReader(CMsgHandler* handler, rdr::InStream* is); diff --git a/common/rfb/CMsgReaderV3.cxx b/common/rfb/CMsgReaderV3.cxx index 2b5196f7..83f758e7 100644 --- a/common/rfb/CMsgReaderV3.cxx +++ b/common/rfb/CMsgReaderV3.cxx @@ -101,3 +101,17 @@ void CMsgReaderV3::readFramebufferUpdate() nUpdateRectsLeft = is->readU16(); handler->framebufferUpdateStart(); } + +void CMsgReaderV3::readSetDesktopName(int x, int y, int w, int h) +{ + char* name = is->readString(); + + if (x || y || w || h) { + fprintf(stderr, "Ignoring DesktopName rect with non-zero position/size\n"); + } else { + handler->setName(name); + } + + delete [] name; +} + diff --git a/common/rfb/CMsgReaderV3.h b/common/rfb/CMsgReaderV3.h index 689bb650..a3b604e6 100644 --- a/common/rfb/CMsgReaderV3.h +++ b/common/rfb/CMsgReaderV3.h @@ -28,7 +28,8 @@ namespace rfb { virtual void readServerInit(); virtual void readMsg(); private: - void readFramebufferUpdate(); + virtual void readFramebufferUpdate(); + virtual void readSetDesktopName(int x, int y, int w, int h); int nUpdateRectsLeft; }; } |