Skip to content

Commit 9f8907f

Browse files
committed
feat(UI): Virtual public functions in JCS_CanvasComp
1 parent a7fa492 commit 9f8907f

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

Assets/JCSUnity/Scripts/UI/JCS_CanvasComp.cs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ public class JCS_CanvasComp<T> : MonoBehaviour
1111
{
1212
/* Variables */
1313

14+
// The canvas this component to control.
1415
protected JCS_Canvas mCanvas = null;
1516

1617
/* Setter & Getter */
@@ -22,8 +23,8 @@ protected virtual void Awake()
2223
this.mCanvas = this.GetComponent<JCS_Canvas>();
2324
}
2425

25-
public void Show() => mCanvas.Show();
26-
public void Hide() => mCanvas.Hide();
27-
public void ToggleVisibility() => mCanvas.ToggleVisibility();
26+
public virtual void Show() => mCanvas.Show();
27+
public virtual void Hide() => mCanvas.Hide();
28+
public virtual void ToggleVisibility() => mCanvas.ToggleVisibility();
2829
}
2930
}

0 commit comments

Comments
 (0)