// --------------------------------------------------------------------------------------------------------------------
//
// Copyright (c) VRMADA, All rights reserved.
//
// --------------------------------------------------------------------------------------------------------------------
using UnityEngine;
namespace UltimateXR.Attributes
{
///
/// Attribute to visualize inspector fields as read-only so that they can't be edited.
/// This can be used for debugging purposes, to expose component information to the user but without the possibility to
/// edit the data. It also provides additional functionality:
///
/// - Make the field read-only during play mode but editable during edit mode.
/// - Hide the field during edit-mode.
///
///
public class ReadOnlyAttribute : PropertyAttribute
{
#region Public Types & Data
///
/// Whether to apply the read-only mode only while playing.
///
public bool OnlyWhilePlaying { get; set; } = false;
///
/// Whether to hide the variable during edit-mode.
///
public bool HideInEditMode { get; set; } = false;
///
/// Whether to hide the variable during play-mode.
///
public bool HideInPlayMode { get; set; } = false;
#endregion
}
}