Exemplo n.º 1
0
        public ScanTrigger()
        {
            hObject = CoreDLL.CreateEvent(IntPtr.Zero, false, false, CoreDLL.TriggerKeyEvent);
            Thread thread = new Thread(new ThreadStart(ThreadProc));

            thread.Start();
        }
Exemplo n.º 2
0
 protected virtual void Dispose(bool disposing)
 {
     // Check to see if Dispose has already been called.
     if (!this.disposed)
     {
         // If disposing equals true, dispose all managed
         // and unmanaged resources.
         if (disposing)
         {
             // Dispose managed resources.
         }
         // Release unmanaged resources. If disposing is false,
         // only the following code is executed.
         bRuning = false;
         if (hObject != IntPtr.Zero)
         {
             CoreDLL.CloseHandle(hObject);
         }
     }
     disposed = true;
 }