#include "friendlistitem.h"
#include "friendlistitemdelegate.h"
#include "friendlistview.h"
+#include "imagebutton.h"
#include "panelcommon.h"
#include "user/user.h"
m_friendListHeaderWidget->setLayout(filterLayout);
m_friendListHeaderWidget->setAutoFillBackground(true);
- m_routeButton = new QPushButton(tr("Route to friend"));
+ m_routeButton = new ImageButton(this, ":res/images/routing.png", ":res/images/routing.png");
m_routeButton->setDisabled(true);
QPalette labelPalette = m_friendListHeaderWidget->palette();
m_friendListHeaderWidget->setPalette(labelPalette);
m_friendListHeaderWidget->hide();
m_friendListLabel = new QLabel(this);
- m_clearFilterButton = new QPushButton(tr("Show all"));
+ ImageButton *clearFilterButton = new ImageButton(this, ":res/images/friend_list.png",
+ ":res/images/friend_list.png");
filterLayout->addWidget(m_friendListLabel);
- filterLayout->addWidget(m_clearFilterButton);
+ filterLayout->addWidget(clearFilterButton);
m_friendListView = new FriendListView(this);
m_friendListView->setItemDelegate(new FriendListItemDelegate(this));
connect(m_friendListView, SIGNAL(friendItemClicked(GeoCoordinate)),
this, SIGNAL(findFriend(GeoCoordinate)));
- connect(m_clearFilterButton, SIGNAL(clicked()),
+ connect(clearFilterButton, SIGNAL(clicked()),
this, SLOT(clearFiltering()));
connect(m_routeButton, SIGNAL(clicked()),
connect(qApp, SIGNAL(topmostWindowChanged(bool)),
this, SLOT(topmostWindowChanged(bool)));
+
+
+ // CONTEXT BUTTONS
+ m_contextButtonList.append(m_routeButton);
+ m_contextButtonList.append(clearFilterButton);
}
void FriendListPanel::anyPanelClosed()
class QPushButton;
class FriendListItemDelegate;
-class GeoCoordinate;
class FriendListView;
+class GeoCoordinate;
+class ImageButton;
class User;
/**
QLineEdit *m_filterField; ///< Text field for the filter text
- QPushButton *m_clearFilterButton; ///< Button to clear list filtering
QPushButton *m_filterClearButton; ///< Button for clearing the filtering
- QPushButton *m_routeButton; ///< Button to route to friend
QWidget *m_friendListHeaderWidget; ///< Friend list header widget
FriendListView *m_friendListView; ///< Friend list view
+ ImageButton *m_routeButton; ///< Button to route to friend
};
#endif // FRIENDLISTPANEL_H