abstract class BaseButtonView extends inkDiscreteNavigationController
{
	protected var m_ButtonController : weak< inkButtonController >;

	protected event OnInitialize()
	{
		m_ButtonController = ( ( inkButtonController )( GetControllerByBaseType( 'inkButtonController' ) ) );
		if( m_ButtonController )
		{
			m_ButtonController.RegisterToCallback( 'OnButtonStateChanged', this, 'OnButtonStateChanged' );
			ButtonStateChanged( m_ButtonController.GetState(), m_ButtonController.GetState() );
			m_ButtonController.RegisterToCallback( 'OnButtonHoldProgressChanged', this, 'OnButtonHoldProgressChanged' );
			ButtonHoldProgressChanged( m_ButtonController.GetHoldProgress() );
		}
	}

	protected event OnButtonStateChanged( controller : weak< inkButtonController >, oldState : inkEButtonState, newState : inkEButtonState )
	{
		ButtonStateChanged( oldState, newState );
	}

	protected event OnButtonHoldProgressChanged( controller : weak< inkButtonController >, progress : Float )
	{
		ButtonHoldProgressChanged( progress );
	}

	protected virtual function ButtonStateChanged( oldState : inkEButtonState, newState : inkEButtonState ) {}

	protected virtual function ButtonHoldProgressChanged( progress : Float ) {}

	public function GetParentButton() : weak< inkButtonController >
	{
		return m_ButtonController;
	}

}

