mirror of
https://github.com/RetroShare/RetroShare.git
synced 2025-06-16 10:30:01 -04:00
FeedReader:
- Added favicon git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@6069 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
edd8a2c0ec
commit
3df3850655
12 changed files with 177 additions and 96 deletions
|
@ -53,6 +53,18 @@ FeedReaderFeedItem::FeedReaderFeedItem(RsFeedReader *feedReader, FeedReaderNotif
|
|||
mFeedId = feedInfo.feedId;
|
||||
mMsgId = msgInfo.msgId;
|
||||
|
||||
if (feedInfo.icon.empty()) {
|
||||
ui->feedIconLabel->hide();
|
||||
} else {
|
||||
/* use icon from feed */
|
||||
QPixmap pixmap;
|
||||
if (pixmap.loadFromData(QByteArray::fromBase64(feedInfo.icon.c_str()))) {
|
||||
ui->feedIconLabel->setPixmap(pixmap.scaled(16, 16, Qt::IgnoreAspectRatio, Qt::SmoothTransformation));
|
||||
} else {
|
||||
ui->feedIconLabel->hide();
|
||||
}
|
||||
}
|
||||
|
||||
ui->titleLabel->setText(QString::fromUtf8(feedInfo.name.c_str()));
|
||||
ui->msgTitleLabel->setText(QString::fromUtf8(msgInfo.title.c_str()));
|
||||
ui->descriptionLabel->setText(QString::fromUtf8(msgInfo.description.c_str()));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue