using Editor;
using Sandbox;
using VeloX.Audio;

namespace VeloX;

[CustomEditor( typeof( Controller ) )]
public class ControllerWidget : ControlObjectWidget
{
	public override bool SupportsMultiEdit => false;
	public override bool IsWideMode => true;

	public ControllerWidget( SerializedProperty property ) : base( property, true )
	{

		Layout = Layout.Column();

		SerializedObject.TryGetProperty( nameof( Controller.InputParameter ), out var inputType );
		Layout.Add( Create( inputType ) );
		SerializedObject.TryGetProperty( nameof( Controller.InputRange ), out var inputRange );
		Layout.Add( Create( inputRange ) );
		
		SerializedObject.TryGetProperty( nameof( Controller.OutputParameter ), out var outputType );
		Layout.Add( Create( outputType ) );
		SerializedObject.TryGetProperty( nameof( Controller.OutputRange ), out var outputRange );
		Layout.Add( Create( outputRange ) );
	}

	protected override void OnPaint() { }
}
