Fix broken APNG (#153)

* Remove explicit APNG check

* Update aocharmovie.h
This commit is contained in:
oldmud0 2020-05-19 18:49:29 -05:00 committed by GitHub
parent f052a7f2ea
commit 4af7bc5fff
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 7 deletions

View File

@ -65,7 +65,6 @@ private:
bool m_flipped = false;
bool play_once = true;
bool apng = false;
signals:
void done();

View File

@ -19,8 +19,6 @@ AOCharMovie::AOCharMovie(QWidget *p_parent, AOApplication *p_ao_app)
void AOCharMovie::play(QString p_char, QString p_emote, QString emote_prefix)
{
apng = false;
QString original_path =
ao_app->get_character_path(p_char, emote_prefix + p_emote + ".gif");
QString alt_path =
@ -35,10 +33,8 @@ void AOCharMovie::play(QString p_char, QString p_emote, QString emote_prefix)
QString gif_path;
current_emote = emote_prefix + p_emote;
current_char = p_char;
if (file_exists(apng_path)) {
if (file_exists(apng_path))
gif_path = apng_path;
apng = true;
}
else if (file_exists(original_path))
gif_path = original_path;
else if (file_exists(alt_path))
@ -184,7 +180,7 @@ void AOCharMovie::movie_ticker()
if (m_movie->frameCount() == 0) {
return;
}
else if (!apng) {
else {
ticker->start(m_movie->nextFrameDelay());
}
}