mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-07-28 08:54:13 -04:00
Added basic widget RSFeedWidget for showing feed items in a QTreeWidget as replacement for the QScrollArea.
- Use sort of QTreeWidget - Filter items - Open/collapse selected item with +/- - Remove selecteds item with dselete key git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7478 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
e588b25b67
commit
d13aa90b2b
20 changed files with 841 additions and 183 deletions
|
@ -32,14 +32,14 @@
|
|||
|
||||
/** Constructor */
|
||||
|
||||
PostedItem::PostedItem(FeedHolder *parent, uint32_t feedId, const RsGxsGroupId &groupId, const RsGxsMessageId &messageId, bool isHome) :
|
||||
GxsFeedItem(parent, feedId, groupId, messageId, isHome, rsPosted, true, false)
|
||||
PostedItem::PostedItem(FeedHolder *feedHolder, uint32_t feedId, const RsGxsGroupId &groupId, const RsGxsMessageId &messageId, bool isHome) :
|
||||
GxsFeedItem(feedHolder, feedId, groupId, messageId, isHome, rsPosted, true, false)
|
||||
{
|
||||
setup();
|
||||
}
|
||||
|
||||
PostedItem::PostedItem(FeedHolder *parent, uint32_t feedId, const RsPostedPost &post, bool isHome) :
|
||||
GxsFeedItem(parent, feedId, post.mMeta.mGroupId, post.mMeta.mMsgId, isHome, rsPosted, false, false),
|
||||
PostedItem::PostedItem(FeedHolder *feedHolder, uint32_t feedId, const RsPostedPost &post, bool isHome) :
|
||||
GxsFeedItem(feedHolder, feedId, post.mMeta.mGroupId, post.mMeta.mMsgId, isHome, rsPosted, false, false),
|
||||
mPost(post)
|
||||
{
|
||||
setup();
|
||||
|
@ -115,7 +115,7 @@ void PostedItem::setContent(const RsPostedPost &post)
|
|||
// FIX THIS UP LATER.
|
||||
notes->setText(QString::fromUtf8(post.mNotes.c_str()));
|
||||
// differences between Feed or Top of Comment.
|
||||
if (mParent)
|
||||
if (mFeedHolder)
|
||||
{
|
||||
// feed.
|
||||
frame_notes->hide();
|
||||
|
@ -218,9 +218,10 @@ void PostedItem::loadComments()
|
|||
{
|
||||
std::cerr << "PostedItem::loadComments()";
|
||||
std::cerr << std::endl;
|
||||
if (mParent)
|
||||
|
||||
if (mFeedHolder)
|
||||
{
|
||||
QString title = QString::fromUtf8(mPost.mMeta.mMsgName.c_str());
|
||||
mParent->openComments(0, mPost.mMeta.mGroupId, mPost.mMeta.mMsgId, title);
|
||||
mFeedHolder->openComments(0, mPost.mMeta.mGroupId, mPost.mMeta.mMsgId, title);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue