[gthumb] import task: always read the image if the orientation adjustment is requested
- From: Paolo Bacchilega <paobac src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gthumb] import task: always read the image if the orientation adjustment is requested
- Date: Sun, 4 Nov 2012 18:23:34 +0000 (UTC)
commit 342699666dde433cdeeb6ca1fdda19a45f357e63
Author: Paolo Bacchilega <paobac src gnome org>
Date: Sun Nov 4 18:54:33 2012 +0100
import task: always read the image if the orientation adjustment is requested
extensions/importer/gth-import-task.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
---
diff --git a/extensions/importer/gth-import-task.c b/extensions/importer/gth-import-task.c
index 54797ce..c3fbc62 100644
--- a/extensions/importer/gth-import-task.c
+++ b/extensions/importer/gth-import-task.c
@@ -598,6 +598,8 @@ static void
import_current_file (GthImportTask *self)
{
GthFileData *file_data;
+ gboolean adjust_image_orientation;
+ gboolean need_image_metadata;
g_free (self->priv->buffer);
self->priv->buffer = NULL;
@@ -657,9 +659,10 @@ import_current_file (GthImportTask *self)
file_data = self->priv->current->data;
self->priv->current_file_size = g_file_info_get_size (file_data->info);
- if (_g_mime_type_is_image (gth_file_data_get_mime_type (file_data))
- && (self->priv->subfolder_type == GTH_SUBFOLDER_TYPE_FILE_DATE))
- {
+ adjust_image_orientation = self->priv->adjust_orientation && gth_main_extension_is_active ("image_rotation");
+ need_image_metadata = (self->priv->subfolder_type == GTH_SUBFOLDER_TYPE_FILE_DATE) || adjust_image_orientation;
+
+ if (_g_mime_type_is_image (gth_file_data_get_mime_type (file_data)) && need_image_metadata) {
gth_task_progress (GTH_TASK (self),
_("Importing files"),
g_file_info_get_display_name (file_data->info),
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]