Example #1
0
 public int PlayTapeWithReturns(object sender, TapeRecorderArgs args)
 {
     //The event handlers are called on the same thread  on which the events are raised. If there are multiple event handlers registered with the event
     //then they are called sequentially in the order of registration.
     Console.WriteLine(args.SongName + " is now being played on " + System.Threading.Thread.CurrentThread.ManagedThreadId);
     return 5;
 }
Example #2
0
 public int PlayTapeWithReturns2(object sender, TapeRecorderArgs args)
 {
     Console.WriteLine(args.SongName + " second part is now being played on " + System.Threading.Thread.CurrentThread.ManagedThreadId);
     return 10;
 }
Example #3
0
 public void PlayTape(object sender, TapeRecorderArgs args)
 {
     Console.WriteLine(args.SongName + " is now being played on " + System.Threading.Thread.CurrentThread.ManagedThreadId);
 }