public void Init(CoreUI ui, BuddyService buddies, StatusPanel status, bool interactive) { UI = ui; Buddies = buddies; Core = buddies.Core; Locations = Core.Locations; Interactive = interactive; SelectionInfo = status; Buddies.GuiUpdate += new BuddyGuiUpdateHandler(Buddy_Update); Locations.GuiUpdate += new LocationGuiUpdateHandler(Location_Update); MouseClick += new MouseEventHandler(BuddyList_MouseClick); MouseDoubleClick += new MouseEventHandler(BuddyList_MouseDoubleClick); MouseDown += new MouseEventHandler(BuddyView_MouseDown); MouseMove += new MouseEventHandler(BuddyView_MouseMove); MouseUp += new MouseEventHandler(BuddyView_MouseUp); DragOver += new DragEventHandler(BuddyView_DragOver); DragDrop += new DragEventHandler(BuddyView_DragDrop); Columns.Add("", 100, System.Windows.Forms.HorizontalAlignment.Left, ColumnScaleStyle.Spring); SmallImageList = new List <Image>(); // itit here, cause main can re-init SmallImageList.Add(new Bitmap(16, 16)); SmallImageList.Add(BuddyRes.away); SmallImageList.Add(BuddyRes.blocked); SelectedIndexChanged += new EventHandler(BuddyView_SelectedIndexChanged); RefreshView(); }
public BuddyUI(CoreUI ui, OpService service) { UI = ui; Core = ui.Core; Buddies = service as BuddyService; }
public BuddyUI(CoreUI ui, OpService service) { UI = ui; Core = ui.Core; Buddies = service as BuddyService; }
public void Init(CoreUI ui, BuddyService buddies, StatusPanel status, bool interactive) { UI = ui; Buddies = buddies; Core = buddies.Core; Locations = Core.Locations; Interactive = interactive; SelectionInfo = status; Buddies.GuiUpdate += new BuddyGuiUpdateHandler(Buddy_Update); Locations.GuiUpdate += new LocationGuiUpdateHandler(Location_Update); MouseClick += new MouseEventHandler(BuddyList_MouseClick); MouseDoubleClick += new MouseEventHandler(BuddyList_MouseDoubleClick); MouseDown += new MouseEventHandler(BuddyView_MouseDown); MouseMove += new MouseEventHandler(BuddyView_MouseMove); MouseUp += new MouseEventHandler(BuddyView_MouseUp); DragOver += new DragEventHandler(BuddyView_DragOver); DragDrop += new DragEventHandler(BuddyView_DragDrop); Columns.Add("", 100, System.Windows.Forms.HorizontalAlignment.Left, ColumnScaleStyle.Spring); SmallImageList = new List<Image>(); // itit here, cause main can re-init SmallImageList.Add(new Bitmap(16, 16)); SmallImageList.Add(BuddyRes.away); SmallImageList.Add(BuddyRes.blocked); SelectedIndexChanged += new EventHandler(BuddyView_SelectedIndexChanged); RefreshView(); }