Qt: Minor GIF view UX improvement

This commit is contained in:
Vicki Pfau 2020-02-10 18:13:19 -08:00
parent fb12372ae3
commit afbf3f8e34
1 changed files with 5 additions and 0 deletions

View File

@ -84,6 +84,11 @@ void GIFView::setFilename(const QString& filename) {
m_filename = filename;
if (!FFmpegEncoderIsOpen(&m_encoder)) {
m_ui.start->setEnabled(!filename.isEmpty());
if (filename.endsWith(".gif")) {
m_ui.fmtGif->setChecked(Qt::Checked);
} else if (filename.endsWith(".png") || filename.endsWith(".apng")) {
m_ui.fmtApng->setChecked(Qt::Checked);
}
}
}