mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-12-25 15:39:27 -05:00
Added to display for Attached Audio,Video and Archive files a default icon in Private Chat
git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3431 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
parent
92f5d37712
commit
a26547effb
@ -1081,13 +1081,37 @@ void PopupChatDialog::fileHashingFinished(AttachFileItem* file)
|
||||
}
|
||||
|
||||
QString message;
|
||||
QString ext = QFileInfo(QString::fromStdString(file->FileName())).suffix();
|
||||
|
||||
if(file->getPicFlag()==1){
|
||||
message+="<img src=\"file:///";
|
||||
message+=file->FilePath().c_str();
|
||||
message+="\" width=\"100\" height=\"100\">";
|
||||
message+="<br>";
|
||||
}
|
||||
}
|
||||
else if (ext == "ogg" || ext == "mp3" || ext == "MP3" || ext == "mp1" || ext == "mp2" || ext == "wav" || ext == "wma")
|
||||
{
|
||||
message+="<img src=\":/images/audio-x-monkey.png";
|
||||
message+="\" width=\"48\" height=\"48\">";
|
||||
message+="<br>";
|
||||
}
|
||||
else if (ext == "avi" || ext == "AVI" || ext == "mpg" || ext == "mpeg" || ext == "wmv" || ext == "ogm"
|
||||
|| ext == "mkv" || ext == "mp4" || ext == "flv" || ext == "mov"
|
||||
|| ext == "vob" || ext == "qt" || ext == "rm" || ext == "3gp")
|
||||
{
|
||||
message+="<img src=\":/images/video-x-generic.png";
|
||||
message+="\" width=\"48\" height=\"48\">";
|
||||
message+="<br>";
|
||||
}
|
||||
else if (ext == "tar" || ext == "bz2" || ext == "zip" || ext == "gz" || ext == "7z"
|
||||
|| ext == "rar" || ext == "rpm" || ext == "deb")
|
||||
{
|
||||
message+="<img src=\":/images/application-x-rar.png";
|
||||
message+="\" width=\"48\" height=\"48\">";
|
||||
message+="<br>";
|
||||
}
|
||||
|
||||
|
||||
|
||||
message+= RetroShareLink(QString::fromStdString(file->FileName()),file->FileSize(),QString::fromStdString(file->FileHash())).toHtmlSize();
|
||||
|
||||
|
@ -1,6 +1,9 @@
|
||||
<RCC>
|
||||
<qresource prefix="/" >
|
||||
<file>images/attach.png</file>
|
||||
<file>images/audio-x-monkey.png</file>
|
||||
<file>images/video-x-generic.png</file>
|
||||
<file>images/application-x-rar.png</file>
|
||||
<file>images/pgp.png</file>
|
||||
<file>images/rs_wizard.png</file>
|
||||
<file>images/about.png</file>
|
||||
|
BIN
retroshare-gui/src/gui/images/application-x-cd-image.png
Normal file
BIN
retroshare-gui/src/gui/images/application-x-cd-image.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.6 KiB |
BIN
retroshare-gui/src/gui/images/application-x-rar.png
Normal file
BIN
retroshare-gui/src/gui/images/application-x-rar.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 3.2 KiB |
BIN
retroshare-gui/src/gui/images/audio-x-monkey.png
Normal file
BIN
retroshare-gui/src/gui/images/audio-x-monkey.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.4 KiB |
BIN
retroshare-gui/src/gui/images/video-x-generic.png
Normal file
BIN
retroshare-gui/src/gui/images/video-x-generic.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.5 KiB |
Loading…
Reference in New Issue
Block a user