Exemplo n.º 1
0
//	public override void revertVisible()
//	{
//		base.revertVisible();
//
//		if ( buttonCaption != null )
//		{
//			buttonCaption.revertVisible();
//		}
//
//		if ( buttonBackground != null )
//		{
//			buttonBackground.revertVisible();
//		}
//	}

    public override void setEnable(bool flag)
    {
        base.setEnable(flag);

        if (buttonCaption != null)
        {
            buttonCaption.setEnable(flag);
        }

        if (buttonCollider != null)
        {
            buttonCollider.enabled = flag;
        }

        if (buttonBackground != null)
        {
            buttonBackground.setEnable(flag);
        }

        if (!flag)
        {
            m_isPressed = false;
            m_isHover   = false;

            SwitchStyle(m_skin.disableStyle, m_skin.disableColor);
        }
        else
        {
            SwitchStyle(m_skin.normalStyle, m_skin.normalColor);
        }
    }
Exemplo n.º 2
0
//	public override void revertVisible()
//	{
//		base.revertVisible();
//
//		if ( m_background != null )
//		{
//			m_background.revertVisible();
//		}
//
//		if ( m_foreground != null )
//		{
//			m_foreground.revertVisible();
//		}
//
//		if ( m_lblValue != null )
//		{
//			m_lblValue.revertVisible();
//		}
//	}

    public override void setEnable(bool flag)
    {
        base.setEnable(flag);

        if (m_lblValue != null)
        {
            m_lblValue.setEnable(flag);
        }

        if (m_background != null)
        {
            m_background.setEnable(flag);
        }

        if (m_foreground != null)
        {
            m_foreground.setEnable(flag);
        }
    }