A stab at progressing posted, got post creation working and parameterised GxsGroupDialog for creating "create <service>" header for all gxs services

git-svn-id: http://svn.code.sf.net/p/retroshare/code/branches/v0.5-gxs-b1@5837 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
chrisparker126 2012-11-17 21:43:21 +00:00
parent ae5cbecaba
commit 92f1673729
13 changed files with 172 additions and 268 deletions

View file

@ -1,17 +1,24 @@
#include "PostedCreatePostDialog.h"
#include "ui_PostedCreatePostDialog.h"
PostedCreatePostDialog::PostedCreatePostDialog(TokenQueue* tokenQ, RsPosted *posted, QWidget *parent):
QDialog(parent), mTokenQueue(tokenQ), mPosted(posted),
PostedCreatePostDialog::PostedCreatePostDialog(TokenQueue* tokenQ, RsPosted *posted, const RsGxsGroupId& grpId, QWidget *parent):
QDialog(parent), mTokenQueue(tokenQ), mPosted(posted), mGrpId(grpId),
ui(new Ui::PostedCreatePostDialog)
{
ui->setupUi(this);
connect(this, SIGNAL(accepted()), this, SLOT(createPost()));
}
void PostedCreatePostDialog::createPost()
{
RsPostedPost post;
post.mMeta.mGroupId = mGrpId;
post.mLink = ui->linkEdit->text().toStdString();
post.mNotes = ui->notesTextEdit->toPlainText().toStdString();
uint32_t token;
mPosted->submitPost(token, post);
mTokenQueue->queueRequest(token, TOKENREQ_MSGINFO, RS_TOKREQ_ANSTYPE_ACK, 0);
close();
}