Latest Kirigami master allows us to turn off reachability mode. In
general this had been rather confusing to our users and it seems to
somewhat conflict with the pull down to refresh of the dive list.
Latest Kirigami also changes the behavior of refresh slightly, you now
need to pull "down" for at least 500ms before it triggers. So, with this
change and the latest Kirigami, hopefully the user experience for
refresh is good enough that we can consider keeping it enabled and use
it as an equivalent to manual sync (even in offline mode).
See #454
See #456
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Fast flicking to the top of the divelist triggers almost certainly a
pull down sync, as the default boundBehavior is DragAndOvershootBounds.
Despite being the default QML action, this leads to unwanted pull
down syncs (even in offline mode).
Setting the boundBehavior to DragOverBounds solves this issue. Now,
the user has to explicitly drag the top down to force a pull down
sync, and a accidental fast flick is stopped at the upper bound.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
Now that we support this for many dive computers, that seem reasonable.
I'm not happy with the icon, but couldn't figure out a better one in the
breeze icon set.
See #426
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
For now just do an indeterminate busy indicator - we can get more fancy
and use the libdivecomputer progress event, later.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Restyle construction of toast message and enable translation for it.
Further, removed newline characters as they break the lines at
non-logical positions.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
Let's have names for the colors in each theme and assign those
named values to the theme colors when switching themes. This
way other pages can access the colors that are not in the current
theme (for example for a theme switcher).
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This code is based on code from Marco Martin from the Kirigami Android
sample app. In order to simplify the QML code the QMLManager function is
there for all OSs, but it's a no-op on anything but Android.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This way the user can scroll up the page to see all of the notes without
having them covered by the action button.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Occasionally I see errors in the log where we would access modelData.dive
with modelData = null. This patch addresses a couple of the spaces where
this happens, but also simplifies the code by using the existing alias.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This isn't great, yet, but a first step to show that this is possible
(and in doing so I found quite a few spots where the colors weren't
correctly propagating, yet).
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
By making the assignments to the Kirigami Theme colors Qt bindings
things get correctly updated when switching.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Now that we have distinct colors for trip header and selected dive, this
is actually counter productive.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Make the accent color much lighter, don't have a solid bar on the left
for dives that are part of a trip.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Implementing another suggestion from Davide. A button to get the map
(as well as just tapping on the location name).
Fixes#431
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Remove the grid layout and replace it with code that is derived from the delegate
that we use in the dive list. In order to look proportional I ended up using a
larger font for the location and therefore decided to allow that text to wrap
instead of forcing single line.
This implements a good chunk of another one of Davide's great
suggestions.
See #431
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This removes fairly redundant text (yes, we know those are the Dive Details) and
makes the label for the Notes consistent with all the other labels.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Davide points out that this is not a commonly understood way in an app
to indicate that a text is also a link. So let's just remove that (but
tapping on the location will still work to get you to the map if there
is GPS information available).
See #431
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This shows that we are, indeed, using Roboto on Android. Which means I
can close the first of Davide's design issues:
Fixes#427
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>