You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

ServerCore.cxx 3.5KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. /* Copyright (C) 2002-2005 RealVNC Ltd. All Rights Reserved.
  2. *
  3. * This is free software; you can redistribute it and/or modify
  4. * it under the terms of the GNU General Public License as published by
  5. * the Free Software Foundation; either version 2 of the License, or
  6. * (at your option) any later version.
  7. *
  8. * This software is distributed in the hope that it will be useful,
  9. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  11. * GNU General Public License for more details.
  12. *
  13. * You should have received a copy of the GNU General Public License
  14. * along with this software; if not, write to the Free Software
  15. * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
  16. * USA.
  17. */
  18. // -=- ServerCore.cxx
  19. // This header will define the Server interface, from which ServerMT and
  20. // ServerST will be derived.
  21. #include <string.h>
  22. #include <rfb/util.h>
  23. #include <rfb/ServerCore.h>
  24. rfb::IntParameter rfb::Server::idleTimeout
  25. ("IdleTimeout",
  26. "The number of seconds after which an idle VNC connection will be dropped "
  27. "(zero means no timeout)",
  28. 0, 0);
  29. rfb::IntParameter rfb::Server::maxDisconnectionTime
  30. ("MaxDisconnectionTime",
  31. "Terminate when no client has been connected for s seconds",
  32. 0, 0);
  33. rfb::IntParameter rfb::Server::maxConnectionTime
  34. ("MaxConnectionTime",
  35. "Terminate when a client has been connected for s seconds",
  36. 0, 0);
  37. rfb::IntParameter rfb::Server::maxIdleTime
  38. ("MaxIdleTime",
  39. "Terminate after s seconds of user inactivity",
  40. 0, 0);
  41. rfb::IntParameter rfb::Server::clientWaitTimeMillis
  42. ("ClientWaitTimeMillis",
  43. "The number of milliseconds to wait for a client which is no longer "
  44. "responding",
  45. 20000, 0);
  46. rfb::IntParameter rfb::Server::compareFB
  47. ("CompareFB",
  48. "Perform pixel comparison on framebuffer to reduce unnecessary updates "
  49. "(0: never, 1: always, 2: auto)",
  50. 2);
  51. rfb::IntParameter rfb::Server::frameRate
  52. ("FrameRate",
  53. "The maximum number of updates per second sent to each client",
  54. 60);
  55. rfb::BoolParameter rfb::Server::protocol3_3
  56. ("Protocol3.3",
  57. "Always use protocol version 3.3 for backwards compatibility with "
  58. "badly-behaved clients",
  59. false);
  60. rfb::BoolParameter rfb::Server::alwaysShared
  61. ("AlwaysShared",
  62. "Always treat incoming connections as shared, regardless of the client-"
  63. "specified setting",
  64. false);
  65. rfb::BoolParameter rfb::Server::neverShared
  66. ("NeverShared",
  67. "Never treat incoming connections as shared, regardless of the client-"
  68. "specified setting",
  69. false);
  70. rfb::BoolParameter rfb::Server::disconnectClients
  71. ("DisconnectClients",
  72. "Disconnect existing clients if an incoming connection is non-shared. "
  73. "If combined with NeverShared then new connections will be refused "
  74. "while there is a client active",
  75. true);
  76. rfb::BoolParameter rfb::Server::acceptKeyEvents
  77. ("AcceptKeyEvents",
  78. "Accept key press and release events from clients.",
  79. true);
  80. rfb::BoolParameter rfb::Server::acceptPointerEvents
  81. ("AcceptPointerEvents",
  82. "Accept pointer press and release events from clients.",
  83. true);
  84. rfb::BoolParameter rfb::Server::acceptCutText
  85. ("AcceptCutText",
  86. "Accept clipboard updates from clients.",
  87. true);
  88. rfb::BoolParameter rfb::Server::sendCutText
  89. ("SendCutText",
  90. "Send clipboard changes to clients.",
  91. true);
  92. rfb::BoolParameter rfb::Server::acceptSetDesktopSize
  93. ("AcceptSetDesktopSize",
  94. "Accept set desktop size events from clients.",
  95. true);
  96. rfb::BoolParameter rfb::Server::queryConnect
  97. ("QueryConnect",
  98. "Prompt the local user to accept or reject incoming connections.",
  99. false);