// Use this for initialization void Awake() { m_controller = transform.GetComponentInChildren <GalaxyTweenController>(); m_mainSpot = transform.Find("Root/Sprite").gameObject; m_targetWidget = transform.GetComponent <UIWidget>(); m_dragObj = transform.GetComponentInChildren <UIDragObject>(); UIEventListener.Get(m_mainSpot).onPress = OnPress; UIEventListener.Get(m_mainSpot).onDrag = OnDrag; SetWidgetSize(false); }
// Use this for initialization void Start() { controller = transform.GetComponent <GalaxyTweenController>(); }
void OnEnable() { _src = target as GalaxyTweenController; _src.ReInit(); }