Torque3D Documentation / _generateds / datablockField.h

datablockField.h

Engine/source/gui/editor/inspector/datablockField.h

More...

Classes:

Detailed Description

  1
  2//-----------------------------------------------------------------------------
  3// Copyright (c) 2012 GarageGames, LLC
  4//
  5// Permission is hereby granted, free of charge, to any person obtaining a copy
  6// of this software and associated documentation files (the "Software"), to
  7// deal in the Software without restriction, including without limitation the
  8// rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
  9// sell copies of the Software, and to permit persons to whom the Software is
 10// furnished to do so, subject to the following conditions:
 11//
 12// The above copyright notice and this permission notice shall be included in
 13// all copies or substantial portions of the Software.
 14//
 15// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
 16// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
 17// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
 18// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
 19// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
 20// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
 21// IN THE SOFTWARE.
 22//-----------------------------------------------------------------------------
 23
 24#ifndef _GUI_INSPECTOR_DATABLOCKFIELD_H_
 25#define _GUI_INSPECTOR_DATABLOCKFIELD_H_
 26
 27#include "gui/editor/guiInspectorTypes.h"
 28
 29
 30//-----------------------------------------------------------------------------
 31// GuiInspectorDatablockField - custom field type for datablock enumeration
 32//-----------------------------------------------------------------------------
 33class GuiInspectorDatablockField : public GuiInspectorTypeMenuBase
 34{
 35   public:
 36      
 37      typedef GuiInspectorTypeMenuBase Parent;
 38      
 39   protected:
 40
 41      AbstractClassRep *mDesiredClass;
 42
 43      virtual SimSet* _getDatablockSet() const { return Sim::getDataBlockGroup(); }
 44      virtual void _populateMenu( GuiPopUpMenuCtrl* menu );
 45      
 46   public:
 47      
 48      DECLARE_CONOBJECT(GuiInspectorDatablockField);
 49      
 50      GuiInspectorDatablockField( StringTableEntry className );
 51      GuiInspectorDatablockField() { mDesiredClass = NULL; };
 52
 53      void setClassName( StringTableEntry className );
 54};
 55
 56//-----------------------------------------------------------------------------
 57// TypeSFXDescriptionName GuiInspectorField Class
 58//-----------------------------------------------------------------------------
 59class GuiInspectorTypeSFXDescriptionName : public GuiInspectorDatablockField
 60{
 61   public:
 62   
 63      typedef GuiInspectorDatablockField Parent;
 64      
 65   protected:
 66   
 67      virtual SimSet* _getDatablockSet() const { return Sim::getSFXDescriptionSet(); }
 68   
 69   public:
 70      
 71      DECLARE_CONOBJECT(GuiInspectorTypeSFXDescriptionName);
 72      static void consoleInit();
 73};
 74
 75
 76//-----------------------------------------------------------------------------
 77// TypeSFXTrackName GuiInspectorField Class
 78//-----------------------------------------------------------------------------
 79class GuiInspectorTypeSFXTrackName : public GuiInspectorDatablockField
 80{
 81   public:
 82   
 83      typedef GuiInspectorDatablockField Parent;
 84      
 85   protected:
 86   
 87      virtual SimSet* _getDatablockSet() const { return Sim::getSFXTrackSet(); }
 88      
 89   public:
 90
 91      DECLARE_CONOBJECT(GuiInspectorTypeSFXTrackName);
 92      static void consoleInit();
 93};
 94
 95
 96//-----------------------------------------------------------------------------
 97// TypeSFXEnvironmentName GuiInspectorField Class
 98//-----------------------------------------------------------------------------
 99class GuiInspectorTypeSFXEnvironmentName : public GuiInspectorDatablockField
100{
101   public:
102   
103      typedef GuiInspectorDatablockField Parent;
104      
105   protected:
106   
107      virtual SimSet* _getDatablockSet() const { return Sim::getSFXEnvironmentSet(); }
108   
109   public:
110      DECLARE_CONOBJECT(GuiInspectorTypeSFXEnvironmentName);
111      static void consoleInit();
112};
113
114
115//-----------------------------------------------------------------------------
116// TypeSFXAmbienceName GuiInspectorField Class
117//-----------------------------------------------------------------------------
118class GuiInspectorTypeSFXAmbienceName : public GuiInspectorDatablockField
119{
120   public:
121   
122      typedef GuiInspectorDatablockField Parent;
123      
124   protected:
125   
126      virtual SimSet* _getDatablockSet() const { return Sim::getSFXAmbienceSet(); }
127   
128   public:
129   
130      DECLARE_CONOBJECT(GuiInspectorTypeSFXAmbienceName);
131      static void consoleInit();
132};
133
134
135#endif
136