public DPAPPageWidget() { Console.WriteLine("DPAP Page widget ctor!"); tree = new TreeView(); Add(tree); TreeViewColumn albumColumn = new Gtk.TreeViewColumn(); //albumColumn.Title = "album"; Gtk.CellRendererText albumNameCell = new Gtk.CellRendererText(); albumNameCell.Visible = true; albumColumn.PackStart(albumNameCell, false); tree.AppendColumn(albumColumn); list = new TreeStore(typeof(string)); tree.Model = list; albumColumn.AddAttribute(albumNameCell, "text", 0); tree.Selection.Changed += OnSelectionChanged; sd = new DPAP.ServiceDiscovery(); sd.Found += OnServiceFound; sd.Removed += OnServiceRemoved; sd.Start(); }
public bool Stop() { uint timer = Log.InformationTimerStart ("Stopping DPAP"); if (sd != null) { sd.Stop (); sd.Found -= OnServiceFound; //locator.Removed -= OnServiceRemoved; sd = null; } return true; }
public bool Stop() { uint timer = Log.InformationTimerStart("Stopping DPAP"); if (sd != null) { sd.Stop(); sd.Found -= OnServiceFound; //locator.Removed -= OnServiceRemoved; sd = null; } //Log.DebugTimerPrint (timer, "BeagleService shutdown took {0}"); return(true); }
public static void Main(string [] args) { ServiceDiscovery sd = new ServiceDiscovery (); sd.Found += OnServiceFound; sd.Start (); // sd.Services [0]; Console.ReadLine (); if (sd != null) { sd.Stop (); sd.Found -= OnServiceFound; //locator.Removed -= OnServiceRemoved; sd = null; } }
public static void Main(string [] args) { ServiceDiscovery sd = new ServiceDiscovery(); sd.Found += OnServiceFound; sd.Start(); // sd.Services [0]; Console.ReadLine(); if (sd != null) { sd.Stop(); sd.Found -= OnServiceFound; //locator.Removed -= OnServiceRemoved; sd = null; } }
public bool Stop () { uint timer = Log.InformationTimerStart ("Stopping DPAP"); if (sd != null) { sd.Stop (); sd.Found -= OnServiceFound; //locator.Removed -= OnServiceRemoved; sd = null; } //Log.DebugTimerPrint (timer, "BeagleService shutdown took {0}"); return true; }
public DPAPPageWidget() { Console.WriteLine ("DPAP Page widget ctor!"); tree = new TreeView (); Add (tree); TreeViewColumn albumColumn = new Gtk.TreeViewColumn (); //albumColumn.Title = "album"; Gtk.CellRendererText albumNameCell = new Gtk.CellRendererText (); albumNameCell.Visible = true; albumColumn.PackStart (albumNameCell,false); tree.AppendColumn (albumColumn); list = new TreeStore (typeof (string)); tree.Model = list; albumColumn.AddAttribute (albumNameCell, "text", 0); tree.Selection.Changed += OnSelectionChanged; sd = new DPAP.ServiceDiscovery (); sd.Found += OnServiceFound; sd.Removed += OnServiceRemoved; sd.Start (); }