/indra/newview/llfloatertelehub.h

https://bitbucket.org/lindenlab/viewer-beta/ · C++ Header · 77 lines · 35 code · 16 blank · 26 comment · 0 complexity · 66e5ae9fcdd0b093bb1fbd9726f37235 MD5 · raw file

  1. /**
  2. * @file llfloatertelehub.h
  3. * @author James Cook
  4. * @brief LLFloaterTelehub class definition
  5. *
  6. * $LicenseInfo:firstyear=2005&license=viewerlgpl$
  7. * Second Life Viewer Source Code
  8. * Copyright (C) 2010, Linden Research, Inc.
  9. *
  10. * This library is free software; you can redistribute it and/or
  11. * modify it under the terms of the GNU Lesser General Public
  12. * License as published by the Free Software Foundation;
  13. * version 2.1 of the License only.
  14. *
  15. * This library is distributed in the hope that it will be useful,
  16. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  17. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  18. * Lesser General Public License for more details.
  19. *
  20. * You should have received a copy of the GNU Lesser General Public
  21. * License along with this library; if not, write to the Free Software
  22. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  23. *
  24. * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
  25. * $/LicenseInfo$
  26. */
  27. #ifndef LL_LLFLOATERTELEHUB_H
  28. #define LL_LLFLOATERTELEHUB_H
  29. #include "llfloater.h"
  30. class LLMessageSystem;
  31. class LLObjectSelection;
  32. const S32 MAX_SPAWNPOINTS_PER_TELEHUB = 16;
  33. class LLFloaterTelehub : public LLFloater
  34. {
  35. public:
  36. LLFloaterTelehub(const LLSD& key);
  37. ~LLFloaterTelehub();
  38. /*virtual*/ BOOL postBuild();
  39. /*virtual*/ void onOpen(const LLSD& key);
  40. /*virtual*/ void draw();
  41. static BOOL renderBeacons();
  42. static void addBeacons();
  43. void refresh();
  44. void sendTelehubInfoRequest();
  45. void onClickConnect();
  46. void onClickDisconnect();
  47. void onClickAddSpawnPoint();
  48. void onClickRemoveSpawnPoint();
  49. static void processTelehubInfo(LLMessageSystem* msg, void**);
  50. void unpackTelehubInfo(LLMessageSystem* msg);
  51. private:
  52. LLUUID mTelehubObjectID; // null if no telehub
  53. std::string mTelehubObjectName;
  54. LLVector3 mTelehubPos; // region local, fallback if viewer can't see the object
  55. LLQuaternion mTelehubRot;
  56. S32 mNumSpawn;
  57. LLVector3 mSpawnPointPos[MAX_SPAWNPOINTS_PER_TELEHUB];
  58. LLSafeHandle<LLObjectSelection> mObjectSelection;
  59. static LLFloaterTelehub* sInstance;
  60. };
  61. #endif