mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-21 05:44:29 -05:00
moved the Status icons to the correct place
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@2043 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
5349ab101a
commit
7e29afbbd9
@ -404,39 +404,50 @@ void PeersDialog::insertPeers()
|
||||
/* change color and icon */
|
||||
int i;
|
||||
if (sslDetail.state & RS_PEER_STATE_CONNECTED) {
|
||||
sslItem -> setIcon(0,(QIcon(IMAGE_ONLINE)));
|
||||
gpg_item -> setIcon(0,(QIcon(IMAGE_ONLINE)));
|
||||
gpg_item -> setText(1, tr("Online"));
|
||||
sslItem -> setIcon(0,(QIcon(":/images/connect_established.png")));
|
||||
QFont font;
|
||||
font.setBold(true);
|
||||
for(i = 0; i < 3; i++) {
|
||||
sslItem -> setTextColor(i,(Qt::darkBlue));
|
||||
gpg_item -> setTextColor(i,(Qt::darkBlue));
|
||||
gpg_item -> setFont(i,font);
|
||||
sslItem -> setFont(i,font);
|
||||
}
|
||||
} else if (sslDetail.state & RS_PEER_STATE_UNREACHABLE) {
|
||||
sslItem -> setIcon(0,(QIcon(IMAGE_UNREACHABLE)));
|
||||
gpg_item -> setIcon(0,(QIcon(IMAGE_UNREACHABLE)));
|
||||
gpg_item -> setText(1, tr("Unreachable"));
|
||||
QFont font;
|
||||
font.setBold(false);
|
||||
for(i = 0; i < 3; i++) {
|
||||
sslItem -> setTextColor(i,(Qt::darkRed));
|
||||
gpg_item -> setTextColor(i,(Qt::darkRed));
|
||||
gpg_item -> setFont(i,font);
|
||||
sslItem -> setFont(i,font);
|
||||
}
|
||||
} else if (sslDetail.state & RS_PEER_STATE_ONLINE) {
|
||||
/* bright green */
|
||||
sslItem -> setIcon(0,(QIcon(IMAGE_AVAIBLE)));
|
||||
gpg_item -> setIcon(0,(QIcon(IMAGE_AVAIBLE)));
|
||||
gpg_item -> setText(1, tr("Avaible"));
|
||||
QFont font;
|
||||
font.setBold(true);
|
||||
for(i = 0; i < 3; i++) {
|
||||
sslItem -> setTextColor(i,(Qt::darkCyan));
|
||||
gpg_item -> setTextColor(i,(Qt::darkCyan));
|
||||
gpg_item -> setFont(i,font);
|
||||
sslItem -> setFont(i,font);
|
||||
}
|
||||
} else {
|
||||
if (time(NULL) - sslDetail.lastConnect < 3600) {
|
||||
sslItem -> setIcon(0,(QIcon(IMAGE_OFFLINE)));
|
||||
gpg_item -> setIcon(0,(QIcon(IMAGE_OFFLINE)));
|
||||
gpg_item -> setText(1, tr("Offline"));
|
||||
} else {
|
||||
sslItem -> setIcon(0,(QIcon(IMAGE_OFFLINE2)));
|
||||
gpg_item -> setIcon(0,(QIcon(IMAGE_OFFLINE2)));
|
||||
gpg_item -> setText(1, tr("Offline"));
|
||||
}
|
||||
QFont font;
|
||||
font.setBold(false);
|
||||
for(i = 0; i < 3; i++) {
|
||||
gpg_item -> setTextColor(i,(Qt::black));
|
||||
gpg_item -> setFont(i,font);
|
||||
sslItem -> setTextColor(i,(Qt::black));
|
||||
sslItem -> setFont(i,font);
|
||||
}
|
||||
|
@ -12,6 +12,7 @@
|
||||
<file>images/btn_26_hover.png</file>
|
||||
<file>images/btn_27.png</file>
|
||||
<file>images/btn_27_hover.png</file>
|
||||
<file>images/connect_established.png</file>
|
||||
<file>images/feedback_arrow.png</file>
|
||||
<file>images/feedback_arrow_hover.png</file>
|
||||
<file>images/feedback-bar-background.png</file>
|
||||
|
BIN
retroshare-gui/src/gui/images/connect_creating.png
Normal file
BIN
retroshare-gui/src/gui/images/connect_creating.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 986 B |
BIN
retroshare-gui/src/gui/images/connect_established.png
Normal file
BIN
retroshare-gui/src/gui/images/connect_established.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 818 B |
BIN
retroshare-gui/src/gui/images/connect_no.png
Normal file
BIN
retroshare-gui/src/gui/images/connect_no.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 757 B |
Loading…
Reference in New Issue
Block a user