Ejemplo n.º 1
0
 /// <summary>
 /// Constructor from an event object
 /// </summary>
 /// <param name="args">The event args</param>
 public LogPacket(LogPacketEventArgs args)
     : this(args.Tag, args.NetId, Guid.NewGuid(), args.NetworkDescription, args.Frame, args.Color, args.Timestamp)
 {
 }
Ejemplo n.º 2
0
        private void log_AddLogPacket(object sender, LogPacketEventArgs e)
        {
            LogPacket packet = new LogPacket(e);

            if (FilterLogPacketEvent != null)
            {
                FilterPacketLogEventArgs args = new FilterPacketLogEventArgs(packet, sender as NetGraph);

                FilterLogPacketEvent.Invoke(this, args);

                if (args.Filter)
                {
                    packet = null;
                }
                else
                {
                    packet = args.Packet;
                }
            }

            if (packet != null)
            {
                lock (_packetLog)
                {
                    _packetLog.Add(packet);
                }
            }
        }
Ejemplo n.º 3
0
 /// <summary>
 /// Constructor from an event object
 /// </summary>
 /// <param name="args">The event args</param>
 public LogPacket(LogPacketEventArgs args)
     : this(args.Tag, args.NetId, Guid.NewGuid(), args.NetworkDescription, args.Frame, args.Color, args.Timestamp)
 {
 }
Ejemplo n.º 4
0
 void log_AddLogPacket(object sender, LogPacketEventArgs e)
 {
     logPacketControlOutput.AddLogEntry(new LogPacket(e));
 }