void daemonThread_CardError(object sender, SmartCardReader.CardEventArgs <string> e)
 {
     //  daemonThread_EjectCard(sender, e);
     if (!writing)
     {
         CatelMediator.SendMessage <long>(0, MsgTag.IdCardError);
     }
 }
 void daemonThread_InsertCard(object sender, SmartCardReader.CardEventArgs <string> e)
 {
     lock (_locker)
     {
         CardNumber = e.Value;
         Monitor.PulseAll(_locker);
         if (!writing)
         {
             CatelMediator.SendMessage(true, MsgTag.ClosePinWindow);
             CatelMediator.SendMessage <string>(e.Value, MsgTag.CardInserted);
         }
     }
 }
 void daemonThread_EjectCard(object sender, EventArgs e)
 {
     CatelMediator.SendMessage <long>(0, MsgTag.CardRemoved);
 }
 void daemonThread_StartedCardReading(object sender, EventArgs e)
 {
     CatelMediator.SendMessage <string>("", MsgTag.StartedCardReading);
 }