Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-client-qt
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
savoirfairelinux
jami-client-qt
Commits
a891b263
Commit
a891b263
authored
2 years ago
by
Nicolas Vengeon
Committed by
Andreas Traczyk
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Chat-view: animated image messages aren't animated
Change-Id: I98e8307c1d44a983939a096e2171ff8cf12f4220 GitLab:
#860
parent
72315f91
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
src/app/messagesadapter.cpp
+3
-2
3 additions, 2 deletions
src/app/messagesadapter.cpp
with
3 additions
and
2 deletions
src/app/messagesadapter.cpp
+
3
−
2
View file @
a891b263
...
...
@@ -589,6 +589,9 @@ MessagesAdapter::isLocalImage(const QString& mimename)
[
fileFormat
](
QByteArray
format
)
{
return
format
==
fileFormat
;
});
if
(
*
iterator
==
"gif"
)
{
return
{{
"isAnimatedImage"
,
true
}};
}
return
{{
"isImage"
,
iterator
!=
supportedFormats
.
end
()}};
}
return
{{
"isImage"
,
false
}};
...
...
@@ -610,7 +613,6 @@ MessagesAdapter::getMediaInfo(const QString& msg)
return
fileInfo
;
}
static
const
QRegExp
vPattern
(
"(video/)(avi|mov|webm|webp|rmvb)$"
,
Qt
::
CaseInsensitive
);
auto
match
=
vPattern
.
indexIn
(
mime
.
name
());
QString
type
=
vPattern
.
capturedTexts
().
size
()
==
3
?
vPattern
.
capturedTexts
()[
1
]
:
""
;
if
(
!
type
.
isEmpty
())
{
return
{
...
...
@@ -619,7 +621,6 @@ MessagesAdapter::getMediaInfo(const QString& msg)
};
}
else
{
static
const
QRegExp
aPattern
(
"(audio/)(ogg|flac|wav|mpeg|mp3)$"
,
Qt
::
CaseInsensitive
);
match
=
aPattern
.
indexIn
(
mime
.
name
());
type
=
aPattern
.
capturedTexts
().
size
()
==
3
?
aPattern
.
capturedTexts
()[
1
]
:
""
;
if
(
!
type
.
isEmpty
())
{
return
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment