예제 #1
0
        private void OnTapReady(TAPDevice tap, bool success)
        {
            this.pending.Remove(tap.Identifier);
            if (success)
            {
                TAPManagerLog.Instance.Log(TAPManagerLogEvent.Info, "TAP is Ready:" + tap.GetStringDescription());
                tap.sendMode();
                tap.SetEventActions(this.OnTapTapped, this.OnTapMoused);


                if (this.OnTapConnected != null)
                {
                    this.OnTapConnected(tap.Identifier, tap.Name, tap.FW);
                }

                if (leftId == "")
                {
                    leftId = tap.Identifier;
                }
                else
                {
                    rightId = tap.Identifier;
                }
            }
            else
            {
                TAPManagerLog.Instance.Log(TAPManagerLogEvent.Error, "Couldn't make TAP Ready: " + tap.GetStringDescription());
                this.taps.Remove(tap.Identifier);
            }
        }
예제 #2
0
        private void OnTapReady(TAPDevice tap, bool success)
        {
            this.pending.Remove(tap.Identifier);
            if (success)
            {
                TAPManagerLog.Instance.Log(TAPManagerLogEvent.Info, "TAP is Ready:" + tap.GetStringDescription());
                tap.sendMode();
                tap.SetEventActions(this.OnTapTapped, this.OnTapMoused, this.OnTapChangedAirGestureState, this.OnTapAirGestured, this.OnTapRawSensorDataReceived);


                if (this.OnTapConnected != null)
                {
                    this.OnTapConnected(tap.Identifier, tap.Name, tap.FW);
                }
            }
            else
            {
                TAPManagerLog.Instance.Log(TAPManagerLogEvent.Error, "Couldn't make TAP Ready: " + tap.GetStringDescription());
                this.taps.Remove(tap.Identifier);
            }
        }