Scale the QML profile in two stages. Firstly, scale to fit. Secondly, scale
again to 95% to create a margin around the profile.
The previous method scales to fit a create a margin in one step. It appears
more elegant, and the margin is calculated more rationally. Unfortunately on
some devices, including mine, the resulting profile is cropped for no obvious
reason.
Signed-off-by: Rick Walsh <rickmwalsh@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Don't use EmailCharactersOnly input method hint for the password. This fixes
the problem of password being displayed on entry, at least on my device.
Signed-off-by: Rick Walsh <rickmwalsh@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
We don't need any of the interactive features. Additionally this allows us to
easily ask for slightly smaller fonts.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
For some users by default the password characters aren't hidden. Maybe the
debugging output will help us understand what's going on.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This is a simple way to deal with a "no network" situation. But this isn't
ideal, yet, if there is a slow network as the dive list will be reset again
once the sync from the cloud finishes. So there is some more thought needed to
make this work "mostly as expected".
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Instead of doing the silly "onEditingFinished" we get the strings from the QML
components at the time we commit the change. Much more logical, much more
straight forward, no issues with the TextArea not having an onEditingFinished
signal.
This still has a few open todos: the temperatures aren't parsed, the edit
screen is missing depth and duration, we can't edit the dive time (and it isn't
passed in on the commit). But it's progress.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Now we at least start out with the corret date, time and number. This still
isn't functional as a lot of the data aren't used and the way you save the data
is completely silly, but it's another step in the right direction.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This mainly happens because add dive is completely broken right now, but in
general it seems to be good policy not to blindly dereference this pointer...
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
I'm not sure this is the best way to do this - QML should be able to get to the
model data directly (I hope?). But this seems to work and I need it to make Add
Dive be semi-correct.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
In the dive detail view, if a location has an associated GPS location, show the
name of the location underlined so the user knows that tapping on it will open
a browser window with a map picture.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This is of course stupid and NOT what we want to do, but one could argue it's
better than nothing (well, not sure, whatever). If we have a GPS location
associated with a dive and you tap on the location name when showing the dive
details, it opens a static image of a satellite map with a marker for the dive
site.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This still doesn't address all the issues, but appears to be a step
forward. It also contains some debug output to better understand what's
going on.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
It appears that one some Android devices there is an interaction between
Qt and the GL implementation that results in black squares instead of
icons being shown on the screen.
Disabling the GammaAdjust avoids running the shader and fixes this
problem.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
At least one tester cannot retrieve their web user id. This should help us
collect more data and figure out why this fails.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Now the message should make more sense. First it tells you that it's looking
for dives. Then you get some progress during the git download, and error
messages if things failed.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
So this has a lot of caveats:
- right now it only works for buddy, divemaster and suit
- you have to actually exit the field with your cursor or the change
doesn't take - that's ridiculous, there must be a far more clever way to
do this
- because I use the onEditingFinished handler I can't do this for the
Notes (so here's another reason why I KNOW that this is the wrong way to
do this)
But it shows in principle how this could be done and once someone who
actually knows what they are doing gets their hands on the code I'm
optimistic that this can be morphed into something much more useful.
It does tie together the changes made in the previous commits so that both
clicking around on the dive list gives the expected results and synching
the data back to the cloud actually works.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Well, at least it doesn't what you think it does. Let's use our little
helper to actually compare the strings.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
File is unused, apparently a left-over from a rename. It's not included
in the qrc and referenced nowhere, so it's safe to delete.
Signed-off-by: Sebastian Kügler <sebas@kde.org>
- page margins are gridUnit / 2, consistent with other pages
- Simplify layout: we don't need to nest that much here, saves two
objects and simplifies code a bit
Signed-off-by: Sebastian Kügler <sebas@kde.org>
This patch creates the following menu structure in the application menu
as discussed on irc:
Cloud credentials
Preferences
Manage dives
Download from computer
Add dive manually
Refresh dives
Upload to cloud
GPS
Add GPS tags to dives
Upload GPS data
Clear GPS cache
Advanced (hidden by default)
App log
Theme Information
"Save" moves out of the context menu, since it's a global thing (syncs
to server).
Signed-off-by: Sebastian Kügler <sebas@kde.org>
Spacing around pages is half a grid unit, as consistent with (some of
the) other pages. For the dive list, it's slightly more complicated:
We want the list items to reach the edges on both side as to increase
the interactive area. We have to apply the spacing left and right inside
the listitems. This patch does that.
Another consistency fix with other pages is that we're now adding a
header at the top of the dive list, which scrolles with the list view.
Signed-off-by: Sebastian Kügler <sebas@kde.org>
Apparently, the width setting got lost in the previous change. This sets
the width of the log text explicitely to the grandparent's width. It
fixes text clipping in the log window.
Signed-off-by: Sebastian Kügler <sebas@kde.org>
This change cleans up the layout optimized for viewing dive details. The
top part contains brief and essential dive info (location, depth,
duration, dive no.), then the profile, then a table with more details,
and finally the notes.
The goal here is to present the dive's data more efficiently and
attractively now that the edit part is factored out.
Signed-off-by: Sebastian Kügler <sebas@kde.org>
Icons for document-edit, document-save and view-readermode are added
from the light breeze variant. They're usd in the dive's contextual
actions.
Signed-off-by: Sebastian Kügler <sebas@kde.org>
Option to switch between view and edit and to save the changes are now
in the context drawer. Let's see how this works out.
If it turns out to be badly discoverable (which is what I'm worried
about), this needs to be fixed at component level.