PageRenderTime 41ms CodeModel.GetById 19ms RepoModel.GetById 0ms app.codeStats 0ms

/indra/newview/llpanelvolume.h

https://bitbucket.org/lindenlab/viewer-beta/
C Header | 123 lines | 58 code | 21 blank | 44 comment | 0 complexity | 7ba7b7da8342f07424fe9c83a7922c05 MD5 | raw file
Possible License(s): LGPL-2.1
  1. /**
  2. * @file llpanelvolume.h
  3. * @brief Object editing (position, scale, etc.) in the tools floater
  4. *
  5. * $LicenseInfo:firstyear=2001&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_LLPANELVOLUME_H
  27. #define LL_LLPANELVOLUME_H
  28. #include "v3math.h"
  29. #include "llpanel.h"
  30. #include "llpointer.h"
  31. #include "llvolume.h"
  32. class LLSpinCtrl;
  33. class LLCheckBoxCtrl;
  34. class LLTextBox;
  35. class LLUICtrl;
  36. class LLButton;
  37. class LLViewerObject;
  38. class LLComboBox;
  39. class LLColorSwatchCtrl;
  40. class LLPanelVolume : public LLPanel
  41. {
  42. public:
  43. LLPanelVolume();
  44. virtual ~LLPanelVolume();
  45. virtual void draw();
  46. virtual void clearCtrls();
  47. virtual BOOL postBuild();
  48. void refresh();
  49. void sendIsLight();
  50. void sendIsFlexible();
  51. static bool precommitValidate(const LLSD& data);
  52. static void onCommitIsLight( LLUICtrl* ctrl, void* userdata);
  53. static void onCommitLight( LLUICtrl* ctrl, void* userdata);
  54. static void onCommitIsFlexible( LLUICtrl* ctrl, void* userdata);
  55. static void onCommitFlexible( LLUICtrl* ctrl, void* userdata);
  56. static void onCommitPhysicsParam( LLUICtrl* ctrl, void* userdata);
  57. static void onCommitMaterial( LLUICtrl* ctrl, void* userdata);
  58. void onLightCancelColor(const LLSD& data);
  59. void onLightSelectColor(const LLSD& data);
  60. void onLightCancelTexture(const LLSD& data);
  61. void onLightSelectTexture(const LLSD& data);
  62. protected:
  63. void getState();
  64. void refreshCost();
  65. protected:
  66. void sendPhysicsShapeType(LLUICtrl* ctrl, void* userdata);
  67. void sendPhysicsGravity(LLUICtrl* ctrl, void* userdata);
  68. void sendPhysicsFriction(LLUICtrl* ctrl, void* userdata);
  69. void sendPhysicsRestitution(LLUICtrl* ctrl, void* userdata);
  70. void sendPhysicsDensity(LLUICtrl* ctrl, void* userdata);
  71. /*
  72. LLTextBox* mLabelSelectSingleMessage;
  73. // Light
  74. LLCheckBoxCtrl* mCheckLight;
  75. LLCheckBoxCtrl* mCheckFlexible1D;
  76. LLTextBox* mLabelColor;
  77. LLColorSwatchCtrl* mLightColorSwatch;
  78. LLSpinCtrl* mLightIntensity;
  79. LLSpinCtrl* mLightRadius;
  80. LLSpinCtrl* mLightFalloff;
  81. LLSpinCtrl* mLightCutoff;
  82. // Flexibile
  83. LLSpinCtrl* mSpinSections;
  84. LLSpinCtrl* mSpinGravity;
  85. LLSpinCtrl* mSpinTension;
  86. LLSpinCtrl* mSpinFriction;
  87. LLSpinCtrl* mSpinWind;
  88. LLSpinCtrl* mSpinForce[3];
  89. */
  90. S32 mComboMaterialItemCount;
  91. LLComboBox* mComboMaterial;
  92. LLColor4 mLightSavedColor;
  93. LLUUID mLightSavedTexture;
  94. LLPointer<LLViewerObject> mObject;
  95. LLPointer<LLViewerObject> mRootObject;
  96. LLComboBox* mComboPhysicsShapeType;
  97. LLSpinCtrl* mSpinPhysicsGravity;
  98. LLSpinCtrl* mSpinPhysicsFriction;
  99. LLSpinCtrl* mSpinPhysicsDensity;
  100. LLSpinCtrl* mSpinPhysicsRestitution;
  101. };
  102. #endif