Commit graph

212 commits

Author SHA1 Message Date
Dirk Hohndel
49a368539a QML UI: set opacity of 1 for dive list
Hopefully with this we get exactly the right colors.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-24 11:19:56 -07:00
Dirk Hohndel
e3cd6719c1 QML UI: Davide's colors for the blue theme
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-24 11:18:18 -07:00
Dirk Hohndel
94bc756391 QML UI: Theme colors: fix bad typo
Here I confused myself with "dark" theme and the "darkerPrimary"
colorls...

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-23 21:36:59 -07:00
Dirk Hohndel
206df227f8 QML UI: remember the theme
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-23 19:49:57 -07:00
Dirk Hohndel
26b206af1f QML UI: show a small color palette preview
When picking which color theme to use, show the user how things will look.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-23 19:49:57 -07:00
Dirk Hohndel
8ba581a088 QML UI: use textColor instead of diveListTextColor
This color is used for more than just the dive list.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-23 19:49:57 -07:00
Dirk Hohndel
694e833f90 QML UI: move theme setting into preferences
And reorganize settings and preferences a bit.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-23 18:48:41 -07:00
Dirk Hohndel
dac9ce578b QML UI: clean up the setting of theme colors
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>
2017-06-23 18:48:41 -07:00
Dirk Hohndel
3f055ac9cb QML UI: set color of the action button
This requires Kirigami master past 2.2.0 (which explains commit 001ff1b9
"QML UI: switch to Kirigami master").

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-23 08:44:55 -07:00
Dirk Hohndel
57e365222b QML UI: color the status bar on Android
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>
2017-06-23 08:42:45 -07:00
Dirk Hohndel
b1f7e3eae2 QML UI: add missing go-up icon
Now the 'Reachability' feature should be more obvious.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-22 09:05:43 -07:00
Dirk Hohndel
ea218b9d24 QML UI: DiveList: allow trip header to wrap
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-22 04:19:23 -07:00
Rick Walsh
d9cb65cbed QML UI: turn off spinner if pull-down-to-refresh fails
Signed-off-by: Rick Walsh <rickmwalsh@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-22 04:19:23 -07:00
Dirk Hohndel
28490d5dd0 QML UI: DiveDetails: add more space at bottom
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>
2017-06-21 18:33:27 -07:00
Dirk Hohndel
a7fca80a3e QML UI: don't access dive without modelData
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>
2017-06-21 17:20:07 -07:00
Dirk Hohndel
7b7294d127 QML UI: DiveList: implement pull down to refresh
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-21 17:20:07 -07:00
Dirk Hohndel
e0f46b033d QML UI: attempt to add dark theme
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>
2017-06-21 17:20:07 -07:00
Dirk Hohndel
8f2fc84ae7 QML UI: simple attempt to allow color scheme switching
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>
2017-06-21 14:01:30 -07:00
Dirk Hohndel
71d9aafcd6 QML UI: Linus requested Hot Pink as color scheme
He started the project, he gets to have his color preference.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-21 13:34:15 -07:00
Dirk Hohndel
4651454557 QML UI: don't reduce opacity for background of selected dive
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>
2017-06-21 11:53:19 -07:00
Dirk Hohndel
02d8c98c93 QML UI: DiveList: always show current trip at the top
This is especially nice for very long dive trips.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-21 11:48:29 -07:00
Dirk Hohndel
9ddd26ff37 QML UI: redo all the colors
Naming them the same way Davide named them in his emails and assigning the
color values he proposed.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-21 11:05:36 -07:00
Dirk Hohndel
16f16f6818 QML UI: DiveList: fix position of delete button
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-21 11:01:37 -07:00
Dirk Hohndel
c775fcebec QML UI: DiveList: turn the color blob into a thin line
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-21 09:55:03 -07:00
Dirk Hohndel
fc4153f8ac QML UI: make title bar taller again on Android
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-21 09:29:24 -07:00
Dirk Hohndel
d7be3b21d6 QML UI: DiveList distinguish trip and selected dive
Making the selected dive's background less opaque prevents confusion.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-21 09:28:40 -07:00
Dirk Hohndel
1d32ebd657 QML UI: use Android palette colors
These were picked from
https://material.io/guidelines/style/color.html#color-color-system

