mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Added warning when not all images can be added.
Added label in the ShiftImageTimesDialog which appears when not all of the selected images have timestamp in the checked range. Made cancel button in this widget actually work. Signed-off-by: Jan Darowski <jan.darowski@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
7d37a3f5a6
commit
0d77b921eb
4 changed files with 70 additions and 5 deletions
|
@ -850,9 +850,10 @@ void DiveListView::loadImages()
|
|||
return;
|
||||
|
||||
updateLastUsedImageDir(QFileInfo(fileNames[0]).dir().path());
|
||||
ShiftImageTimesDialog shiftDialog(this);
|
||||
ShiftImageTimesDialog shiftDialog(this, fileNames);
|
||||
shiftDialog.setOffset(lastImageTimeOffset());
|
||||
shiftDialog.exec();
|
||||
if (!shiftDialog.exec())
|
||||
return;
|
||||
updateLastImageTimeOffset(shiftDialog.amount());
|
||||
|
||||
Q_FOREACH (const QString &fileName, fileNames) {
|
||||
|
@ -861,7 +862,7 @@ void DiveListView::loadImages()
|
|||
for_each_dive (j, dive) {
|
||||
if (!dive->selected)
|
||||
continue;
|
||||
dive_create_picture(dive, qstrdup(fileName.toUtf8().data()), shiftDialog.amount());
|
||||
dive_create_picture(dive, copy_string(fileName.toUtf8().data()), shiftDialog.amount());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue