mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-10-01 02:35:48 -04:00
Added two new images from defnax to SecurityItem for SEC_TYPE_CONNECT_ATTEMPT and SEC_TYPE_UNKNOWN_IN.
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@5060 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
b32fddb3e0
commit
fae86aff3b
@ -39,6 +39,7 @@ AvatarWidget::AvatarWidget(QWidget *parent) :
|
||||
|
||||
mFlag.isOwnId = false;
|
||||
mFlag.isGpg = false;
|
||||
defaultAvatar = ":/images/no_avatar_background.png";
|
||||
|
||||
setFrameType(NO_FRAME);
|
||||
|
||||
@ -137,6 +138,12 @@ void AvatarWidget::setOwnId()
|
||||
setId(rsPeers->getOwnId(), false);
|
||||
}
|
||||
|
||||
void AvatarWidget::setDefaultAvatar(const QString &avatar)
|
||||
{
|
||||
defaultAvatar = avatar;
|
||||
updateAvatar(QString::fromStdString(mId));
|
||||
}
|
||||
|
||||
void AvatarWidget::refreshStatus()
|
||||
{
|
||||
switch (mFrameType) {
|
||||
@ -226,8 +233,6 @@ void AvatarWidget::updateStatus(const QString peerId, int status)
|
||||
|
||||
void AvatarWidget::updateAvatar(const QString &peerId)
|
||||
{
|
||||
QString defaultAvatar = ":/images/no_avatar_background.png";
|
||||
|
||||
if (mId.empty()) {
|
||||
QPixmap avatar(defaultAvatar);
|
||||
ui->avatar->setPixmap(avatar);
|
||||
|
@ -46,6 +46,7 @@ public:
|
||||
void setFrameType(FrameType type);
|
||||
void setId(const std::string& id, bool isGpg);
|
||||
void setOwnId();
|
||||
void setDefaultAvatar(const QString &avatar);
|
||||
|
||||
protected:
|
||||
void resizeEvent(QResizeEvent *event);
|
||||
@ -59,6 +60,7 @@ private slots:
|
||||
private:
|
||||
void refreshStatus();
|
||||
|
||||
QString defaultAvatar;
|
||||
Ui::AvatarWidget *ui;
|
||||
|
||||
std::string mId;
|
||||
|
@ -114,12 +114,14 @@ void SecurityItem::updateItemStatic()
|
||||
{
|
||||
case SEC_TYPE_CONNECT_ATTEMPT:
|
||||
title = tr("Connect Attempt");
|
||||
avatar->setDefaultAvatar(":images/user/user_request48.png");
|
||||
break;
|
||||
case SEC_TYPE_AUTH_DENIED:
|
||||
title = tr("Not Yet Friends");
|
||||
break;
|
||||
case SEC_TYPE_UNKNOWN_IN:
|
||||
title = tr("Unknown (Incoming) Connect Attempt");
|
||||
avatar->setDefaultAvatar(":images/user/user_request_unknown48.png");
|
||||
break;
|
||||
case SEC_TYPE_UNKNOWN_OUT:
|
||||
title = tr("Unknown (Outgoing) Connect Attempt");
|
||||
|
@ -464,6 +464,8 @@
|
||||
<file>images/user/agt_forum128.png</file>
|
||||
<file>images/user/group16.png</file>
|
||||
<file>images/user/group24.png</file>
|
||||
<file>images/user/user_request48.png</file>
|
||||
<file>images/user/user_request_unknown48.png</file>
|
||||
<file>images/up.png</file>
|
||||
<file>images/up0down0.png</file>
|
||||
<file>images/up0down1.png</file>
|
||||
|
BIN
retroshare-gui/src/gui/images/user/user_request_unknown48.png
Normal file
BIN
retroshare-gui/src/gui/images/user/user_request_unknown48.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.4 KiB |
Loading…
Reference in New Issue
Block a user