Ejemplo n.º 1
0
    public void OnBack()
    {
        RemovePeripherals();

        if (_scanning)
        {
            OnScan();              // this will stop scanning
        }
        BluetoothLEHardwareInterface.DeInitialize(() => {
            BLETestScript.Show(PanelTypeSelection);
        });
    }
Ejemplo n.º 2
0
 public void OnPeripheralSelected()
 {
     if (TextName.text.Contains("RFduino"))
     {
         PanelCentralRFduino.Initialize(this);
         BLETestScript.Show(PanelCentralRFduino.transform);
     }
     else if (TextName.text.Contains("SensorTag"))
     {
         PanelCentralTISensorTag.Initialize(this);
         BLETestScript.Show(PanelCentralTISensorTag.transform);
     }
 }
 public void OnBack()
 {
     if (Connected)
     {
         disconnect((Address) => {
             Connected = false;
             BLETestScript.Show(PanelCentral.transform);
         });
     }
     else
     {
         BLETestScript.Show(PanelCentral.transform);
     }
 }
Ejemplo n.º 4
0
	static public void Show (Transform panel)
	{
		if (_bleTestSCript == null)
		{
			GameObject gameObject = GameObject.Find ("Canvas");
			if (gameObject != null)
				_bleTestSCript = gameObject.GetComponent<BLETestScript> ();
		}

		if (_bleTestSCript != null)
		{
			while (_bleTestSCript.PanelActive.childCount > 0)
				_bleTestSCript.PanelActive.GetChild (0).transform.SetParent (_bleTestSCript.PanelInActive);

			panel.SetParent (_bleTestSCript.PanelActive);
		}
	}
Ejemplo n.º 5
0
    static public void Show(Transform panel)
    {
        if (_bleTestSCript == null)
        {
            GameObject gameObject = GameObject.Find("Canvas");
            if (gameObject != null)
            {
                _bleTestSCript = gameObject.GetComponent <BLETestScript> ();
            }
        }

        if (_bleTestSCript != null)
        {
            while (_bleTestSCript.PanelActive.childCount > 0)
            {
                _bleTestSCript.PanelActive.GetChild(0).transform.SetParent(_bleTestSCript.PanelInActive);
            }

            panel.SetParent(_bleTestSCript.PanelActive);
        }
    }
Ejemplo n.º 6
0
 public void OnBack()
 {
     BluetoothLEHardwareInterface.DeInitialize(() => {
         BLETestScript.Show(PanelTypeSelection);
     });
 }
Ejemplo n.º 7
0
 public void OnPeripheral()
 {
     PanelPeripheral.Initialize();
     BLETestScript.Show(PanelPeripheral.gameObject.transform);
 }