This appears to fix the mystery crashes that can occur when deleting a dive
from the dive list.
Fixes: #497
Signed-off-by: Rick Walsh <rickmwalsh@gmail.com>
This gets rid of TypeError messages, but does not appear to affect behaviour
qrc:///qml/DiveDetailsEdit.qml:254: TypeError: Cannot read property 'dive' of null
qrc:///qml/DiveDetailsEdit.qml:228: TypeError: Cannot read property 'dive' of null
qrc:///qml/DiveDetailsEdit.qml:216: TypeError: Cannot read property 'dive' of null
qrc:///qml/DiveDetailsEdit.qml:204: TypeError: Cannot read property 'dive' of null
Signed-off-by: Rick Walsh <rickmwalsh@gmail.com>
MapWidgetContextMenu now has a new action (SELECT_VISIBLE_LOCATIONS),
that will invoke the MapWidgetHelper method selectVisibleLocations().
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
First, this function calculates the zoom out effect until both the
current Map center and the target rectangle are visible - see the
"calculate zoom out" part.
Then it calculates a zoom level, so that the target rectangle
fits the viewport, but also so that the zoom is not too much (clamped).
see the "calculate zoom in" part.
NOTE: "centerStored" (the variable used to store the current map center)
is created using QtPositioning.coordinate(), because the code needs a new
object and not a reference of the map.center QGeoCoordinate object.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Add stopZoomAnimations(), which is really just a precaution
function to make sure we have stopped all animation of the
map before doing calculations! Since the animation *should*
be running in a separate thread, this would make sure the Map "center"
and "zoomLevel" properties do not change.
Add pointIsVisible(), which is a helper to determine
if a point created by map.fromCoordinate() method is inside
the viewport. fromCoordinate() has to be called without the
"false" (clip) flag for this to work.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
MapWidgetHelper::centerOnDiveSite() now checks if more than
one dive sites are selected and finds the most top-left and
bottom-right ones in the coordinate system to form
a rectangle.
It also supports the special cases where a selected dive site
does not have coordinates or the case where only a single dive site
with GPS coordinates are selected.
TODO: implement mapwidget.qml::centerOnRectangle()
This QML function will receive a QGeoCoordinate based rectangle which
has to be centered in the viewport with animation.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
For instance, if the 'googlemaps' geoservices plugin is missing
a new message is now shown:
"qml: MapWidget.qml: cannot find a plugin with the name 'googlemaps'"
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Do so until the following issue is resolved:
https://github.com/vladest/googlemaps/issues/9
With the satellite map ([1]), the black tiles at relatively high
zoom levels over the Red Sea cannot be seen. Instead it shows white
tiles at the ultra-maximum zoom level at places.
As a side note, the "satellite" map does not have the country labels
which the "hybrid" map has.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
No idea why this was restricted to be so narrow. Also, making
the font of the label smaller and lighter seems visually more
pleasing.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This makes sure that the autocompleting comboboxes never displays the scroll list where the user can pick an entry, and as such forces the view of a autocompleting textfield from the users point of view. The reasoning is that when scrolling in the drop down list it it possible to scroll to far and thus abort the ongoing edit by flicking away the edit page.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Mobile devices hare rather limited when it comes to screen size,
there is no point in reducing the availabel space more than neccecary.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
This handles a cornercase where a user starts editing and then cances the divedit followed by a return to edit mode. The previously acive textfield would then be active again even though all changes are lost.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
For some reason the textfields on dive edit page did not loose focus when editing ended by press on the return key.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
When the user makes a selection using the autocomplete function while editing a dive the keyboard should close and the selection list should disappear.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Add star icons from the material repository.
https://material.io/icons/
The icons are under Apache License Version 2.0
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
This patch makes use of the geolocation plugin "googlemaps"
for Qt Location with source code from here:
https://github.com/vladest/googlemaps
The change from the ESRI plugin is that it requires new indexes
for the Hybrid ([3]) and Street ([0]) map types.
There are more zoom levels in this plugins, but our default zoom-in
settings seem to transition well to it.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The C++ side for the desktop version already does that. Add a slot
for that in QML, for later use in the mobile version.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The editing support is added via dragging. It is handled via the
MouseArea's drag.target of the MapQuickItem. The drag target changes
with the model selectedUuid.
"mapAnimationZoomIn" now also does an initial zoom-out before moving
to a new location.
centerOnCoordinate() now pefroms calculations to determine how much
the animation needs to zoom out. What it does is it reduces the Map
zoomLevel util both the current and the new target coordinates are visible.
It then restores the zoomLevel and performs animation based on newZoomOut.
animateMapZoomIn() is now obsolete.
The patch also includes the following smaller changes:
- remove the setSelectedUuid() call in deselectMapLocation()
This is now handled in C++
- sets "defaultZoomIn" to 12.0
- use ">=" when determining if a mapItem text should be visible
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The MapWidgetHelper QML instance now has the slot onEditModeChanged()
which toggles the visiblity of a newly added message box that
notifies the user if editing mode is enabled.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Call setSelectedUuid() from C++ also center on coodinates instead
on a MapLocation, as there is no point to pass the MapLocation object
back to QML.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The MapItemView delegate now includes a white Text element.
It uses the MapLocation "name" property as text.
This text is only visible if the map zoom is above "textVisibleZoom".
For hundreds of dives, using the DropShadow effect for the text
makes it laggy. Instead, using a fake drop shadow (duplicate black
Text under the default text) makes it much better.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The buttons are positioned bellow the "toggle map type" button
and increment / decrement the zoom by "zoomStep" (2 for now).
Also clamp the zoom-in level to "map.maximumZoomLevel".
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Double clicking a marker or the newly added MouseArea now performs
a +2 zoom-in over a period of 500ms and centers on that clicked
coordinate.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Different actions might be performed depending on the count of selected
dives - e.g. deep zoom only for a single selected dive.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The signal emits a QList<int> filled with dive idexes from the
main backend dive table.
The MapWidgetHelper QML instance handles that in onSelectedDivesChanged().
This will only be needed for the mobile version, as the desktop version
should connect it's own slot in MapWidget.cpp.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The idea of this flag is to be able to only to emit the
selectedLocationChanged() signal when the user clicked on the map
(fromClick == true).
MapWidgetHelper::selectedLocationChanged() listens for this signal
and only then it will select nearby dives based on a "small-cicle".
If "fromClick" is false, it's the backend or the dive list that
updated the selection and MapWidgetHelper::selectedLocationChanged()
should no be called.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Each time the zoom changes MapWidgetHelper::calculateSmallCircleRadius()
is called, and the "small circle" radius is stored in both C++ and QML.
On the C++ side this radius will be used to select multiple nearby
dives.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
openLocationInGoogleMaps() now can be used to open a URL in an
external browser, triggered by the context menu. Use the same
Google Maps URL formating as in main.qml showMap().
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The actionSelected() signal is now dispatched when the user selects
an action from the menu (see the "actions" object). Then the declaration
of the MapWidgetContextMenu object in mapwidget.qml can catch that
signal in the onActionSelected() slot and obtain the action via
switch() branching.
The actions enumeration is kept in QML for now, with the idea that
specific C++ methods from the mapwidgethelper class will be called
directly (if marked as Q_INVOCABLE), instead of a generic
onMapAction(action) C++ method in the helper. But if the actions
are possible from QML (like copying to clipboard) and are also
small and non-expensive, it might be better to keep them
in mapwidget.qml.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
- move the readonly properties near the top of the root Item
- move the rest of the properties bellow the readonly properties
- make the ListView Timer as a child of the ListView
- slight rename of the timer ID
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
NOTES:
- the ListView object uses lsitItemDelagate to display all elements from
the model listModel
- onCountChanged() is used to adjust the x position based on the
maxItemWidth property which is calculated when the items are populated
with text
- onVisibleChanged() is used to deselect the last selected item by
calling listModel.selectedIdx = -1
- onOpacityChanged() i sued to make sure that the View is hidden if the
opacity becomes 0.0
- inside the View there is a MouseAre which obtains the selected item via
indexAt(x,y)
- there is a Timer with id listViewVisibleTimer, which is called each
time the user selects an item from the list and the timer performs a
"delayed hide"
- a couple of State and a Transition objects are used to preform smooth
fade-in / out animation when the ListView is hidden or becomes visible
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
This property would act like a state flag. If -1 (default) no QML State
animation will be pefromed, otherwise the ListView will either fade in
(1), or fade out (0) when the user clicks the context menu button
(Image) or selects an item from the list.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The ListView delegate is a simple Component with a parent Rectangle.
It contains a text field with the ListView action.
This patch also defines some properties for the delegate animations
and looks. The property maxItemWidth tracks the width of all item
text, and makes the width of all items be of that value.
The above prevents potential issues when a fixed width item is used
and some translated language string cannot be fit inside of it.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Menu item indexes are enumerated in the object menuItemIndex, while
menuItemData, holds an array of objects which will define the number
of items, with indexes (idx) and text (itemText).
When the ListModel is created, it's dynamically populated from
from menuItemData.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The anchor of the menu itself will be positioned near the edge of the
map widget, while the menu contents will have negative coordinates.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
This QML component will be used to provide a context menu for the
QML map widget. Include the file in QRC and test it's creation
in MapWidget.qml.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Make the "enumeration" local to the Map object for now.
This will possibly break if another plugin is used in place of the
ESRI plugin, but it will simplify the map toggle button which is about
to be implemented next.
If support for multiple plugins is added on runtime a simple
helper function will be needed that will check the current plugin "name".
And return the appropriate supportedMapTypes[X] for e.g. STREET of that
plugin.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The QML based map will have a toggle in the top left corner to toggle
between the satellite and steet tiles.
The images are created specifically for use in this Qt Location widget
and are free for use in Subsurface.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The animation sequence when deselecting a zoomed in map location, should
be:
- zoom out completely
- pan to center
To achieve that a new animation object is created - "mapAnimationZoomOut"
The previous zoom in animation is renamed to "mapAnimationZoomIn".
The map functions centerOnMapLocation() and deselectMapLocation()
now call the helper functions animateMapZoomIn() and animateMapZoomOut().
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
It's best to only animate the flags when clicked, thus play the animation
in the onClicked() slot from the MouseArea.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
To be used to center the map on a dive location or reset the map
if a dive from the dive list doesn't have GPS coordinates.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
When centering on a map location, use the predefined zoom
map.defaultZoomIn.
Later the map should be able to center on (0, 0) and zoom-out
if a dive doesn't have GPS data.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The rest of the QML code in subsurface doesn't use the ';' to
end a line of code or a declaration. Remove all the redundant ';'.
Also clean extra blank lines.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
If a marker is clicked it's source image changes, which will
call the onSourceChanged() slot. If a marker is selected
play the newly added sourceItemAnimation which is a short scale
animation for the image.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
These properties will be used when zooming-in on a map location
or when zooming out if no map location is selected.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The function in QML centerOnCoordinate() is now renamed
centerOnMapLocation() and accepts a MapLocation object, so that
a marker is selected (based on UUID).
In MapWidgetHelper::centerOnDiveSite(), the pointer to a MapLocation
is retrieved via MapLocationModel::getMapLocationForUuid(). Added in the
previous commit.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Add a MouseArea to the MapItemView delagate and onClick set
the "mapHelper.model.selectedUuid" to the uuid of the clicked marker.
This updates the "selectedUuid" property inside MapLocationModel.
Based on "mapHelper.model.selectedUuid" it is now possible to
show two seprate images for selected / deselected markers.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The image for the unselected marker is now a slightly darker flag.
Same behaviour as the current Marble implementation.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Rename the QML function "centerOnCoordinates" to "centerOnCoordinate"
and pass a QGeoCoordinate to it in ::centerOnDiveSite().
This will prevent the creation of a QGeoCoordinate object on the
QML side and instead it will be created in C++.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Instead of maintaining a seperate latitude/longitude values
in C++ and passing them to QML separatelly, pass them as a QGeoCoordinate.
This reduces the number of model "roles" and also prevents the creations
of extra objects in QML (e.g. via QtPositioning.coordinate(..)).
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
MapItemView is the QML class that handles the "create map markers based
on a model". In this case the model is created as part of the
MapWidgetHelper, so here passing "mapHelper.model" to the "model"
property is enough.
The delegate receives coordinates from the model as "model.latitude",
"model.logitude" and converts them to QGeoCoordinate.
The "sourceItem" image for the delagete is just an image ATM and is
fetched from QRC.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
When calling centerOnCoordinates() the map will now animate over a
period of 3 seconds the zoom level and over 2 seconds the center
of the map.
Can be tweaked and improved later on.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
This function can be called to center the map on a specific coordinates.
For the C++ version call it via QMetaObject::invokeMethod() in
centerOnDiveSite().
TODO: add QML property animations.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The idea here is that the Map object can be controlled from C++ via
the "m_map" private member. Also, for the mobile version, QML code can
call the same C++ methods (if marked as Q_INVOCABLE).
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
This instance in the QML code itself will be accessed by both the
mobile and desktop version. That way, the map code between
the two Subsurface versions will be shared.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Add a local "enumeration" (object) for the two possibly map types
of interest: SATELLITE and STREET.
Use SATELLITE by default.
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
The root element is now an Item and also doesn't have explicit
anchors and dimensions as these will be handled by the parent:
- on desktop: a QQuickWidget
- on mobile: any QML based QQuickItem
Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Like the subject says. We do not want the password to be made
visible, so a switch to show it, is useless and is therefore
removed. Futher, the entry mode is set to PasswordEchoOnEdit,
which causes the passwd to be visible (for easy entry), but
can't be made visible again after save/end edit.
Fixes: #512
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
Kirigami prevents us from altering the color of the gps icon in the action menu. So let's display an gps fix icon in the lower left corner of the drawer when the location services is running, colored to match the themes primary accent color.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Not the lsit is much more compact and shows a lot more dives even on
smaller screens. And it's similar in style to the dive list.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Replace the theme checkboxes on the settings page
so that we get a unified UI.
These switches are linked and as such can only be activated
deactivation occurs when the user selects another theme.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Move the location services switch to the GPS menu, indicate both with icon and text if the service is active or not.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Strangely, a click/tap anywhere else worked as expected, but if you hit
exactly on the checkbox, the status change wasn't propagated.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
In stead of using the fixed 4 column code introduced in f2fcad89b0db9b164d8fd3f89218ad27ca362bd3 use percentages of page width to allow for a more flexible layout since no block really has 4 columns.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Automatically save changes made on the settings page on completion of text fields or theme checkboxes.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Put all GPS settings in one block and revert to a 2 column layout while maintaing the 4 column widh.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Addresses: #492
Signed-off-by: Rick Walsh <rickmwalsh@gmail.com>
Had a bit of rebase issue with this one.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
New icons for the dive management sub-menu
ttps://material.io/icons/
The icons are under Apache License Version 2.0
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Add a couple of icons from the material repository.
https://material.io/icons/
The icons are under Apache License Version 2.0
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Add a checkbox to the preferences page to facilitate selective visibility of the developer menu. With the coresponding function in qmlmanager.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Fixes: #490 items 1) and 2).
1) Reference to isBluetooth.leftPadding is removed as the isBooltooth
checkbox is gone.
2) Do not set background color of downloaded dives. The checkbox is used
to denote "selected or not".
In addition, incorrect references to subsurfaceTheme.PrimaryColor (which
does not exist) are replaced by the correct subsurfaceTheme.primaryColor.
Finally, an obvious copy/paste error width: childrenRect.height. that
is supposed to be width: childrenRect.width.
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
This commit adds the capability to cancel a running download from DC.
The actual cancel is fully handled in the underlying libdivecomputer
code. As the user may be interested in the dives downloaded up to
the moment of cancel, do not just close the download screen (as
it was before this commit). Now, the <quit> button changes to
<cancel> when the download is started, and pressing cancel, only
cancels the download and does not close the download screen, but
presents the so far downloaded data. When no download is running,
the <quit> button just quits the screen as before.
Fixes: #485
Signed-off-by: Jan Mulder <jlmulder@xs4all.nl>
The connection already clearly defines whether this is Bluetooth or not.
No reason for the separate checkbox.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
I wonder if we even need this anymore at all as the connection
clearly determines whether this is a BT download or not.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
If we can't find a match, just leave it unchanged. This way, if we
mis-recognize a device, the user can correct the product (or even
vendor) without losing the correct connection.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Add styling to the GPS fixes page.
The background color of the swipe list objects is wrong and also the icon overlay. This is a Kirigami issue.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
The built in theme in Kirigami has special variables for sertain objects, this sets the correct color for each object to match our themes.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
THe editable textboxes rely on the material theme to set the correct colors. This sets the appropriate colors for each theme.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
This hides the text for the map it button if ther are no coordinates for a dive. Needed as for the dark theme the map it text was still visible.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
This adds the right handle icon that is needed for the swipe list items not to report an error when activated.
Signed-off-by: Joakim Bygdell <j.bygdell@gmail.com>
Right now we need to restart Subsurface-mobile in order to detect
Bluetooth devices - so simply turning on BT after Subsurface-mobile was
started is not sufficient.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit only has the actual changes, the next commit will clean up
the white space in order to make it more obvious what was done.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
These buttons only work when we successfully downloaded a dive. Also, don't
show a list of dives when there are no dives.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
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>