mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-02-17 21:34:10 -05:00
fixed fonts for unread msgs in Forum Model
This commit is contained in:
parent
f56e932fb7
commit
b7b9f335f9
@ -287,7 +287,7 @@ QVariant RsGxsForumModel::data(const QModelIndex &index, int role) const
|
|||||||
if(role == Qt::FontRole)
|
if(role == Qt::FontRole)
|
||||||
{
|
{
|
||||||
QFont font ;
|
QFont font ;
|
||||||
font.setBold( (fmpe.mPostFlags & (ForumModelPostEntry::FLAG_POST_HAS_UNREAD_CHILDREN | ForumModelPostEntry::FLAG_POST_IS_PINNED)));
|
font.setBold( (fmpe.mPostFlags & (ForumModelPostEntry::FLAG_POST_HAS_UNREAD_CHILDREN | ForumModelPostEntry::FLAG_POST_IS_PINNED)) || IS_MSG_UNREAD(fmpe.mMsgStatus));
|
||||||
return QVariant(font);
|
return QVariant(font);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -383,7 +383,6 @@ GxsForumThreadWidget::GxsForumThreadWidget(const RsGxsGroupId &forumId, QWidget
|
|||||||
ui->threadTreeWidget->setItemDelegateForColumn(RsGxsForumModel::COLUMN_THREAD_READ,new ReadStatusItemDelegate()) ;
|
ui->threadTreeWidget->setItemDelegateForColumn(RsGxsForumModel::COLUMN_THREAD_READ,new ReadStatusItemDelegate()) ;
|
||||||
|
|
||||||
ui->threadTreeWidget->header()->setSortIndicatorShown(true);
|
ui->threadTreeWidget->header()->setSortIndicatorShown(true);
|
||||||
connect(ui->threadTreeWidget->header(),SIGNAL(sortIndicatorChanged(int,Qt::SortOrder)),this,SLOT(sortColumn(int,Qt::SortOrder)));
|
|
||||||
|
|
||||||
connect(ui->versions_CB, SIGNAL(currentIndexChanged(int)), this, SLOT(changedVersion()));
|
connect(ui->versions_CB, SIGNAL(currentIndexChanged(int)), this, SLOT(changedVersion()));
|
||||||
connect(ui->threadTreeWidget, SIGNAL(customContextMenuRequested(QPoint)), this, SLOT(threadListCustomPopupMenu(QPoint)));
|
connect(ui->threadTreeWidget, SIGNAL(customContextMenuRequested(QPoint)), this, SLOT(threadListCustomPopupMenu(QPoint)));
|
||||||
@ -492,11 +491,6 @@ GxsForumThreadWidget::GxsForumThreadWidget(const RsGxsGroupId &forumId, QWidget
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void GxsForumThreadWidget::sortColumn(int col,Qt::SortOrder o)
|
|
||||||
{
|
|
||||||
ui->threadTreeWidget->sortByColumn(col,o);
|
|
||||||
}
|
|
||||||
|
|
||||||
void GxsForumThreadWidget::blank()
|
void GxsForumThreadWidget::blank()
|
||||||
{
|
{
|
||||||
ui->progressBar->hide();
|
ui->progressBar->hide();
|
||||||
|
@ -74,15 +74,12 @@ public:
|
|||||||
virtual QString groupName(bool withUnreadCount);
|
virtual QString groupName(bool withUnreadCount);
|
||||||
virtual QIcon groupIcon();
|
virtual QIcon groupIcon();
|
||||||
virtual bool navigate(const RsGxsMessageId& msgId);
|
virtual bool navigate(const RsGxsMessageId& msgId);
|
||||||
//virtual bool isLoading();
|
|
||||||
|
|
||||||
unsigned int newCount() { return mNewCount; }
|
unsigned int newCount() { return mNewCount; }
|
||||||
unsigned int unreadCount() { return mUnreadCount; }
|
unsigned int unreadCount() { return mUnreadCount; }
|
||||||
|
|
||||||
QTreeWidgetItem *generateMissingItem(const RsGxsMessageId &msgId);
|
QTreeWidgetItem *generateMissingItem(const RsGxsMessageId &msgId);
|
||||||
|
|
||||||
// Callback for all Loads.
|
|
||||||
//virtual void loadRequest(const TokenQueue *queue, const TokenRequest &req);
|
|
||||||
virtual void blank();
|
virtual void blank();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -99,7 +96,6 @@ private slots:
|
|||||||
/** Create the context popup menu and it's submenus */
|
/** Create the context popup menu and it's submenus */
|
||||||
void threadListCustomPopupMenu(QPoint point);
|
void threadListCustomPopupMenu(QPoint point);
|
||||||
void contextMenuTextBrowser(QPoint point);
|
void contextMenuTextBrowser(QPoint point);
|
||||||
void sortColumn(int col,Qt::SortOrder o);
|
|
||||||
|
|
||||||
void changedThread(QModelIndex index);
|
void changedThread(QModelIndex index);
|
||||||
void changedVersion();
|
void changedVersion();
|
||||||
@ -120,11 +116,6 @@ private slots:
|
|||||||
|
|
||||||
void saveImage();
|
void saveImage();
|
||||||
|
|
||||||
|
|
||||||
//void print();
|
|
||||||
//void printpreview();
|
|
||||||
|
|
||||||
//void removemessage();
|
|
||||||
void markMsgAsRead();
|
void markMsgAsRead();
|
||||||
void markMsgAsReadChildren();
|
void markMsgAsReadChildren();
|
||||||
void markMsgAsUnread();
|
void markMsgAsUnread();
|
||||||
@ -165,15 +156,9 @@ private:
|
|||||||
void insertMessage();
|
void insertMessage();
|
||||||
void insertGroupData();
|
void insertGroupData();
|
||||||
|
|
||||||
//void insertThreads();
|
|
||||||
//void fillThreads(QList<QTreeWidgetItem *> &threadList, bool expandNewMessages, QList<QTreeWidgetItem*> &itemToExpand);
|
|
||||||
//void fillChildren(QTreeWidgetItem *parentItem, QTreeWidgetItem *newParentItem, bool expandNewMessages, QList<QTreeWidgetItem*> &itemToExpand);
|
|
||||||
|
|
||||||
int getSelectedMsgCount(QList<QTreeWidgetItem*> *pRows, QList<QTreeWidgetItem*> *pRowsRead, QList<QTreeWidgetItem*> *pRowsUnread);
|
int getSelectedMsgCount(QList<QTreeWidgetItem*> *pRows, QList<QTreeWidgetItem*> *pRowsRead, QList<QTreeWidgetItem*> *pRowsUnread);
|
||||||
void setMsgReadStatus(QList<QTreeWidgetItem*> &rows, bool read);
|
void setMsgReadStatus(QList<QTreeWidgetItem*> &rows, bool read);
|
||||||
void markMsgAsReadUnread(bool read, bool children, bool forum);
|
void markMsgAsReadUnread(bool read, bool children, bool forum);
|
||||||
//void calculateIconsAndFonts(QTreeWidgetItem *item = NULL);
|
|
||||||
//void calculateIconsAndFonts(QTreeWidgetItem *item, bool &hasReadChilddren, bool &hasUnreadChilddren);
|
|
||||||
void calculateUnreadCount();
|
void calculateUnreadCount();
|
||||||
|
|
||||||
void togglethreadview_internal();
|
void togglethreadview_internal();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user