Age | Commit message (Collapse) | Author |
|
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
|
|
This fixes an issue where beginRemoveRows is called with argument -1
in DiveImportedModel::setImportedDivesIndexes.
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
|
|
Curly braces are necessary in nested conditionals or results may not be
those expected. In this case, the "else" clause applied on second "if",
instead of first one.
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
|
|
Use update_event_name() for bookmarks merge and free temp string.
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
|
|
Do not just report the failure but abort parsing or we will get a crash
Signed-off-by: Salvador Cuñat <salvador.cunat@gmail.com>
|
|
I believe that even though the sample file clearly shows
comments, the syntax actually doesn't allow it.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
...sorry, I don't have a way to test this.
Signed-off-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
This is another attept at the problem if identifying a potentially
user supplied text in the dive notes upon replannig a dive.
It gets rid of the user visable position markers (*!* and ***) and
cirumvents problems with mark-up by first converting the old notes
to plan text (assuming that user only enters plain text in the notes
field as we do in other places as well). Then the automatically added
part is identified by locating the disclaimer in the text (if the user
edited/delted the disclaimer or changed langue in between it is her
problem to manually delete the old plan).
Everything from the disclaimer on is deleted and replaced by the new plan.
If the disclaimer is not found, the new plan is appended to the old notes.
This way we make sure no information gets automatically deleted.
Signed-off-by: Robert C. Helling <helling@atdotde.de>
|
|
Yes, currentdive can be undefined in case of of a new logbook and starting the planner
right away. Do not abort on that.
Reported-by: Robert C. Helling <helling@atdotde.de>
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
|
|
When replanning a dive, the setpoint information from the profile waypoints
were reset to 0, resulting in a dive that has a dive mode of CCR, but only with
OC legs in the profile. This is just wrong, and is corrected here. Notice
that there is no averaging involved (in the reduction of a replanned real
dive that has more than 100 waypoints) as is done for depth. This is just
fine for setpoint data.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
|
|
Data such as cilinders and used gasses are populated fromn the currently
selected dive when starting the planner. It is more logical to use
the dive mode (OC, CCR, pSCR) of the currently selected dive
as well. This commits changes this.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
|
|
2 strings in the planner output showed based on "Bühlmann ZHL-16B with GFLow = "
gradient factors without % after the factor. While this is fine for an
abbreviated form like GF 40/80, this looks strange for a verbose sentence like
the 2 corrected ones.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
|
|
Currently we do not know what the extra data in the sampleBlob is, but
the block size must be adjusted nevertheless.
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
|
|
Signed-off-by: Robert C. Helling <helling@atdotde.de>
|
|
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Setting up an RFCOMM connection has not been required for a long time.
Reported-by: Stephen Hemminger <stephen@networkplumber.org>
Signed-off-by: Rick Walsh <rickmwalsh@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Applie a more strict filter to URL handling in dive notes:
The URL needs to have:
- Scheme like "http:" or "mailto:"
- Host name like "www.test.de" or path like "/pathtosomewhere/"
Otherwise strings like "OTU:" or "Runtime:" are treated as URL.
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
|
|
URLs in the dive notes are detected today. A tooltip is displayed and
one can follow the URL by Ctrl-click.
In the function fromCursorTilWhitespace there is an issue with incorrect
return value of Qt (5.7?!) function cursor->movePosition(). This value is
erroneous true in some condition e.g. if the cursor is inside a table at
the very beginning or the very end of a table line and not moving any more.
This can cause the function end up in an infinite loop.
Bugfix adds an additional exit criteria for the loop if the string is
not growing any more.
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
|
|
We parse input XML using UTF-8 encoding by default. If this fails, try
latin1 instead.
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
|
|
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
|
|
Now it should also work on devices with device pixel ratios of
1.3, 1.33, or 1.4.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Once we re-inserted the dive in the list we aren't done, quite the
contrary - we now need to make sure that we handle any other changes
and mark the dive list as updated.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
We need to set the timeSpec after the QDateTime was parsed,
otherwise it gets converted to localtime again.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
See https://github.com/Subsurface-divelog/subsurface/issues/253. The original
behaviour (greyed out when disconnected) is restored. Not sure where and when
got lost, but this simple change fixes it.
Fixes #253
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
|
|
New strategy to identify old planner output in notes when
replanning a dive: Text anchors ("*!*" and "***") added for planner output
For backwards compatibility: If there is no anchor but an old table
delete everything.
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
|
|
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
|
|
Change source for grantlee in build.sh to Github steveire/grantlee
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
|
|
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
|
|
Don't add the last stop with addstop for correcting the lenght
of the dive if planner generated points can be removed when replanning.
Otherwise this will not be deleted when replanning a dive.
Signed-off-by: Stefan Fuchs <sfuchs@gmx.de>
|
|
Trying to close the non-existing context drawer caused the function
to abort (and consequently not to delete the dive).
Fixes #309
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
There was an extra BasicListItem inside the SwipeListItem.
This commit just removes 5 lines, the rest is indentation change.
Fixes #312
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Otherwise the last value in those fields might still be shown.
Also, set up the cylinder completion.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
We already have that for the other three fields where we offer auto
completion (buddy, divemaster, suit).
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
I think this is actually a typo - either way, seems to work correctly
now.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Prior to Qt Quick Components 2.1 there was no onPressed signal for a
TextField; in order to be able to build against Qt 5.7 (which comes with
Qt Quick Components 2.0) we need to work around the lack of this signal.
This code seems to do a pretty good job at simulating it.
My attempt in commit 73c66e1d7d9f ("QML UI: make run with Qt 5.7 again")
didn't work so well.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
If we don't have values for the HintsTextEdit fields, don't show any
values.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
This fixes the visual artifact that Willem reported.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
We reference it elsewhere.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Now that wrapping should work correctly, this isn't necessary any more.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
onPressed needs to be relative to Keys in Qt 5.7.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
This needs to be reimplemented.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
After the restyle of the maintab code, the translation of some tab titles went
missing. Corrected here.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
|
|
This should make it easier to spot displays that are completely out of
whack in their scaling.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Some of these header files are no longer necessary, and will be removed
from libdivecomputer in the near future.
Signed-off-by: Jef Driesen <jef@libdivecomputer.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
The custom_serial.h header doesn't exist in upstream libdivecomputer.
Signed-off-by: Jef Driesen <jef@libdivecomputer.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Assigning actions in an imperative way on component complete,
seems to cause a crash on some devices, assign declaratively
the whole list instead, hiding the gps related actions on
iOS as they are not supported on that platform.
Signed-off-by: Marco Martin <notmart@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|
|
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
|