1/4 convertion of GxsGroupFrameDialog to blocking API

This commit is contained in:
csoler 2020-03-21 15:25:34 +01:00
parent 1a9ac16546
commit 2387150f64
No known key found for this signature in database
GPG key ID: 7BCA522266C0804C
18 changed files with 251 additions and 131 deletions

View file

@ -45,11 +45,10 @@ class RsGxsChannels;
extern RsGxsChannels* rsGxsChannels;
struct RsGxsChannelGroup : RsSerializable
struct RsGxsChannelGroup : RsSerializable, RsGxsGenericGroupData
{
RsGxsChannelGroup() : mAutoDownload(false) {}
RsGroupMetaData mMeta;
std::string mDescription;
RsGxsImage mImage;

View file

@ -54,11 +54,8 @@ static const uint32_t RS_GXS_FORUM_MSG_FLAGS_MODERATED = 0x00000001;
#define IS_FORUM_MSG_MODERATION(flags) (flags & RS_GXS_FORUM_MSG_FLAGS_MODERATED)
struct RsGxsForumGroup : RsSerializable
struct RsGxsForumGroup : RsSerializable, RsGxsGenericGroupData
{
/** Forum GXS metadata */
RsGroupMetaData mMeta;
/** @brief Forum desciption */
std::string mDescription;

View file

@ -118,8 +118,15 @@ struct RsGroupMetaData : RsSerializable
}
};
// This is the parent class of all interface-level GXS group data. Derived classes
// will include service-specific information, such as icon, description, etc
struct RsGxsGenericGroupData
{
virtual ~RsGxsGenericGroupData() = default; // making the type polymorphic
RsGroupMetaData mMeta;
};
struct RsMsgMetaData : RsSerializable
{

View file

@ -40,9 +40,8 @@ class RsPosted;
*/
extern RsPosted* rsPosted;
struct RsPostedGroup
struct RsPostedGroup: RsGxsGenericGroupData
{
RsGroupMetaData mMeta;
std::string mDescription;
RsGxsImage mGroupImage;
};
@ -150,6 +149,8 @@ public:
const std::list<RsGxsGroupId>& boardsIds,
std::vector<RsPostedGroup>& boardsInfo ) = 0;
virtual bool getBoardsSummaries(std::list<RsGroupMetaData>& groupInfo) =0;
virtual bool getBoardContent(
const RsGxsGroupId& boardId,
const std::set<RsGxsMessageId>& contentsIds,