InspectableRangedField.cs 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. //********************************** Banshee Engine (www.banshee3d.com) **************************************************//
  2. //**************** Copyright (c) 2016 Marko Pintera ([email protected]). All rights reserved. **********************//
  3. using bs;
  4. namespace bs.Editor
  5. {
  6. /** @addtogroup Inspector
  7. * @{
  8. */
  9. /// <summary>
  10. /// IsnpectableRangedField is a <see cref="InspectableField"/> that has a Range attribute and must be rendered as a slider.
  11. /// </summary>
  12. public abstract class InspectableRangedField : InspectableField
  13. {
  14. protected InspectableFieldStyleInfo style;
  15. /// <summary>
  16. /// Creates a new inspectable ranged field GUI for the specified property.
  17. /// </summary>
  18. /// <param name="context">Context shared by all inspectable fields created by the same parent.</param>
  19. /// <param name="title">Name of the property, or some other value to set as the title.</param>
  20. /// <param name="path">Full path to this property (includes name of this property and all parent properties).</param>
  21. /// <param name="type">Type of property this field will be used for displaying.</param>
  22. /// <param name="depth">Determines how deep within the inspector nesting hierarchy is this field. Some fields may
  23. /// contain other fields, in which case you should increase this value by one.</param>
  24. /// <param name="layout">Parent layout that all the field elements will be added to.</param>
  25. /// <param name="property">Serializable property referencing the field whose contents to display.</param>
  26. /// <param name="style">Contains information about the field style</param>
  27. public InspectableRangedField(InspectableContext context, string title, string path, SerializableProperty.FieldType type,
  28. int depth, InspectableFieldLayout layout, SerializableProperty property, InspectableFieldStyleInfo style)
  29. : base(context, title, path, type, depth, layout, property)
  30. {
  31. this.style = style;
  32. }
  33. }
  34. /** @} */
  35. }