mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-05-13 11:32:48 -04:00
Removed buttons to create a new identity
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@7789 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
810a5cacc0
commit
417f66a566
20 changed files with 73 additions and 360 deletions
|
@ -26,7 +26,6 @@
|
|||
#include "ui_PostedCreatePostDialog.h"
|
||||
|
||||
#include "util/TokenQueue.h"
|
||||
#include "gui/Identity/IdDialog.h"
|
||||
|
||||
#include <iostream>
|
||||
|
||||
|
@ -39,7 +38,6 @@ PostedCreatePostDialog::PostedCreatePostDialog(TokenQueue* tokenQ, RsPosted *pos
|
|||
|
||||
connect(ui->submitButton, SIGNAL(clicked()), this, SLOT(createPost()));
|
||||
connect(ui->buttonBox, SIGNAL(rejected()), this, SLOT(close()));
|
||||
connect(ui->toolButton_NewId, SIGNAL(clicked()), this, SLOT(createNewGxsId()));
|
||||
|
||||
ui->headerFrame->setHeaderImage(QPixmap(":/images/posted_64.png"));
|
||||
ui->headerFrame->setHeaderText(tr("Submit a new Post"));
|
||||
|
@ -58,20 +56,20 @@ PostedCreatePostDialog::~PostedCreatePostDialog()
|
|||
void PostedCreatePostDialog::createPost()
|
||||
{
|
||||
RsGxsId authorId;
|
||||
switch (ui->idChooser->getChosenId(authorId)) {
|
||||
case GxsIdChooser::KnowId:
|
||||
case GxsIdChooser::UnKnowId:
|
||||
break;
|
||||
case GxsIdChooser::NoId:
|
||||
case GxsIdChooser::None:
|
||||
default:
|
||||
switch (ui->idChooser->getChosenId(authorId)) {
|
||||
case GxsIdChooser::KnowId:
|
||||
case GxsIdChooser::UnKnowId:
|
||||
break;
|
||||
case GxsIdChooser::NoId:
|
||||
case GxsIdChooser::None:
|
||||
default:
|
||||
std::cerr << "PostedCreatePostDialog::createPost() ERROR GETTING AuthorId!, Post Failed";
|
||||
std::cerr << std::endl;
|
||||
|
||||
QMessageBox::warning(this, tr("RetroShare"),tr("Please create or choose a Signing Id first"), QMessageBox::Ok, QMessageBox::Ok);
|
||||
|
||||
return;
|
||||
}//switch (ui->idChooser->getChosenId(authorId))
|
||||
}//switch (ui->idChooser->getChosenId(authorId))
|
||||
|
||||
RsPostedPost post;
|
||||
post.mMeta.mGroupId = mGrpId;
|
||||
|
@ -84,7 +82,7 @@ void PostedCreatePostDialog::createPost()
|
|||
/* error message */
|
||||
QMessageBox::warning(this, "RetroShare", tr("Please add a Title"), QMessageBox::Ok, QMessageBox::Ok);
|
||||
return; //Don't add a empty title!!
|
||||
}//if(ui->titleEdit->text().isEmpty())
|
||||
}//if(ui->titleEdit->text().isEmpty())
|
||||
|
||||
uint32_t token;
|
||||
mPosted->createPost(token, post);
|
||||
|
@ -92,11 +90,3 @@ void PostedCreatePostDialog::createPost()
|
|||
|
||||
accept();
|
||||
}
|
||||
|
||||
void PostedCreatePostDialog::createNewGxsId()
|
||||
{
|
||||
IdEditDialog dlg(this);
|
||||
dlg.setupNewId(false);
|
||||
dlg.exec();
|
||||
ui->idChooser->setDefaultId(dlg.getLastIdName());
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue