PageRenderTime 40ms CodeModel.GetById 23ms RepoModel.GetById 0ms app.codeStats 0ms

/indra/newview/llfloatertopobjects.h

https://bitbucket.org/lindenlab/viewer-beta/
C Header | 105 lines | 49 code | 25 blank | 31 comment | 0 complexity | 9a7073cd083b56dd897f9e8db19e453d MD5 | raw file
Possible License(s): LGPL-2.1
  1. /**
  2. * @file llfloatertopobjects.h
  3. * @brief Shows top colliders or top scripts
  4. *
  5. * $LicenseInfo:firstyear=2005&license=viewerlgpl$
  6. * Second Life Viewer Source Code
  7. * Copyright (C) 2010, Linden Research, Inc.
  8. *
  9. * This library is free software; you can redistribute it and/or
  10. * modify it under the terms of the GNU Lesser General Public
  11. * License as published by the Free Software Foundation;
  12. * version 2.1 of the License only.
  13. *
  14. * This library is distributed in the hope that it will be useful,
  15. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  16. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  17. * Lesser General Public License for more details.
  18. *
  19. * You should have received a copy of the GNU Lesser General Public
  20. * License along with this library; if not, write to the Free Software
  21. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
  22. *
  23. * Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
  24. * $/LicenseInfo$
  25. */
  26. #ifndef LL_LLFLOATERTOPOBJECTS_H
  27. #define LL_LLFLOATERTOPOBJECTS_H
  28. #include "llfloater.h"
  29. class LLUICtrl;
  30. class LLFloaterTopObjects : public LLFloater
  31. {
  32. friend class LLFloaterReg;
  33. public:
  34. // Opens the floater on screen.
  35. // static void show();
  36. // Opens the floater if it's not on-screen.
  37. // Juggles the UI based on method = "scripts" or "colliders"
  38. static void handle_land_reply(LLMessageSystem* msg, void** data);
  39. void handleReply(LLMessageSystem* msg, void** data);
  40. void clearList();
  41. void updateSelectionInfo();
  42. virtual BOOL postBuild();
  43. void onRefresh();
  44. static void setMode(U32 mode);
  45. private:
  46. LLFloaterTopObjects(const LLSD& key);
  47. ~LLFloaterTopObjects();
  48. void initColumns(LLCtrlListInterface *list);
  49. void onCommitObjectsList();
  50. static void onDoubleClickObjectsList(void* data);
  51. void onClickShowBeacon();
  52. void doToObjects(int action, bool all);
  53. void onReturnAll();
  54. void onReturnSelected();
  55. void onDisableAll();
  56. void onDisableSelected();
  57. static bool callbackReturnAll(const LLSD& notification, const LLSD& response);
  58. static bool callbackDisableAll(const LLSD& notification, const LLSD& response);
  59. void onGetByOwnerName();
  60. void onGetByObjectName();
  61. // static void onGetByOwnerNameClicked(void* data) { onGetByOwnerName(NULL, data); };
  62. // static void onGetByObjectNameClicked(void* data) { onGetByObjectName(NULL, data); };
  63. void showBeacon();
  64. private:
  65. std::string mMethod;
  66. LLSD mObjectListData;
  67. uuid_vec_t mObjectListIDs;
  68. U32 mCurrentMode;
  69. U32 mFlags;
  70. std::string mFilter;
  71. BOOL mInitialized;
  72. F32 mtotalScore;
  73. enum
  74. {
  75. ACTION_RETURN = 0,
  76. ACTION_DISABLE
  77. };
  78. static LLFloaterTopObjects* sInstance;
  79. };
  80. #endif