mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-01-27 15:57:08 -05:00
removed some more old code from forum thread widget
This commit is contained in:
parent
9c840baf2e
commit
09ffffe88e
@ -317,6 +317,7 @@ GxsForumThreadWidget::GxsForumThreadWidget(const RsGxsGroupId &forumId, QWidget
|
|||||||
{
|
{
|
||||||
ui->setupUi(this);
|
ui->setupUi(this);
|
||||||
|
|
||||||
|
#ifdef TO_REMOVE
|
||||||
mTokenTypeGroupData = nextTokenType();
|
mTokenTypeGroupData = nextTokenType();
|
||||||
mTokenTypeInsertThreads = nextTokenType();
|
mTokenTypeInsertThreads = nextTokenType();
|
||||||
mTokenTypeMessageData = nextTokenType();
|
mTokenTypeMessageData = nextTokenType();
|
||||||
@ -327,10 +328,11 @@ GxsForumThreadWidget::GxsForumThreadWidget(const RsGxsGroupId &forumId, QWidget
|
|||||||
mTokenTypeNeutralAuthor = nextTokenType();
|
mTokenTypeNeutralAuthor = nextTokenType();
|
||||||
mTokenTypePositiveAuthor = nextTokenType();
|
mTokenTypePositiveAuthor = nextTokenType();
|
||||||
mTokenTypeEditForumMessage = nextTokenType();
|
mTokenTypeEditForumMessage = nextTokenType();
|
||||||
|
#endif
|
||||||
|
|
||||||
setUpdateWhenInvisible(true);
|
setUpdateWhenInvisible(true);
|
||||||
|
|
||||||
#ifdef TODO
|
#ifdef TO_REMOVE
|
||||||
/* Setup UI helper */
|
/* Setup UI helper */
|
||||||
mStateHelper->addWidget(mTokenTypeGroupData, ui->subscribeToolButton);
|
mStateHelper->addWidget(mTokenTypeGroupData, ui->subscribeToolButton);
|
||||||
mStateHelper->addWidget(mTokenTypeGroupData, ui->newthreadButton);
|
mStateHelper->addWidget(mTokenTypeGroupData, ui->newthreadButton);
|
||||||
@ -373,6 +375,7 @@ GxsForumThreadWidget::GxsForumThreadWidget(const RsGxsGroupId &forumId, QWidget
|
|||||||
ui->threadTreeWidget->setModel(mThreadProxyModel);
|
ui->threadTreeWidget->setModel(mThreadProxyModel);
|
||||||
|
|
||||||
ui->threadTreeWidget->setSortingEnabled(true);
|
ui->threadTreeWidget->setSortingEnabled(true);
|
||||||
|
ui->threadTreeWidget->setDynamicSortFilter(true);
|
||||||
|
|
||||||
ui->threadTreeWidget->setItemDelegateForColumn(RsGxsForumModel::COLUMN_THREAD_DISTRIBUTION,new DistributionItemDelegate()) ;
|
ui->threadTreeWidget->setItemDelegateForColumn(RsGxsForumModel::COLUMN_THREAD_DISTRIBUTION,new DistributionItemDelegate()) ;
|
||||||
ui->threadTreeWidget->setItemDelegateForColumn(RsGxsForumModel::COLUMN_THREAD_AUTHOR,new AuthorItemDelegate()) ;
|
ui->threadTreeWidget->setItemDelegateForColumn(RsGxsForumModel::COLUMN_THREAD_AUTHOR,new AuthorItemDelegate()) ;
|
||||||
@ -600,9 +603,11 @@ QString GxsForumThreadWidget::groupName(bool withUnreadCount)
|
|||||||
|
|
||||||
QIcon GxsForumThreadWidget::groupIcon()
|
QIcon GxsForumThreadWidget::groupIcon()
|
||||||
{
|
{
|
||||||
|
#ifdef TO_REMOVE
|
||||||
if (mStateHelper->isLoading(mTokenTypeGroupData) || mFillThread) {
|
if (mStateHelper->isLoading(mTokenTypeGroupData) || mFillThread) {
|
||||||
return QIcon(":/images/kalarm.png");
|
return QIcon(":/images/kalarm.png");
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
if (mNewCount) {
|
if (mNewCount) {
|
||||||
return QIcon(":/images/message-state-new.png");
|
return QIcon(":/images/message-state-new.png");
|
||||||
@ -2330,6 +2335,7 @@ bool GxsForumThreadWidget::navigate(const RsGxsMessageId &msgId)
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef TO_REMOVE
|
||||||
bool GxsForumThreadWidget::isLoading()
|
bool GxsForumThreadWidget::isLoading()
|
||||||
{
|
{
|
||||||
if (mStateHelper->isLoading(mTokenTypeGroupData) || mFillThread) {
|
if (mStateHelper->isLoading(mTokenTypeGroupData) || mFillThread) {
|
||||||
@ -2338,6 +2344,7 @@ bool GxsForumThreadWidget::isLoading()
|
|||||||
|
|
||||||
return GxsMessageFrameWidget::isLoading();
|
return GxsMessageFrameWidget::isLoading();
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
void GxsForumThreadWidget::copyMessageLink()
|
void GxsForumThreadWidget::copyMessageLink()
|
||||||
{
|
{
|
||||||
@ -2761,8 +2768,11 @@ void GxsForumThreadWidget::updateGroupData()
|
|||||||
|
|
||||||
if(groups.size() != 1)
|
if(groups.size() != 1)
|
||||||
{
|
{
|
||||||
|
std::cerr << __PRETTY_FUNCTION__ << " obtained more than one group info for forum " << groupId() << std::endl;
|
||||||
|
#ifdef TO_REMOVE
|
||||||
mStateHelper->setActive(mTokenTypeGroupData, false);
|
mStateHelper->setActive(mTokenTypeGroupData, false);
|
||||||
mStateHelper->clear(mTokenTypeGroupData);
|
mStateHelper->clear(mTokenTypeGroupData);
|
||||||
|
#endif
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2813,8 +2823,11 @@ void GxsForumThreadWidget::updateMessageData(const RsGxsMessageId& msgId)
|
|||||||
|
|
||||||
if(msgs.size() != 1)
|
if(msgs.size() != 1)
|
||||||
{
|
{
|
||||||
|
std::cerr << __PRETTY_FUNCTION__ << " obtained more than one msg info for msgId " << msgId << std::endl;
|
||||||
|
#ifdef TO_REMOVE
|
||||||
mStateHelper->setActive(mTokenTypeGroupData, false);
|
mStateHelper->setActive(mTokenTypeGroupData, false);
|
||||||
mStateHelper->clear(mTokenTypeGroupData);
|
mStateHelper->clear(mTokenTypeGroupData);
|
||||||
|
#endif
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -74,7 +74,7 @@ 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();
|
//virtual bool isLoading();
|
||||||
|
|
||||||
unsigned int newCount() { return mNewCount; }
|
unsigned int newCount() { return mNewCount; }
|
||||||
unsigned int unreadCount() { return mUnreadCount; }
|
unsigned int unreadCount() { return mUnreadCount; }
|
||||||
@ -217,6 +217,7 @@ private:
|
|||||||
unsigned int mUnreadCount;
|
unsigned int mUnreadCount;
|
||||||
unsigned int mNewCount;
|
unsigned int mNewCount;
|
||||||
|
|
||||||
|
#ifdef TO_REMOVE
|
||||||
uint32_t mTokenTypeGroupData;
|
uint32_t mTokenTypeGroupData;
|
||||||
uint32_t mTokenTypeInsertThreads;
|
uint32_t mTokenTypeInsertThreads;
|
||||||
uint32_t mTokenTypeMessageData;
|
uint32_t mTokenTypeMessageData;
|
||||||
@ -227,6 +228,7 @@ private:
|
|||||||
uint32_t mTokenTypeNegativeAuthor;
|
uint32_t mTokenTypeNegativeAuthor;
|
||||||
uint32_t mTokenTypePositiveAuthor;
|
uint32_t mTokenTypePositiveAuthor;
|
||||||
uint32_t mTokenTypeNeutralAuthor;
|
uint32_t mTokenTypeNeutralAuthor;
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Color definitions (for standard see qss.default) */
|
/* Color definitions (for standard see qss.default) */
|
||||||
QColor mTextColorRead;
|
QColor mTextColorRead;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user