mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-15 02:44:20 -05:00
added display Blog logo's for BlogsDialog, and stylesheet color switch when its own, subscribed or public Blogs
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@2929 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
105e617596
commit
ab0bc5ccf9
@ -40,6 +40,8 @@
|
|||||||
#include "gui/ChanGroupDelegate.h"
|
#include "gui/ChanGroupDelegate.h"
|
||||||
#include "gui/GeneralMsgDialog.h"
|
#include "gui/GeneralMsgDialog.h"
|
||||||
|
|
||||||
|
#define BLOG_DEFAULT_IMAGE ":/images/hi64-app-kblogger.png"
|
||||||
|
|
||||||
|
|
||||||
/** Constructor */
|
/** Constructor */
|
||||||
BlogsDialog::BlogsDialog(QWidget *parent)
|
BlogsDialog::BlogsDialog(QWidget *parent)
|
||||||
@ -506,6 +508,16 @@ void BlogsDialog::updateBlogMsgs()
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(bi.pngImageLen != 0){
|
||||||
|
|
||||||
|
QPixmap blogImage;
|
||||||
|
blogImage.loadFromData(bi.pngChanImage, bi.pngImageLen, "PNG");
|
||||||
|
iconLabel->setPixmap(blogImage);
|
||||||
|
}else{
|
||||||
|
QPixmap defaultImage(BLOG_DEFAULT_IMAGE);
|
||||||
|
iconLabel->setPixmap(defaultImage);
|
||||||
|
}
|
||||||
|
|
||||||
iconLabel->setEnabled(true);
|
iconLabel->setEnabled(true);
|
||||||
|
|
||||||
/* set textcolor for Blog name */
|
/* set textcolor for Blog name */
|
||||||
@ -521,16 +533,20 @@ void BlogsDialog::updateBlogMsgs()
|
|||||||
{
|
{
|
||||||
subscribeButton->setEnabled(false);
|
subscribeButton->setEnabled(false);
|
||||||
unsubscribeButton->setEnabled(true);
|
unsubscribeButton->setEnabled(true);
|
||||||
|
frame->setStyleSheet("QFrame#frame{ border: 2px solid #6E777F;border-radius: 10px;background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1,stop:0 #515D66, stop:1 #75818A); }");
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
subscribeButton->setEnabled(true);
|
subscribeButton->setEnabled(true);
|
||||||
unsubscribeButton->setEnabled(false);
|
unsubscribeButton->setEnabled(false);
|
||||||
|
frame->setStyleSheet("QFrame#frame{ border: 2px solid #6ACEFF;border-radius: 10px;background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1,stop:0 #0076B1, stop:1 #12A3EB); }");
|
||||||
}
|
}
|
||||||
|
|
||||||
if (bi.blogFlags & RS_DISTRIB_PUBLISH)
|
if (bi.blogFlags & RS_DISTRIB_PUBLISH)
|
||||||
{
|
{
|
||||||
postButton->setEnabled(true);
|
postButton->setEnabled(true);
|
||||||
|
frame->setStyleSheet("QFrame#frame{ border: 2px solid #6ACEFF;border-radius: 10px;background-color: qlineargradient(x1:0, y1:0, x2:0, y2:1,stop:0 #0076B1, stop:1 #12A3EB); }");
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user