mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 22:54:01 +02:00
Added filename as fallback for audio files while export chat history.
Fixed #28920.
This commit is contained in:
parent
7cf832a2f4
commit
c4b37950a9
1 changed files with 6 additions and 4 deletions
|
@ -2323,10 +2323,12 @@ MediaData HtmlWriter::Wrap::prepareMediaData(
|
||||||
} else if (data.isVideoFile) {
|
} else if (data.isVideoFile) {
|
||||||
// At least try to pushVideoFileMedia.
|
// At least try to pushVideoFileMedia.
|
||||||
} else if (data.isAudioFile) {
|
} else if (data.isAudioFile) {
|
||||||
result.title = (data.songPerformer.isEmpty()
|
result.title = (!data.songPerformer.isEmpty()
|
||||||
|| data.songTitle.isEmpty())
|
&& !data.songTitle.isEmpty())
|
||||||
? QByteArray("Audio file")
|
? (data.songPerformer + " \xe2\x80\x93 " + data.songTitle)
|
||||||
: data.songPerformer + " \xe2\x80\x93 " + data.songTitle;
|
: !data.name.isEmpty()
|
||||||
|
? data.name
|
||||||
|
: QByteArray("Audio file");
|
||||||
result.status = FormatDuration(data.duration);
|
result.status = FormatDuration(data.duration);
|
||||||
if (!hasFile) {
|
if (!hasFile) {
|
||||||
result.status += ", " + FormatFileSize(data.file.size);
|
result.status += ", " + FormatFileSize(data.file.size);
|
||||||
|
|
Loading…
Add table
Reference in a new issue