summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2019-12-24build-system: Add CMakeLists.txt to map-widgetGravatar jan Iversen
In order to make the central CMakeLists cleaner and more consistent add a CMakeLists.txt to map-widget, like in other root directories. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-24build-system: move qmlprofile to profile-widgets/CMakeLists.txtGravatar jan Iversen
qmlprofile.* is part of profile-widget, and are now defined in the the corresponding CMakeLists.txt, and thereby making the central CMakeLists.txt cleaner. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-24build-system: correct spelling error in build.shGravatar jan Iversen
the location of libdivecomputer is not subsurface/llibdivecomputer Correct spelling error. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-24Cleanup: Turn QMLProfile::diveId from QString to intGravatar Berthold Stoeger
This property is used to render the profile of a given dive. Weirdly, even though the diveId is an integer, it was stored as a string. It is not clear why that is the case. Therefore, turn into the more natural int and avoid unnecessary conversion. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2019-12-24build system: add forgotten directory to xCode projectGravatar jan Iversen
Add tests to xCode project. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-24release doc: update CHANGELOG.mdGravatar jan Iversen
add info about qml compiler Signed-off-by: Jan Iversen <jani@apache.org>
2019-12-24build-system: iOS, activate qml compilerGravatar jan Iversen
Activate use of qml compiler, which provides: - more error detection at compile time - fast qml - smaller footprint Signed-off-by: Jan Iversen <jani@apache.org>
2019-12-24mobile-widgets/qml: remove use of eval()Gravatar jan Iversen
eval() cannot be used in combination with the Qt5 qml compiler, replace eval() with switch statements. Signed-off-by: Jan Iversen <jani@apache.org>
2019-12-21Update libdivecomputerGravatar Dirk Hohndel
Add initial support for the Oceanic Pro Plus 4 Fix the Oceanic Geo 4.0 memory layout Ignore all empty logbook entries Add a workaround for the hwOS ppO2 firmware bug Use macros to encode the firmware version Use symbolic constants for the sample types Remove the obsolete hwos parameter Limit the tank pressure workaround to hwOS devices Fix the OSTC tank pressure decoding Fix the Scubapro G2 HUD udev rule Add the Mares Genius to the bluetooth filter Add firmware upgrade support for the Ratio computers Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2019-12-18build-system: iOS, change location of 3rd party buildsGravatar jan Iversen
move location of 3rd build to follow same pattern as desktop/mobile build update central .gitignore to silence libdivecomputer/build-ios, this should really be in libdivecomputer, but it is more easy to put it in a subsurface controlled file. Signed-off-by: Jan Iversen <jani@apache.org>
2019-12-18build-system: iOS, change location of install-rootGravatar jan Iversen
move from build-ios/install-root/<arch> to SSRF_CLONE/install-root/ios/<arch> move fat libraries, include and bin to SSRF_CLONE/install-root/ios Call "make" and not "make qmake_all" which is just a FORCE dependency. Signed-off-by: Jan Iversen <jani@apache.org>
2019-12-18build-system: iOS, use ~/QtGravatar jan Iversen
packaging/ios/build.sh expected a link ./Qt to the Qt installation. scripts/build.sh expect ~/Qt to contain the Qt installation change to ~/Qt and thus no longer need link Signed-off-by: Jan Iversen <jani@apache.org>
2019-12-18mobile-widget: use qPref variableGravatar jan Iversen
change prefs.cloudUserName to PrefCloudStage.cloud_storage_email. This is slightly more effective (direct instead of indirect), and reduces the use of prefs. This is part of limiting the use of prefs. (which is a precessor to qPref) to the login process, and ultimately remove it. Signed-off-by: Jan Iversen <jani@apache.org>
2019-12-18mobile-widget: correct set of default_cylinderGravatar jan Iversen
set_default_cylinder is accepted, because it is defined in Qt Meta system, however the call is never carried out, because the Q_INVOKE macro is missing Change PrefGeneral.set_default_cylinder(...) which is a function call to PrefGeneral.default_cylinder = ... which is a builtin assignment Signed-off-by: Jan Iversen <jani@apache.org>
2019-12-16Stop Compiler Warning: Change struct to classGravatar Robert C. Helling
Signed-off-by: Robert C. Helling <helling@atdotde.de>
2019-12-13Coding style: use std::equal_to instead of lambdaGravatar Berthold Stoeger
Use std::equal_to instead of lambdas that compare two dive pointers. One could argue over which version is more readable. For whatever it's worth, std::equal_to is more compact and expressive. This removes an old erroneous comment that stated that std::equal_to is only available since C++14. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2019-12-13core: remove LOG_STP from mobileGravatar jan Iversen
LOG_STP is on longer providing the data needed, since a lot of the startup is indirectly in QML, furthermore using the xcode project and running profiler gives much more detailed information Signed-off-by: Jan Iversen <jani@apache.org>
2019-12-13qt-models: remove LOG_STP from mobile/desktopGravatar jan Iversen
LOG_STP is on longer providing the data needed, since a lot of the startup is indirectly in QML, furthermore using the xcode project and running profiler gives much more detailed information Signed-off-by: Jan Iversen <jani@apache.org>
2019-12-12release doc: add to CHANGELOG.mdGravatar jan Iversen
Upload to dive-share is now available in mobile Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-12mobile/qml: Integrate/activate diveshare in ExportGravatar jan Iversen
Integrate diveshare in Export Activate diveshare radio button Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-12mobile-widgets: activate uploadDiveShare in qmlmanagerGravatar jan Iversen
Remove "TO BE IMPLEMENTED" and add call doUpload Connect signal to signal in QMLManager to avoid registring the upload class. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-12mobile/qml: Clear status field in ExportGravatar jan Iversen
When opening the saveAsDialog a second time, it contains the last status from first time. Clear statusText before calling saveAsDialog Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-12core: divehare avoid race problem.Gravatar jan Iversen
Do reply->readAll() before reply-deleteLater() With UI deleteLater() seems to happen after the function exist, but with QML it causes problems. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-12core: divehare change slot namesGravatar jan Iversen
change slot names from slot_* to *Slot Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-12mobile/qml: make close dialog in Connect workGravatar jan Iversen
When using Connect, the context is switched, so close() might or might not work. Change unqualified close() to qualified uploadDialog.close() Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-12mobile/qml: remove empty lineGravatar jan Iversen
Remove empty line that does not make sense. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-12core/settings: qPrefCloudStorage, correct diveshare_uid namingGravatar jan Iversen
The variable in Q_PROPERTY was wrongly named diveshare_userid change diveshare_userid to diveshare_uid Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-12core: uploadDiveLogsDE::prepareDives no longer need to be publicGravatar jan Iversen
Integration into desktop-widgets is complete. Move prepareDives() from public to private Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-12build system: make INSTALL_ROOT depend on BUILD_PREFIX as wellGravatar Dirk Hohndel
This makes things more consistent. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2019-12-12build system: fix most shellcheck warningsGravatar Dirk Hohndel
A couple are still there, but this was the low hanging fruit. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2019-12-12build system: do something more reasonable if subsurface is a symlinkGravatar Dirk Hohndel
This actually changes behavior compared to what we did before. But it seems reasonabel. If ./subsurface is a link to a different directory, then assume that we want a true out of tree build in the current directory. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2019-12-12build-system: allow shared source across multiple hostsGravatar Dirk Hohndel
This attempts to allow sharing a host directory across multiple builds, target use case is to have a shared source directory on a VM host and be able to build from that in a number of VMs without those builds stepping on top of each other. Instead of subsurface/build, subsurface/mobile-build, subsurface/libdivecomputer/build, use a prefix path to allow having true out of tree builds. The one shortcoming is that the autotools need to be run in the libdivecomputer directory - that means this will be run on the first system that starts a build. But that seems to cause no harm in my testing. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2019-12-11mobile/qml: close upload dialog if successGravatar jan Iversen
Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11core: corrected timeout and error text problem in uploadDiveLogsDEGravatar jan Iversen
incorrectly stopped timer before the upload was started. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11desktop-widgets: divelogsDE: integrate shared backendGravatar jan Iversen
Use doUpload() from uploadDiveLogsDE Connect signals from uploadDiveLogsDE to do UI part. Clean slots to only contain UI. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11core: add uploadStatus signal to uploadDiveLogsDEGravatar jan Iversen
The uploadStatus signal can be used to inform the user about the process e.g. - preparing zip file - starting actual upload It is a suplement to uploadProgress, that only informs about the network part. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11desktop-widgets: divelogsDE: delay handling until user select uploadGravatar jan Iversen
Do not prepare zip file, just because user selected the divelogs.de radiobutton Move prepareDives to startUpload (slot handling user clicking on upload button). Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11desktop-widgets: split UI and network in DivelogsDeWebServices (prepare)Gravatar jan Iversen
Clean prepareDivesForUpload() and uploadDives() so that uploadDives() only contain network handling no UI. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11core: make uploadDiveLogsDE slots workable for desktopGravatar jan Iversen
Secure that the slots/signals in uploadDiveLogsDE, which are without UI, can be used in DivelogsDeWebServices (to add the UI part). Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11desktop-widgets: use qPrefCloudStorage instead of QSettingsGravatar jan Iversen
Use qPrefCloudStorage for divelogde_user/password to secure same handling as other settings, as well as same handling as used in shared uploadDiveLogsDE class Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11desktop-widgets: remove code under RM_OBSOLETE_CODE ifdefGravatar jan Iversen
history, and it is disturbing in "diff". Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11core: rename slot in uploadDiveLogsDEGravatar jan Iversen
The difference between slot names and signal names was to insignificant e.g. uploadFinish (signal) uploadFinished (slot). Change slot names to slot_<name> should clear any confusion. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11desktop-widgets: use uploadDiveLogsDE::prepareDivesGravatar jan Iversen
Remove local implementation (prepare_dives_for_divelog) and call uploadDiveLogsDE::prepareDives, which are shared between mobile and desktop Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11core: make prepareDives public in uploadDiveLogsDEGravatar jan Iversen
prepareDives needs to be public, in order to be used in subsurfacewebservices. "friend" is another option, but that gives subsurfacewebservices too much freedom. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11core: make shared prepareDives identical to desktop prepare_dives_for_divelogsGravatar jan Iversen
In order to replace DivelogsDeWebServices::prepare_dives_for_divelogs with uploadDiveLogsDE::prepareDives, first step is to make the functions identical. amount_selected is not maintained for mobile, add #ifdef SUBSURFACE_MOBILE Add comment, to make code more readable add white line to make code more readable change to use variable ds (created a couple of lines earlier Avoid "goto" by adding close code Remove label and close code (it was only called in 1 place) Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11core: correct QString arg problemGravatar jan Iversen
use report_error directly, instead of making a QString first, argument syntax are different (%s vs. %1) Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11release doc: add to CHANGELOG.mdGravatar jan Iversen
Upload to divelogs.de now possible with limited error/success reporting. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11core: add timeout.stop() if upload successfulGravatar jan Iversen
Stop timeout not only in case of errors, but also in positive case. Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11mobile/qml: handle upload signalsGravatar jan Iversen
Add uploadFinish and uploadProgress to Export page Signed-off-by: Jan Iversen <jan@casacondor.com>
2019-12-11mobile-widgets: make upload signals available to QMLGravatar jan Iversen
Connect signal to signal in QMLManager to avoid registring the upload class. Signed-off-by: Jan Iversen <jan@casacondor.com>