mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-07 08:35:16 -04:00
improved network statistics for GXS net service. Added number of available messages for unsubscribed forums in GUI. Should be done as well for channels.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7760 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
d4dad8328f
commit
93f77a0e2c
15 changed files with 186 additions and 113 deletions
|
@ -22,6 +22,7 @@
|
|||
#include <QMenu>
|
||||
#include <QToolButton>
|
||||
|
||||
#include "retroshare/rsgxsflags.h"
|
||||
#include "GroupTreeWidget.h"
|
||||
#include "ui_GroupTreeWidget.h"
|
||||
|
||||
|
@ -353,18 +354,22 @@ void GroupTreeWidget::fillGroupItems(QTreeWidgetItem *categoryItem, const QList<
|
|||
item->setIcon(COLUMN_NAME, itemInfo.icon);
|
||||
|
||||
/* Set popularity */
|
||||
QString tooltip = PopularityDefs::tooltip(itemInfo.popularity);
|
||||
QString tooltip = PopularityDefs::tooltip(itemInfo.popularity);
|
||||
|
||||
item->setIcon(COLUMN_POPULARITY, PopularityDefs::icon(itemInfo.popularity));
|
||||
item->setData(COLUMN_DATA, ROLE_POPULARITY, -itemInfo.popularity); // negative for correct sorting
|
||||
|
||||
/* Set tooltip */
|
||||
if (itemInfo.privatekey) {
|
||||
tooltip += "\n" + tr("Private Key Available");
|
||||
}
|
||||
}
|
||||
if(!IS_GROUP_SUBSCRIBED(itemInfo.subscribeFlags))
|
||||
tooltip += "\n" + QString::number(itemInfo.max_visible_posts) + " messages available" ;
|
||||
|
||||
item->setToolTip(COLUMN_NAME, tooltip);
|
||||
item->setToolTip(COLUMN_POPULARITY, tooltip);
|
||||
|
||||
item->setData(COLUMN_DATA, ROLE_SUBSCRIBE_FLAGS, itemInfo.subscribeFlags);
|
||||
item->setData(COLUMN_DATA, ROLE_SUBSCRIBE_FLAGS, itemInfo.subscribeFlags);
|
||||
|
||||
/* Set color */
|
||||
QBrush brush;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue