diff --git a/NEWS b/NEWS index efca8e3b86..c78b9dca27 100644 --- a/NEWS +++ b/NEWS @@ -1,102 +1,104 @@ digiKam 6.2.0 - Release date: 2019-06-?? ***************************************************************************************************** NEW FEATURES: IconView : HiDPI support for 4K screens. ***************************************************************************************************** BUGFIXES: 001 ==> 279216 - "Resize image" feature is missing some useful options [patch]. 002 ==> 406581 - "No such album" when dragging duplicated Tag to merge them. 003 ==> 406585 - Feature request: clean or hide empty Tags. 004 ==> 389657 - QFile::rename: Empty or null file name. 005 ==> 406610 - Hit enter when renaming, sometime don't rename correctly. 006 ==> 406637 - Duplicates "Search in" Doesn't Show Collection Name Upon First Selection. 007 ==> 406226 - Adding tags to a selection from a large list of no-tags images takes a very long time. 008 ==> 374302 - MYSQL : all Images with Geoinfo seem to be at (0°, 0°). 009 ==> 406815 - Can not setup Thunderbid in Send by mail. 010 ==> 406855 - Feature request: date from filename. 011 ==> 406938 - Face region is not saved after resizing. 012 ==> 406942 - Thumbnails does not get saved for videofiles over 2^64b, mysql. 013 ==> 406981 - GoPro video thumbnails are just noise. 014 ==> 407043 - Image rename to folder fails on Windows. 015 ==> 407157 - Lens Auto-Correction for fixed-lens cameras 016 ==> 407197 - Target album does not exist. 017 ==> 371005 - Zoom function doesn't work properly on HiDPI Display 018 ==> 407233 - Pictures distribution on Light Table. 019 ==> 403197 - Thumbnails in icon and preview views are not HiDPI (macOS). 020 ==> 370705 - Current Album is deselected when clearing search bar. 021 ==> 407232 - Swith from list to display with enter. 022 ==> 407262 - Face tagging doesn't work with rotation. 023 ==> 407345 - Verbose debug messages. 024 ==> 407334 - Accented characters not taken into account google photos. 025 ==> 406594 - Interface becomes irresponsive for a while after editing metadata in search panel. 026 ==> 407357 - Print Creator Gimp 2.10. not recgonized. 027 ==> 397865 - Current GIMP version cannot be selected. 028 ==> 407440 - After export to google photo, metadata are written to sidecar files (and perhaps to picture file too). 029 ==> 401100 - Release plan text not readable. 030 ==> 360475 - Open in file manager for individual images. 031 ==> 407565 - Entering multi tags to the same photo failed. 032 ==> 378112 - No progress bar while maint initializes. 033 ==> 407699 - Text format for "add tag" and "remove tag" is inconsistent. 034 ==> 407736 - Status Bar Not Visible in Full Screen. 035 ==> 407806 - Applied reverse geocoding are not saved. 036 ==> 407946 - Duplicates search should perform the search automatically. 037 ==> 407947 - Crash while updating fingerprints. 038 ==> 407993 - Feature request: feedback when deleting unassigned tags in Tag Manager. 039 ==> 407958 - In Thumbnail View Creation date is not correct. 040 ==> 407948 - Option to configure temp directory. 041 ==> 387770 - Plugin Instructions Unreadable in Some Themes. 042 ==> 397599 - Usability deteriorated. 043 ==> 388359 - Icons on the toolbar are not visible when background is dark. 044 ==> 408147 - From LightTable, "Open" picture does not open the right one. 045 ==> 408157 - "Tone Color Picker" cursor is not correctly positionned vs Mouse. 046 ==> 408095 - Sort items by manual. 047 ==> 378364 - Sequence number options need date-aware modifier. 048 ==> 408213 - '+' symbol is a legitimate win10 file character but unable to enter it into digiKam via Rename. 049 ==> 408261 - In Metadata editor, "Ok" and "Apply" buttons should save changes for all tabs, not just the active one. 050 ==> 408265 - The stacked images tool appears to be non-functional. 051 ==> 369657 - XMP subject matter code can be added twice. 052 ==> 408311 - Opening and closing downloading windows. 053 ==> 408334 - Windows elements design changed? 054 ==> 408332 - Disabled Export plugins visible in rightside toolbar. 055 ==> 342379 - Allow to use decimals values with custom size settings. 056 ==> 408450 - digikam git r43105 cannot build without marble. 057 ==> 408420 - Can't add images to Lightable. 058 ==> 408466 - When exporting >1 picture to Google Photos, all pictures have title & caption of the last one. 059 ==> 387093 - Option to select ignored folders on first setup crashes DigiKam. 060 ==> 408513 - Piwigo export does not save connection details. 061 ==> 408525 - Flickr export - location lost and/or replaced. 062 ==> 408562 - Applying the Exif rotation setting to images only, not videos. 063 ==> 408568 - Keywords are not showing up on video files. 064 ==> 408667 - In reverse geocoding, whow which address element correspond to each name. 065 ==> 408666 - Reverse geocoding tool, confusing dialog question phrasing. 066 ==> 406937 - Cannot change icon theme in Appimage. 067 ==> 408687 - "Failed to update file timestamp" despite date being changed successfully in Adjust Date and Time tool. 068 ==> 408804 - Deleted file in Digikam can't be found in Windows trash bin. 069 ==> 408803 - Placement bug in Thumbnail view when using arrow keys. 070 ==> 408819 - Displayed number of entries. 071 ==> 408793 - Memory leak when .psd file in album folder. 072 ==> 408782 - In manual sorting, bad placement after new version creation. 073 ==> 408471 - DigiKam crashes after about 10 photos viewed, random images then fail to load. 074 ==> 408883 - Crash after opening video in Image Editor - /tmp runs out of space. 075 ==> 376359 - Sort by Image Quality (assign quality tags) ignores many images. 076 ==> 408958 - digikam crashes on deletion of new files from SD card (import window). 077 ==> 398921 - digikam 5.9.0 slow to start on Mac but rapid on Ubuntu with same database. 078 ==> 408952 - Leaving Lighttable. 079 ==> 408982 - Not being able to write person name when tagging faces despite text field having focus. 080 ==> 404384 - Show number of entries in group. 081 ==> 409038 - Erroneous extraction of date metadata for videos. 082 ==> 405589 - Date taken metadata for video files (start video not used and difference of time). 083 ==> 409087 - OpenGL Viewer does not respect the picture rotation. 084 ==> 408881 - Digikam Editor automatically reapplies last edition, even on a different picture. 085 ==> 391840 - Timeline does not show any pictures if range is too big. 086 ==> 408878 - 'Open with' shows nothing. 087 ==> 387575 - Last note in server instructions is truncated. 088 ==> 165753 - Scale image: Allow setting new size in inch/cm/mm. 089 ==> 402063 - Database names is not valid. 090 ==> 329438 - Rename function with Date & Time does not work with NTFS. 091 ==> 409528 - Unable to select default email client / outlook for sending by email. -092 ==> +092 ==> 409686 - Digikam hits database deadlock on start with gelocation query. +093 ==> 409698 - Typo in digiKam menu. +094 ==> diff --git a/core/dplugins/generic/tools/expoblending/blendingdlg/expoblendingdlg.cpp b/core/dplugins/generic/tools/expoblending/blendingdlg/expoblendingdlg.cpp index 49d6f20ecd..8346af94e7 100644 --- a/core/dplugins/generic/tools/expoblending/blendingdlg/expoblendingdlg.cpp +++ b/core/dplugins/generic/tools/expoblending/blendingdlg/expoblendingdlg.cpp @@ -1,676 +1,676 @@ /* ============================================================ * * This file is a part of digiKam project * https://www.digikam.org * * Date : 2009-12-13 * Description : a tool to blend bracketed images. * * Copyright (C) 2009-2019 by Gilles Caulier * Copyright (C) 2015 by Benjamin Girault, * * This program is free software; you can redistribute it * and/or modify it under the terms of the GNU General * Public License as published by the Free Software Foundation; * either version 2, or (at your option) * any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * ============================================================ */ #include "expoblendingdlg.h" // C ANSI includes extern "C" { #include #include #include } // C++ includes #include // Qt includes #include #include #include #include #include #include #include #include #include #include #include #include #include // KDE includes #include #include // Local includes #include "digikam_debug.h" #include "expoblendingthread.h" #include "bracketstack.h" #include "enfusebinary.h" #include "enfusesettings.h" #include "enfusestack.h" #include "dmessagebox.h" #include "dpreviewmanager.h" #include "dsavesettingswidget.h" #include "expoblendingmanager.h" #include "dfileoperations.h" #include "dxmlguiwindow.h" using namespace Digikam; namespace DigikamGenericExpoBlendingPlugin { class Q_DECL_HIDDEN ExpoBlendingDlg::Private { public: explicit Private() : templateFileName(nullptr), previewWidget(nullptr), enfuseSettingsBox(nullptr), saveSettingsBox(nullptr), bracketStack(nullptr), enfuseStack(nullptr), mngr(nullptr), firstImageDisplayed(false), buttonBox(nullptr), previewButton(nullptr), startButton(nullptr), propagateReject(true) { } QString inputFileName; QString output; QLineEdit* templateFileName; DPreviewManager* previewWidget; EnfuseSettingsWidget* enfuseSettingsBox; DSaveSettingsWidget* saveSettingsBox; BracketStackList* bracketStack; EnfuseStackList* enfuseStack; ExpoBlendingManager* mngr; bool firstImageDisplayed; QDialogButtonBox* buttonBox; QPushButton* previewButton; QPushButton* startButton; bool propagateReject; }; ExpoBlendingDlg::ExpoBlendingDlg(ExpoBlendingManager* const mngr, QWidget* const parent) : QDialog(parent), d(new Private) { d->mngr = mngr; setModal(false); setWindowTitle(i18n("Exposure Blending")); const int spacing = QApplication::style()->pixelMetric(QStyle::PM_DefaultLayoutSpacing); d->buttonBox = new QDialogButtonBox(QDialogButtonBox::Close, this); d->buttonBox->button(QDialogButtonBox::Close)->setDefault(true); d->startButton = new QPushButton(this); d->startButton->setText(i18nc("@action:button", "&Save")); d->startButton->setIcon(QIcon::fromTheme(QLatin1String("document-save"))); d->startButton->setToolTip(i18nc("@info:tooltip", "Process and save selected items.")); d->buttonBox->addButton(d->startButton, QDialogButtonBox::ActionRole); d->previewButton = new QPushButton(this); d->previewButton->setText(i18nc("@action:button", "&Preview")); d->previewButton->setIcon(QIcon::fromTheme(QLatin1String("system-run"))); d->previewButton->setToolTip(i18nc("@info:tooltip", "Process a preview of bracketed images stack with current settings.")); d->buttonBox->addButton(d->previewButton, QDialogButtonBox::ActionRole); QPushButton* const defaultButton = new QPushButton(this); defaultButton->setText(i18nc("@action:button", "&Default")); defaultButton->setIcon(QIcon::fromTheme(QLatin1String("document-revert"))); defaultButton->setToolTip(i18nc("@info:tooltip", "Revert current settings to default values.")); d->buttonBox->addButton(defaultButton, QDialogButtonBox::ResetRole); // --------------------------------------------------------------- d->previewWidget = new DPreviewManager(this); d->previewWidget->setButtonText(i18nc("@action:button", "Details...")); // --------------------------------------------------------------- QScrollArea* const rightColumn = new QScrollArea(this); QWidget* const rightPanel = new QWidget(rightColumn->viewport()); rightColumn->setWidget(rightPanel); rightColumn->setWidgetResizable(true); rightColumn->setFrameStyle(QFrame::NoFrame); QVBoxLayout* const panel = new QVBoxLayout(rightPanel); d->bracketStack = new BracketStackList(rightPanel); panel->addWidget(d->bracketStack, 1); // --------------------------------------------------------------- QGroupBox* const enfuse = new QGroupBox(rightPanel); enfuse->setTitle(i18n("Enfuse Settings")); QVBoxLayout* const elay = new QVBoxLayout(enfuse); enfuse->setLayout(elay); d->enfuseSettingsBox = new EnfuseSettingsWidget(enfuse); elay->addWidget(d->enfuseSettingsBox); panel->addWidget(enfuse, 1); // --------------------------------------------------------------- QGroupBox* const save = new QGroupBox(rightPanel); - save->setTitle(i18n("Save Settings")); + save->setTitle(i18n("Save Result")); QVBoxLayout* const slay = new QVBoxLayout(save); save->setLayout(slay); d->saveSettingsBox = new DSaveSettingsWidget(save); slay->addWidget(d->saveSettingsBox); QHBoxLayout* const hbox = new QHBoxLayout(save); QLabel* const customLabel = new QLabel(save); customLabel->setText(i18nc("@label:textbox", "File Name Template: ")); hbox->addWidget(customLabel); d->templateFileName = new QLineEdit(save); d->templateFileName->setClearButtonEnabled(true); hbox->addWidget(d->templateFileName); d->saveSettingsBox->setCustomSettingsWidget(d->saveSettingsBox); slay->addLayout(hbox); panel->addWidget(save, 1); // --------------------------------------------------------------- d->enfuseStack = new EnfuseStackList(rightPanel); panel->addWidget(d->enfuseStack, 1); rightPanel->setLayout(panel); panel->setContentsMargins(QMargins()); // --------------------------------------------------------------- QGridLayout* const grid = new QGridLayout(this); grid->addWidget(d->previewWidget, 0, 0, 3, 1); grid->addWidget(rightColumn, 0, 1, 3, 1); grid->addWidget(d->buttonBox, 4, 0, 1, 2); grid->setContentsMargins(spacing, spacing, spacing, spacing); grid->setSpacing(spacing); grid->setColumnStretch(0, 10); grid->setColumnStretch(1, 5); setLayout(grid); // --------------------------------------------------------------- connect(this, SIGNAL(finished(int)), this, SLOT(slotFinished())); connect(this, SIGNAL(cancelClicked()), this, SLOT(slotCancelClicked())); connect(defaultButton, SIGNAL(clicked()), this, SLOT(slotDefault())); connect(d->startButton, SIGNAL(clicked()), this, SLOT(slotProcess())); connect(d->previewButton, SIGNAL(clicked()), this, SLOT(slotPreview())); connect(d->buttonBox, &QDialogButtonBox::rejected, this, &ExpoBlendingDlg::slotCloseClicked); connect(d->mngr->thread(), SIGNAL(starting(DigikamGenericExpoBlendingPlugin::ExpoBlendingActionData)), this, SLOT(slotExpoBlendingAction(DigikamGenericExpoBlendingPlugin::ExpoBlendingActionData))); connect(d->mngr->thread(), SIGNAL(finished(DigikamGenericExpoBlendingPlugin::ExpoBlendingActionData)), this, SLOT(slotExpoBlendingAction(DigikamGenericExpoBlendingPlugin::ExpoBlendingActionData))); connect(d->bracketStack, SIGNAL(signalAddItems(QList)), this, SLOT(slotAddItems(QList))); connect(d->bracketStack, SIGNAL(signalItemClicked(QUrl)), this, SLOT(slotItemClicked(QUrl))); connect(d->previewWidget, SIGNAL(signalButtonClicked()), this, SLOT(slotPreviewButtonClicked())); connect(d->enfuseStack, SIGNAL(signalItemClicked(QUrl)), this, SLOT(slotLoadProcessed(QUrl))); connect(d->templateFileName, SIGNAL(textChanged(QString)), this, SLOT(slotFileFormatChanged())); connect(d->saveSettingsBox, SIGNAL(signalSaveFormatChanged()), this, SLOT(slotFileFormatChanged())); // --------------------------------------------------------------- busy(false); readSettings(); loadItems(d->mngr->itemsList()); } ExpoBlendingDlg::~ExpoBlendingDlg() { delete d; } void ExpoBlendingDlg::slotFinished() { d->mngr->thread()->cancel(); d->mngr->cleanUp(); saveSettings(); } void ExpoBlendingDlg::closeEvent(QCloseEvent* e) { if (!e) { return; } slotFinished(); e->accept(); } void ExpoBlendingDlg::slotCancelClicked() { d->mngr->thread()->cancel(); } void ExpoBlendingDlg::slotFileFormatChanged() { d->enfuseStack->setTemplateFileName(d->saveSettingsBox->fileFormat(), d->templateFileName->text()); } void ExpoBlendingDlg::slotPreviewButtonClicked() { DMessageBox::showInformationList(QMessageBox::Information, qApp->activeWindow(), qApp->applicationName(), i18nc("@title:window", "Enfuse Processing Messages"), d->output.split(QLatin1Char('\n'))); } void ExpoBlendingDlg::loadItems(const QList& urls) { d->bracketStack->clear(); d->bracketStack->addItems(urls); } void ExpoBlendingDlg::slotAddItems(const QList& urls) { if (!urls.isEmpty()) { d->mngr->thread()->identifyFiles(urls); if (!d->mngr->thread()->isRunning()) d->mngr->thread()->start(); } } void ExpoBlendingDlg::slotItemClicked(const QUrl& url) { QString fileName = url.fileName(); if (fileName.isEmpty()) return; int dot = fileName.lastIndexOf(QLatin1Char('.')); fileName = fileName.left(dot); d->templateFileName->setText(fileName); slotFileFormatChanged(); } void ExpoBlendingDlg::slotLoadProcessed(const QUrl& url) { d->mngr->thread()->loadProcessed(url); if (!d->mngr->thread()->isRunning()) d->mngr->thread()->start(); } void ExpoBlendingDlg::setIdentity(const QUrl& url, const QString& identity) { BracketStackItem* const item = d->bracketStack->findItem(url); if (item) item->setExposure(identity); } void ExpoBlendingDlg::busy(bool val) { d->enfuseSettingsBox->setEnabled(!val); d->saveSettingsBox->setEnabled(!val); d->bracketStack->setEnabled(!val); d->startButton->setEnabled(!val ? !d->enfuseStack->settingsList().isEmpty() : false); d->previewButton->setEnabled(!val); setRejectButtonMode(val ? QDialogButtonBox::Cancel : QDialogButtonBox::Close); if (val) d->previewWidget->setButtonVisible(false); } void ExpoBlendingDlg::slotDefault() { d->enfuseSettingsBox->resetToDefault(); d->saveSettingsBox->resetToDefault(); d->templateFileName->setText(QLatin1String("enfuse")); } void ExpoBlendingDlg::readSettings() { KConfig config; KConfigGroup group = config.group("ExpoBlending Settings"); d->enfuseSettingsBox->readSettings(group); d->saveSettingsBox->readSettings(group); d->templateFileName->setText(group.readEntry("Template File Name", QString::fromLatin1("enfuse"))); winId(); KConfigGroup group2 = config.group("ExpoBlending Dialog"); DXmlGuiWindow::restoreWindowSize(windowHandle(), group2); resize(windowHandle()->size()); } void ExpoBlendingDlg::saveSettings() { KConfig config; KConfigGroup group = config.group("ExpoBlending Settings"); d->enfuseSettingsBox->writeSettings(group); d->saveSettingsBox->writeSettings(group); group.writeEntry("Template File Name", d->templateFileName->text()); KConfigGroup group2 = config.group("ExpoBlending Dialog"); DXmlGuiWindow::saveWindowSize(windowHandle(), group2); config.sync(); } void ExpoBlendingDlg::slotPreview() { QList selectedUrl = d->bracketStack->urls(); if (selectedUrl.isEmpty()) return; ExpoBlendingItemUrlsMap map = d->mngr->preProcessedMap(); QList preprocessedList; foreach (const QUrl& url, selectedUrl) { ExpoBlendingItemPreprocessedUrls preprocessedUrls = map.value(url); preprocessedList.append(preprocessedUrls.previewUrl); } EnfuseSettings settings = d->enfuseSettingsBox->settings(); settings.inputUrls = d->bracketStack->urls(); settings.outputFormat = d->saveSettingsBox->fileFormat(); d->mngr->thread()->enfusePreview(preprocessedList, d->mngr->itemsList()[0], settings, d->mngr->enfuseBinary().path()); if (!d->mngr->thread()->isRunning()) d->mngr->thread()->start(); } void ExpoBlendingDlg::slotProcess() { QList list = d->enfuseStack->settingsList(); if (list.isEmpty()) return; ExpoBlendingItemUrlsMap map = d->mngr->preProcessedMap(); QList preprocessedList; foreach (const EnfuseSettings& settings, list) { preprocessedList.clear(); foreach (const QUrl& url, settings.inputUrls) { ExpoBlendingItemPreprocessedUrls preprocessedUrls = map.value(url); preprocessedList.append(preprocessedUrls.preprocessedUrl); } d->mngr->thread()->enfuseFinal(preprocessedList, d->mngr->itemsList()[0], settings, d->mngr->enfuseBinary().path()); if (!d->mngr->thread()->isRunning()) d->mngr->thread()->start(); } } void ExpoBlendingDlg::saveItem(const QUrl& temp, const EnfuseSettings& settings) { QUrl newUrl = QUrl::fromLocalFile(temp.adjusted(QUrl::RemoveFilename).toLocalFile() + settings.targetFileName); if (d->saveSettingsBox->conflictRule() != FileSaveConflictBox::OVERWRITE) { newUrl = DFileOperations::getUniqueFileUrl(newUrl); } qCDebug(DIGIKAM_DPLUGIN_GENERIC_LOG) << "Renaming " << temp << " to " << newUrl; if (!newUrl.isEmpty()) { // remove newUrl file if it exist if (temp.toLocalFile() != newUrl.toLocalFile() && QFile::exists(temp.toLocalFile()) && QFile::exists(newUrl.toLocalFile())) { QFile::remove(newUrl.toLocalFile()); } if (!QFile::rename(temp.toLocalFile(), newUrl.toLocalFile())) { QMessageBox::critical(this, QString(), i18n("Failed to save image to %1.", QDir::toNativeSeparators(newUrl.toLocalFile()))); d->enfuseStack->setOnItem(settings.previewUrl, false); d->enfuseStack->processedItem(settings.previewUrl, false); return; } else { d->enfuseStack->removeItem(settings.previewUrl); } } if (d->enfuseStack->settingsList().isEmpty()) { d->startButton->setEnabled(false); busy(false); d->previewWidget->setBusy(false); } emit d->mngr->updateHostApp(newUrl); } void ExpoBlendingDlg::slotExpoBlendingAction(const DigikamGenericExpoBlendingPlugin::ExpoBlendingActionData& ad) { QString text; if (ad.starting) // Something have been started... { switch (ad.action) { case(EXPOBLENDING_IDENTIFY): { break; } case(EXPOBLENDING_LOAD): { busy(true); break; } case(EXPOBLENDING_ENFUSEPREVIEW): { busy(true); d->previewWidget->setBusy(true, i18n("Processing preview of bracketed images...")); break; } case(EXPOBLENDING_ENFUSEFINAL): { busy(true); d->previewWidget->setBusy(true, i18n("Processing output of bracketed images...")); d->enfuseStack->processingItem(ad.enfuseSettings.previewUrl, true); break; } default: { qCWarning(DIGIKAM_DPLUGIN_GENERIC_LOG) << "Unknown action"; break; } } } else { if (!ad.success) // Something is failed... { switch (ad.action) { case(EXPOBLENDING_IDENTIFY): { setIdentity(ad.inUrls[0], ad.message); busy(false); break; } case(EXPOBLENDING_LOAD): { d->previewWidget->setText(i18n("Failed to load processed image."), Qt::red); busy(false); break; } case(EXPOBLENDING_ENFUSEPREVIEW): { d->output = ad.message; d->previewWidget->setBusy(false); d->previewWidget->setButtonVisible(true); d->previewWidget->setText(i18n("Failed to process preview of bracketed images."), Qt::red); busy(false); break; } case(EXPOBLENDING_ENFUSEFINAL): { slotCancelClicked(); d->output = ad.message; d->previewWidget->setBusy(false); d->previewWidget->setButtonVisible(true); d->previewWidget->setText(i18n("Failed to process output of bracketed images."), Qt::red); d->enfuseStack->processingItem(ad.enfuseSettings.previewUrl, false); d->enfuseStack->setOnItem(ad.enfuseSettings.previewUrl, false); busy(false); break; } default: { qCWarning(DIGIKAM_DPLUGIN_GENERIC_LOG) << "Unknown action"; break; } } } else // Something is done... { switch (ad.action) { case(EXPOBLENDING_IDENTIFY): { setIdentity(ad.inUrls[0], ad.message); busy(false); break; } case(EXPOBLENDING_LOAD): { d->previewWidget->setImage(ad.image, !d->firstImageDisplayed); d->firstImageDisplayed |= true; d->enfuseStack->setThumbnail(ad.inUrls[0], ad.image); busy(false); break; } case(EXPOBLENDING_ENFUSEPREVIEW): { d->enfuseStack->addItem(ad.outUrls[0], ad.enfuseSettings); busy(false); break; } case(EXPOBLENDING_ENFUSEFINAL): { d->enfuseStack->processingItem(ad.enfuseSettings.previewUrl, false); saveItem(ad.outUrls[0], ad.enfuseSettings); break; } default: { qCWarning(DIGIKAM_DPLUGIN_GENERIC_LOG) << "Unknown action"; break; } } } } } void ExpoBlendingDlg::setRejectButtonMode(QDialogButtonBox::StandardButton button) { if (button == QDialogButtonBox::Close) { d->buttonBox->button(QDialogButtonBox::Close)->setText(i18n("Close")); d->buttonBox->button(QDialogButtonBox::Close)->setIcon(QIcon::fromTheme(QLatin1String("window-close"))); d->buttonBox->button(QDialogButtonBox::Close)->setToolTip(i18n("Close window")); d->propagateReject = true; } else if (button == QDialogButtonBox::Cancel) { d->buttonBox->button(QDialogButtonBox::Close)->setText(i18n("Cancel")); d->buttonBox->button(QDialogButtonBox::Close)->setIcon(QIcon::fromTheme(QLatin1String("dialog-cancel"))); d->buttonBox->button(QDialogButtonBox::Close)->setToolTip(i18n("Cancel current operation")); d->propagateReject = false; } else { qCDebug(DIGIKAM_DPLUGIN_GENERIC_LOG) << "Unexpected button mode passed"; } } void ExpoBlendingDlg::slotCloseClicked() { if (d->propagateReject) { reject(); } else { emit cancelClicked(); } } } // namespace DigikamGenericExpoBlendingPlugin