editing: Decide editable based on true mime type

Previously it was decided on the early unreliable mime type.

Fixes #449
This commit is contained in:
Sophie Herold 2025-02-19 11:46:32 +01:00
parent e3a58270b1
commit 1d40a28b54
4 changed files with 31 additions and 12 deletions

View file

@ -231,7 +231,7 @@ impl LpImagePage {
imp.stack.set_visible_child(&*imp.error_page);
imp.error_more_info.set_visible(false);
} else if image.specific_error() == DecoderError::UnsupportedFormat {
let mime_type = image.metadata().mime_type().unwrap_or_default();
let mime_type = image.metadata().unreliable_mime_type().unwrap_or_default();
let content_type = gio::content_type_from_mime_type(&mime_type).unwrap_or_default();
let description = gio::content_type_get_description(&content_type).to_string();