diff --git a/retroshare-gui/src/gui/Posted/PostedCreatePostDialog.cpp b/retroshare-gui/src/gui/Posted/PostedCreatePostDialog.cpp
index 07e6c6d8d..96e74ab0d 100644
--- a/retroshare-gui/src/gui/Posted/PostedCreatePostDialog.cpp
+++ b/retroshare-gui/src/gui/Posted/PostedCreatePostDialog.cpp
@@ -37,11 +37,11 @@ PostedCreatePostDialog::PostedCreatePostDialog(TokenQueue* tokenQ, RsPosted *pos
{
ui->setupUi(this);
- connect(ui->buttonBox, SIGNAL(accepted()), this, SLOT(createPost()));
+ connect(ui->submitButton, SIGNAL(clicked()), this, SLOT(createPost()));
connect(ui->buttonBox, SIGNAL(rejected()), this, SLOT(close()));
ui->headerFrame->setHeaderImage(QPixmap(":/images/posted_64.png"));
- ui->headerFrame->setHeaderText(tr("Create Post"));
+ ui->headerFrame->setHeaderText(tr("Submit a new Post"));
/* fill in the available OwnIds for signing */
ui->idChooser->loadIds(IDCHOOSER_ID_REQUIRED, "");
@@ -71,6 +71,12 @@ void PostedCreatePostDialog::createPost()
post.mNotes = std::string(ui->notesTextEdit->toPlainText().toUtf8());
post.mMeta.mMsgName = std::string(ui->titleEdit->text().toUtf8());
post.mMeta.mAuthorId = authorId;
+
+ if(ui->titleEdit->text().isEmpty()) {
+ /* error message */
+ QMessageBox::warning(this, "RetroShare", tr("Please add a Title"), QMessageBox::Ok, QMessageBox::Ok);
+ return; //Don't add a empty title!!
+ }
uint32_t token;
mPosted->createPost(token, post);
diff --git a/retroshare-gui/src/gui/Posted/PostedCreatePostDialog.ui b/retroshare-gui/src/gui/Posted/PostedCreatePostDialog.ui
index 0eb03bb94..643c3efeb 100644
--- a/retroshare-gui/src/gui/Posted/PostedCreatePostDialog.ui
+++ b/retroshare-gui/src/gui/Posted/PostedCreatePostDialog.ui
@@ -6,12 +6,12 @@
0
0
- 593
+ 575
371
- Create Post
+ Submit Post
@@ -39,7 +39,93 @@
QFrame::Raised
- -
+
-
+
+
+
+
+
+
+
+ 255
+ 255
+ 255
+
+
+
+
+
+
+ 246
+ 230
+ 159
+
+
+
+
+
+
+
+
+ 255
+ 255
+ 255
+
+
+
+
+
+
+ 246
+ 230
+ 159
+
+
+
+
+
+
+
+
+ 246
+ 230
+ 159
+
+
+
+
+
+
+ 246
+ 230
+ 159
+
+
+
+
+
+
+
+
+ Tahoma
+ 11
+
+
+
+ true
+
+
+ QFrame::Box
+
+
+ You are submitting a link. The key to a successful submission is interesting content and a descriptive title.
+
+
+ true
+
+
+
+ -
-
@@ -71,7 +157,7 @@ p, li { white-space: pre-wrap; }
- -
+
-
-
@@ -101,7 +187,7 @@ p, li { white-space: pre-wrap; }
- -
+
-
-
@@ -115,13 +201,39 @@ p, li { white-space: pre-wrap; }
- -
+
-
+
+
+ Qt::Horizontal
+
+
+
+ 40
+ 20
+
+
+
+
+ -
+
+
+ Submit
+
+
+
+ -
+
+
+ 0
+ 0
+
+
Qt::Horizontal
- QDialogButtonBox::Cancel|QDialogButtonBox::Ok
+ QDialogButtonBox::Cancel
diff --git a/retroshare-gui/src/gui/Posted/PostedItem.cpp b/retroshare-gui/src/gui/Posted/PostedItem.cpp
index 3543e4359..58cf55dc8 100644
--- a/retroshare-gui/src/gui/Posted/PostedItem.cpp
+++ b/retroshare-gui/src/gui/Posted/PostedItem.cpp
@@ -88,10 +88,10 @@ void PostedItem::setContent(const RsPostedPost &post)
dateLabel->setText(timestamp);
fromLabel->setId(post.mMeta.mAuthorId);
titleLabel->setText("" +
+ ">" +
QString::fromStdString(post.mMeta.mMsgName) + "");
siteLabel->setText("" +
+ ">" +
QString::fromStdString(post.mLink) + "");
//QString score = "Hot" + QString::number(post.mHotScore);
diff --git a/retroshare-gui/src/gui/Posted/PostedItem.ui b/retroshare-gui/src/gui/Posted/PostedItem.ui
index 91357a44d..ee232a005 100644
--- a/retroshare-gui/src/gui/Posted/PostedItem.ui
+++ b/retroshare-gui/src/gui/Posted/PostedItem.ui
@@ -6,8 +6,8 @@
0
0
- 754
- 129
+ 667
+ 119
@@ -108,7 +108,7 @@ border-radius: 10px}
-
-
+
0
0
@@ -157,7 +157,7 @@ border-radius: 10px}
- Date
+ Submitted
diff --git a/retroshare-gui/src/gui/Posted/PostedListDialog.cpp b/retroshare-gui/src/gui/Posted/PostedListDialog.cpp
index e72c05fb1..137c8dae7 100644
--- a/retroshare-gui/src/gui/Posted/PostedListDialog.cpp
+++ b/retroshare-gui/src/gui/Posted/PostedListDialog.cpp
@@ -72,7 +72,7 @@ PostedListDialog::PostedListDialog(QWidget *parent)
connect(ui.nextButton, SIGNAL(clicked()), this, SLOT(showNext()));
connect(ui.prevButton, SIGNAL(clicked()), this, SLOT(showPrev()));
- connect( ui.pushButton, SIGNAL(clicked()), this, SLOT(todo()));
+ connect(ui.pushButton, SIGNAL(clicked()), this, SLOT(todo()));
// default sort method.
mSortMethod = RsPosted::HotRankType;
@@ -179,7 +179,7 @@ void PostedListDialog::groupListCustomPopupMenu(QPoint /*point*/)
//bool isPublisher = IS_GROUP_PUBLISHER(subscribeFlags);
bool isSubscribed = IS_GROUP_SUBSCRIBED(subscribeFlags);
- QAction *action = contextMnu.addAction(QIcon(IMAGE_MESSAGE), tr("Create Post"), this, SLOT(newPost()));
+ QAction *action = contextMnu.addAction(QIcon(IMAGE_MESSAGE), tr("Submit a new Post"), this, SLOT(newPost()));
action->setEnabled(isSubscribed);
action = contextMnu.addAction(QIcon(IMAGE_SUBSCRIBE), tr("Subscribe"), this, SLOT(subscribeTopic()));
action->setEnabled(!isSubscribed);
@@ -1002,8 +1002,8 @@ void PostedListDialog::todo()
{
QMessageBox::information(this, "Todo",
"Open points:"
- "- Subreddits/tags support"
- "
- Edit Groups"
+ "
- Subreddits/tag to posts support"
+ "
- Edit Topics"
"
- Picture Support"
"
");
-}
\ No newline at end of file
+}
diff --git a/retroshare-gui/src/gui/Posted/PostedListDialog.h b/retroshare-gui/src/gui/Posted/PostedListDialog.h
index ecf28614c..7daa2b3a6 100644
--- a/retroshare-gui/src/gui/Posted/PostedListDialog.h
+++ b/retroshare-gui/src/gui/Posted/PostedListDialog.h
@@ -78,6 +78,8 @@ private slots:
void showNext();
void showPrev();
+
+ void todo();
protected:
virtual void updateDisplay(bool complete);
@@ -131,7 +133,6 @@ private:
void loadRequest(const TokenQueue *queue, const TokenRequest &req);
- void todo();
private:
QTreeWidgetItem *yourTopics;
diff --git a/retroshare-gui/src/gui/Posted/PostedListDialog.ui b/retroshare-gui/src/gui/Posted/PostedListDialog.ui
index be6391515..cc205cc9b 100644
--- a/retroshare-gui/src/gui/Posted/PostedListDialog.ui
+++ b/retroshare-gui/src/gui/Posted/PostedListDialog.ui
@@ -59,7 +59,7 @@
-
- Create Post
+ Submit a new Post
@@ -263,7 +263,7 @@
0
0
- 710
+ 711
16
diff --git a/retroshare-gui/src/gui/qss/stylesheet/Standard.qss b/retroshare-gui/src/gui/qss/stylesheet/Standard.qss
index e310306a7..a30183ca2 100644
--- a/retroshare-gui/src/gui/qss/stylesheet/Standard.qss
+++ b/retroshare-gui/src/gui/qss/stylesheet/Standard.qss
@@ -540,3 +540,11 @@ MessageWidget QFrame#decryptFrame {
background: #CCFFCC;
background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1, stop:0 #CCFFCC, stop:1 #AAFFAA);
}
+/* Posted Links */
+
+PostedCreatePostDialog QLabel#info_label {
+ border: 1px solid #DCDC41;
+ border-radius: 6px;
+ background: #FFFFD7;
+ background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1, stop:0 #FFFFD7, stop:1 #FFFFB2);
+}