示例#1
0
 /// <summary>
 /// Processes events from this queue one at a time, until there are no
 /// further events remaining, and dispatches them to proper C# AL5.
 /// </summary>
 public void DispatchAll()
 {
     if (IsEmpty)
         return;
     else
     {
         AL5.Events.ALEvent evt = new AL5.Events.ALEvent();
         while (!IsEmpty)
         {
             NextRawEvent(ref evt);
             Dispatch(ref evt);
         }
     }
 }
示例#2
0
 /// <summary>
 /// Waits for an event to be posted to this event queue, then
 /// dispatches all events until the queue is empty once again.
 /// </summary>
 public void WaitDispatchAll()
 {
     AL5.Events.ALEvent evt = new AL5.Events.ALEvent();
     WaitForRawEvent(ref evt);
     do
     {
         Dispatch(ref evt);
         NextRawEvent(ref evt);
     } while (!IsEmpty);
 }