海淀天下城电子沙盘单机版
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
677 B

4 years ago
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
[RequireComponent(typeof(Toggle))]
public class RecordStop : MonoBehaviour {
private Toggle toggle;
public Text name;
// Use this for initialization
void Start ()
{
toggle = GetComponent<Toggle>();
toggle.onValueChanged.AddListener(ValueChanged);
}
private void ValueChanged(bool isOn)
{
if (isOn)
{
name.text = "暂停记录";
}
else
{
name.text = "正在记录";
}
}
// Update is called once per frame
void Update () {
}
}