One could argue that we should use different colors for iOS.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 22:51:25 -07:00
Dirk Hohndel
d1ed9c310f QML UI: remove files we no longer use
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 22:49:41 -07:00
Dirk Hohndel
fd5cd5ebf0 QML UI: DiveList: playing with different colors
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>
2017-06-20 16:21:47 -07:00
Dirk Hohndel
7a6f87405a QML UI: disable the MouseArea
Visible doesn't even make sense...

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 13:28:46 -07:00
Dirk Hohndel
20dae442ad QML UI: DiveDetailsView add button for map
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>
2017-06-20 13:28:46 -07:00
Dirk Hohndel
7ccda01e7e QML UI: DiveDetailsView: make key dive info consistent with dive list
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>
2017-06-20 13:06:29 -07:00
Dirk Hohndel
cbcb43247e QML UI: DiveDetailsView: make the lower section less busy
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>
2017-06-20 11:59:51 -07:00
Dirk Hohndel
4f34513277 QML UI: DiveDetailsView: move profile into bottom layout
Then we can remove the main layout and create a similar look as we now have
in the dive list.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 11:57:14 -07:00
Dirk Hohndel
d941384fb6 QML UI: DiveDetailsView: don't underline location
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>
2017-06-20 11:07:09 -07:00
Dirk Hohndel
4a2e21cf7b QML UI: log the font in use
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>
2017-06-20 11:00:01 -07:00
Dirk Hohndel
157e14e11d QML UI: DiveList: some fine tuning of sizes and spacing
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 10:05:45 -07:00
Dirk Hohndel
712d1e97f3 QML UI: DiveList: remove space below trip heading
That made sense before we had the shaded background, now it just looks terrible.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 09:25:07 -07:00
Dirk Hohndel
edd0d2f2bb QML UI: DiveList: don't show empty trip heading for dives without trip
We need to hide the left bar and background rectangle as well.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 09:14:05 -07:00
Dirk Hohndel
a93e3b26d6 QML UI: DiveList: show left bar on dives that are part of a trip
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 09:13:12 -07:00
Dirk Hohndel
a6a9eaa998 QML UI: DiveList: add blue bar on the left to trip heading
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 08:29:06 -07:00
Dirk Hohndel
684354ab6e QML UI: re-indent DiveList code
No actual changes besides whitespace.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 07:49:11 -07:00
Dirk Hohndel
e49301ea21 QML UI: DiveList: add background color to trip heading
In order to make it easier to see the changes, the code hasn't been re-indented.
This will be in the next commit.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 07:49:11 -07:00
Dirk Hohndel
3d8f61fe6c QML UI: turn DiveList heading into label
This way it will render in the same font as the location of a dive.
This will look like crap until the next commit adds a rectangle with
color around it, but this way it's much easier to see the individual
changes.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-20 07:45:16 -07:00
Dirk Hohndel
3d707dca9a QML UI: make the dive list heading slightly smaller
Again, the goal is to make this list look better and be more space
efficient.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-18 18:05:18 -07:00
Dirk Hohndel
d74ef97228 QML UI: less whitespace around dive list entries
This way we get to show a few more dives per screen.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-18 17:38:03 -07:00
Dirk Hohndel
47a01b1dcd QML UI: improve the dive list layout
Based on Davide's ideas, but with a few tweaks:
I really like the dive number on the far right; that gives a clean
consistent look. I tried it with date on the left and depth/duration in
the middle and liked the result.

This doesn't change the font, just addresses the layout and bold heading
vs smaller sub-heading.

See #427

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-18 17:06:53 -07:00
Dirk Hohndel
b2b51c833a QML UI: redesign the user notification
The old system of cloud access updates with fake percentages just wasn't
helpful. Even worse, it hid a lot important information from the user.
This should be more useful (but it will require that we localize the
messages sent from the git progress notifications and make them more
'user ready').

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-17 23:22:37 -07:00
Dirk Hohndel
9db886b8c8 QML UI: explicitly reference parent id
Otherwise we get an odd 'TypeError: Cannot read property of null'
error message.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-17 22:56:08 -07:00
Dirk Hohndel
b45340389b QML UI: better App Log
This should actually scroll and be much simple.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2017-06-16 02:02:00 -07:00