2010-05-07 04:47:10 -05:00
|
|
|
/*
|
|
|
|
* Copyright 2009, Pier Luigi Fiorini. All rights reserved.
|
|
|
|
* Distributed under the terms of the MIT License.
|
|
|
|
*/
|
|
|
|
#ifndef _ROSTER_LIST_VIEW_H
|
|
|
|
#define _ROSTER_LIST_VIEW_H
|
|
|
|
|
2012-05-15 11:48:53 -05:00
|
|
|
#include <OutlineListView.h>
|
2010-05-07 04:47:10 -05:00
|
|
|
|
|
|
|
class BPopUpMenu;
|
|
|
|
|
2021-05-23 14:39:07 -05:00
|
|
|
class Contact;
|
2010-05-07 04:47:10 -05:00
|
|
|
class RosterItem;
|
|
|
|
|
2012-05-15 11:48:53 -05:00
|
|
|
class RosterListView : public BOutlineListView
|
2010-05-07 04:47:10 -05:00
|
|
|
{
|
|
|
|
public:
|
|
|
|
RosterListView(const char* name);
|
|
|
|
|
|
|
|
virtual void MessageReceived(BMessage* msg);
|
|
|
|
virtual void MouseMoved(BPoint where, uint32 code, const BMessage*);
|
|
|
|
virtual void MouseDown(BPoint where);
|
|
|
|
virtual void Draw(BRect updateRect);
|
2012-03-11 10:11:29 -05:00
|
|
|
virtual void AttachedToWindow();
|
2021-06-18 16:41:09 -05:00
|
|
|
|
2021-07-28 16:53:59 -05:00
|
|
|
virtual bool AddItem(BListItem* item);
|
|
|
|
virtual bool RemoveItem(BListItem* item);
|
2021-06-18 16:41:09 -05:00
|
|
|
RosterItem* RosterItemAt(int32 index);
|
|
|
|
|
2010-05-07 04:47:10 -05:00
|
|
|
void Sort();
|
|
|
|
|
|
|
|
private:
|
2012-03-11 10:11:29 -05:00
|
|
|
|
2021-05-23 14:39:07 -05:00
|
|
|
void _InfoWindow(Contact* linker);
|
2012-03-11 10:11:29 -05:00
|
|
|
|
2010-05-07 04:47:10 -05:00
|
|
|
BPopUpMenu* fPopUp;
|
|
|
|
RosterItem* fPrevItem;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif // _ROSTER_LIST_VIEW_H
|