Mostly irrelevant std::move() stuff of copy-on-write Qt objects,
a few real bugs, a timestamp_t downconversion and some codingsyle
adaptation.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
On the InformationTab a signal is emitted when programatically
setting the index of the dive mode combobox which in turn then
edits the dive.
Usually not a problem, because the editing code realizes that
the value is not changed. It is however a problem when multiple
dives are selected.
Therefore, block the signals when setting the index. Same for
the other comboboxes on the same page.
Fixes#3960.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
The DivePlannerWidget was initialized before the planner models.
However, it attaches these (non existing) models to the comboboxes.
That can't work. Initialize in correct order.
Fixes#4014
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
If prefs.show_icd is false, this function does nothing, but
the output parameter is checked by the calling function
DiveEventItem::setupToolTipString().
Let's reset the strucvture to 0.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
When adjusting picture times, the offset in seconds is stored in a
32-bit int. Make it a 64-bit int. Sounds crazy, because why would
you want to move the pictures by more than 70 years?
Well, suppose it is the year 2039, for some strange reason your
camera was set to unix epoch and you want to adjust the pictures
to current time.
Ok - that's a far-fetched scenario. The real reason is that this
hopefully silences a Coverity warning and avoids integer casting.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Unfortunately Coverity doesn't understand that most Qt data
structures are copy-on-write. It's a mis-feature of Qt, but
it is the way it is. Thus, passing by value is not an issue.
Out of ca. 25 warnings only two were legit. Let's silence
the others by either std::move()ing or passing by reference,
as would be idiomatic C++, which Qt is not.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Add more information to metainfo file and update it to the AppStream 1.0
standard
* Added screenshot caption, more URLs and a <launchable/> tag
* Replaced <developer_name/> with <developer/>
Now the file conforms to the AppStream 1.0 specification
Signed-off-by: Alexander Wilms <f.alexander.wilms@gmail.com>
There are two enums related to the type of dive.
There is the global
enum divemode_t {OC, CCR, PSCR, FREEDIVE, NUM_DIVEMODE,
UNDEF_COMP_TYPE};
and the anonymous
enum {AIR, NITROX, TRIMIX, FREEDIVING} dive_type;
in struct plot_info.
In profile.c FREEDIVE (of divemode_t) is assigned to dive_type.
This only works because by chance(?) FREEDIVE and FREEDIVING are
the fourth element of each enum.
Fix this. C truly is a bad language when it comes to types
(very weak) and namespaces (non existing).
Contains whitespace fix.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Current instruction to get the installer out the container will fail
with bash complaining about cp being a binary. Then would fail too
because subsurface-installer.exe doesn't exist any more.
Proposed instruction should work.
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
It is very strange that in some yaml files the $(<release-version) construct
works just fine, but in others it evaluates to an empty string, even though the
file is there an has the correct content.
Attempting to get more debugging info and also use a different expression to
extract the information.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
That was the whole point of the previous change.
Also, run the build number creation on a pull request as well (at least for a
while) so we don't need to create new releases in order to test that part of
the process).
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
In order to make it easier to see what's happening inside get-atomic-buildnr.sh
write the result to a file that can be read by the caller. Not quite as
elegant, but hopefully more practical to see what's going wrong when no new
build number is created.
Make sure that post-releasenotes is successfull by actually posting a release
artifact (apparently the gh release action otherwise quietly fails).
Try to ensure we find the Android APK when uploading to the release.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Some experimentation showed what should have been obvious. The release
information is additive. So it's enough if ONE of the actions creates release
notes, all the others can simply add additional release artifacts.
To make this more obvious, this commit creates a new action that does nothing
but create the release notes and publish the release. Since it really doesn't
do anything else, it's likely to be the quickest to complete, but that doesn't
matter - the last action that has a body or body_path in the gh-release action
determines the release notes. And we now have exactly one action that does so.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Instead of using a thirdparty action and painfully passing things around,
simply use the GitHub CLI (gh) and assemble the release notes on the fly.
This makes for much simpler and much easier to maintain code.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
The get-or-create-buildnr.sh script writes a nice message to stdout which is useful
when using it interactively - but it broke the scripting; so redirect that output.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>