Changeset 140
- Timestamp:
- 03/06/07 21:52:01 (2 years ago)
- Files:
-
- dmp/trunk/Bridge/Bridge.cs (modified) (3 diffs)
- dmp/trunk/Bridge/SongListChangeEventArgs.cs (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
dmp/trunk/Bridge/Bridge.cs
r139 r140 24 24 /// </summary> 25 25 public event EventHandler<ServerStatusEventArgs> ServerRemoved; 26 27 /// <summary> 28 /// Fires when the list of songs is changed 29 /// </summary> 30 public event EventHandler<SongListChangedEventArgs> SongListChanged; 26 31 27 32 /// <summary> … … 254 259 Console.WriteLine("Connected to " + newClient.Name); 255 260 261 if (this.SongListChanged != null) { 262 DataTable newSongs = this.getAvailableSongsInCollection(); 263 this.SongListChanged(this, new SongListChangedEventArgs(newSongs)); 264 } 265 256 266 return newClient.Id; 257 267 } … … 302 312 this.ServerRemoved(this, new ServerStatusEventArgs(oldServer.Name, true)); 303 313 } 314 if (this.SongListChanged != null) { 315 DataTable newSongs = this.getAvailableSongsInCollection(); 316 this.SongListChanged(this, new SongListChangedEventArgs(newSongs)); 317 } 304 318 } 305 319 else { dmp/trunk/Bridge/SongListChangeEventArgs.cs
r139 r140 1 1 using System; 2 2 using System.Collections.Generic; 3 using System.Data; 3 4 using System.Text; 4 5 … … 7 8 /// The arguments for a SongListChange event 8 9 /// </summary> 9 class SongListChangeEventArgs { 10 public class SongListChangedEventArgs : EventArgs { 11 /// <summary> 12 /// The new data table 13 /// </summary> 14 public DataTable NewTable; 15 16 /// <summary> 17 /// Creates a new instance of the SongListChangeEventArgs 18 /// </summary> 19 /// <param name="theTable">The new DataTable</param> 20 public SongListChangedEventArgs(DataTable theTable) { 21 this.NewTable = theTable; 22 } 23 10 24 11 25 }
