Du kannst nicht mehr als 25 Themen auswählen Themen müssen mit entweder einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

CMsgHandler.cxx 2.0KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. /* Copyright (C) 2002-2005 RealVNC Ltd. All Rights Reserved.
  2. * Copyright 2009-2011 Pierre Ossman for Cendio AB
  3. *
  4. * This is free software; you can redistribute it and/or modify
  5. * it under the terms of the GNU General Public License as published by
  6. * the Free Software Foundation; either version 2 of the License, or
  7. * (at your option) any later version.
  8. *
  9. * This software is distributed in the hope that it will be useful,
  10. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  11. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  12. * GNU General Public License for more details.
  13. *
  14. * You should have received a copy of the GNU General Public License
  15. * along with this software; if not, write to the Free Software
  16. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
  17. * USA.
  18. */
  19. #include <stdio.h>
  20. #include <rfb/Exception.h>
  21. #include <rfb/CMsgHandler.h>
  22. #include <rfb/screenTypes.h>
  23. using namespace rfb;
  24. CMsgHandler::CMsgHandler()
  25. {
  26. }
  27. CMsgHandler::~CMsgHandler()
  28. {
  29. }
  30. void CMsgHandler::setDesktopSize(int width, int height)
  31. {
  32. cp.width = width;
  33. cp.height = height;
  34. }
  35. void CMsgHandler::setExtendedDesktopSize(unsigned reason, unsigned result,
  36. int width, int height,
  37. const ScreenSet& layout)
  38. {
  39. cp.supportsSetDesktopSize = true;
  40. if ((reason == reasonClient) && (result != resultSuccess))
  41. return;
  42. if (!layout.validate(width, height))
  43. fprintf(stderr, "Server sent us an invalid screen layout\n");
  44. cp.width = width;
  45. cp.height = height;
  46. cp.screenLayout = layout;
  47. }
  48. void CMsgHandler::setPixelFormat(const PixelFormat& pf)
  49. {
  50. cp.setPF(pf);
  51. }
  52. void CMsgHandler::setName(const char* name)
  53. {
  54. cp.setName(name);
  55. }
  56. void CMsgHandler::fence(rdr::U32 flags, unsigned len, const char data[])
  57. {
  58. cp.supportsFence = true;
  59. }
  60. void CMsgHandler::endOfContinuousUpdates()
  61. {
  62. cp.supportsContinuousUpdates = true;
  63. }
  64. void CMsgHandler::framebufferUpdateStart()
  65. {
  66. }
  67. void CMsgHandler::framebufferUpdateEnd()
  68. {
  69. }