All these aren't actually things that need fixing, they are observations about
the code.
Given that LGTM.com reports FIXME comments as Alerts, let's change the ones
that aren't about things that need fixing to something more harmless.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
To test single bits, datatrak.c would transform bytes into
malloc()ed char[8] buffers. Instead, simply introduce a function
to test individual bits. This should make it distinctly easier for
the compiler to optimize away.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
It's a drop in the bucket, but let's remove some unnecessary
global variables. With one exception these variables were only
used in one function anyway. The other one can be passed as a
parameter.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Otherwise PRs from people who create branches in the main repo will always
trigger two builds.
The second entry should ensure that we do build releases.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
ostcFirmwareCheck in DownloadFromDCWidget was neither freed
in the destructor, not freed if a new object was allocated.
Simply make it a unique_ptr<> to do all the work for us.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Having a parameter representing a location with the same name as a global
variable representing our locale is confusing.
Found via LGTM.com
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
While in the specific calculations here there isn't really a risk that float
might overflow, it seems odd to cast to float in order to assign to double.
This caused an Alert via LGTM.com
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
snapcraft doesn't support remote parts any more, and there's no
extension (the replacement for remote parts) for Qt yet.
Signed-off-by: Michał Sawicz <michal.sawicz@canonical.com>
On LGTM we end up installing in /opt/out.
Also, fix a silly error in the existing code - don't look for libraries in
include directories.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
When updating the coordinates of a dive site, the MapLocationModel
is updated. The code created a (col, row) index with col = 0.
[The idea of course being col = x, row = y]. Alas, that's not
how Qt works - its models want (row, col) indices. The code
worked, because the only time when the dive site locations were
updated was in dive site edit mode, when only one site is visible,
i.e. there is only one row leading to the correct (0, 0) index.
Fix this so that we can also change dive site positions if more
than one site is displayed.
Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
We already do that on mobile and I was certain we used to do this for
desktop as well, but apparently that got lost somewhere...
This should solve the problems we are seeing for people with mixed case
email addresses.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Create a label for each line added for the depth and temperature
statistics buckets
Add line to statistics widget for each bucket to be displayed
Signed-off-by: Doug Junkins <junkins@foghead.com>
Added stats_t structures to summarize dive statistics by depth and
by temperature.
Process each dive to add the dive stats to the proper depth and
temperature bucket. Buckets are defined using constants
STATS_MAX_DEPTH, STATS_DEPTH_BUCKET, STATS_MAX_TEMP, and
STATS_TEMP_BUCKET which are defined in statistics.h
Signed-off-by: Doug Junkins <junkins@foghead.com>