summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2020-06-12pull latest translations from Transifexv4.9.5Gravatar Dirk Hohndel
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-06-12Update ReleaseNotes and README for 4.9.5Gravatar Dirk Hohndel
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-06-08mobile: update version to 3.0.9Gravatar Dirk Hohndel
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-06-08mobile/dive-details: restrict width of tags fieldGravatar Dirk Hohndel
Having a lot of tags (or more precisely, a tags string that is very long) could cause the width of the dive details view to extend past the width of the the page. The txtTags label was missing a maximum width, and to make the result more useful, I also added correct wrapping and elide to the mix (stupidly, we had the wrap and width for the fixed name of the field ('Tags'), but not for the user determined content of that field). Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-06-07mobile: add option to merge local cloud cache dataGravatar Dirk Hohndel
The UI is ugly, and of course this is hidden in the developer options that have to first be enabled in the advanced settings. As I mentioned in the previous commit, I believe the actual risk that something gets damaged here is very low, but still, explaining this so it makes sense to the casual user may be a bit... difficult. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-06-07mobile: add helper to import data from local cloud cacheGravatar Dirk Hohndel
If you pass in the repo name, it isn't treated as cloud storage, but simply as local git storage and imported (i.e., added) to the current dive list. This allows the user to work around failed no-cloud->cloud transitions, merge different accounts, and most importantly deal with situations were conflicts on the server caused us to move a cache out of the way and potentially make dives that were on the mobile device inaccessible to the user. Once a UI is added, this allows the user to recover those dives (realistically this is not really all that potentially 'dangerous' to do, but it's definitely something that would best be done after talking to someone who understands the cloud storage and can guide the user...). Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-06-07mobile: make list of local cloud cache directories availableGravatar Dirk Hohndel
This way QML can show those to the user. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-06-07mobile: tiny whitespace updateGravatar Dirk Hohndel
Every time I edit main.qml, QtCreator fixes this for me. And then I filter it from the commit to not mix white space and actual changes. So let's just get this fixed and move on. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-05-31Fix indentationGravatar Miika Turkia
The diff goes crazy if indentation is not fixed by itself. Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-31Print empty cylinder, if neededGravatar Miika Turkia
When the dive that is used to generate the header, we need to print empty cylinders for the dives that had less cylinders than the one used for header printing. Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-31Print at most as many cylinders as the header hasGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-31Limit cylinders to one dive onlyGravatar Miika Turkia
With XSLT we have to be specific if we want to apply cylinder iteration operation to one dive only. Thus using the last dive as reference when printing cylinder header. Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-30mobile: update version to 3.0.8Gravatar Dirk Hohndel
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-05-30mobile/dive-edit: fix broken editable combo boxesGravatar Dirk Hohndel
This is a partial revert of commit 99438121c4 ("mobile/dive-edit: use template components and theme colors") Clearly the information given in the Qt documentation on how to theme ComboBox is flat out broken. The trade-off between 'better dark theme' and 'broken user experience' is fairly easy to make. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-05-29cleanup: make local functions of static linkageGravatar Berthold Stoeger
A few functions in save-html.c were local but not marked as static. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-27cleanup: remove QCalendarWidget forward declaration and includeGravatar Berthold Stoeger
This is an artifact of code that never came to be. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-27cleanup: unglobalize grayImage()Gravatar Berthold Stoeger
This function was globalized in be462ae1a6 to be used for the calender widget, but that never came to be. Therefore, for now unglobalize it until it is needed. That said, there probably is a helper function to turn pictures into gray-scale. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-27Android: install translations into the right placeGravatar Dirk Hohndel
When updating the NDK I forgot to adjust the install destination for the translations. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-05-27cleanup: un-singletonize ShiftTimesDialogGravatar Berthold Stoeger
There is no reason that this dialog is a singleton. Since it is modal, it can be created on demand. Apart from removing superfluous global state, this simplifies code, because preparing the widget can now be done in the constructor instead of overriding the showEvent() function. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-27cleanup: un-singletonize RenumberDialogGravatar Berthold Stoeger
There is no reason that this dialog is a singleton. Since it is modal, it can be created on demand. This simplifies code, because the mode (selected-only or all-dives) can be set in the constructor. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-26Update changelogGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-05-26Fix precision bug on SubsurfaceCSV importGravatar Miika Turkia
We need decimal point as size is stored with one decimal on imperial export. Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Remove debug outputGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Add dive mode support for SubsurfaceCSV importGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Fix field indexes after dive mode and sac changeGravatar Miika Turkia
We need to update field numbers when parsing CSV, as recently sac and dive mode were added. Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26CSV import: add SAC if we end up supporting itGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Test case for multicylinder support on CSV importGravatar Miika Turkia
Test for importing Subsurface generated CSV dive details, with multiple cylinders support. Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26XML start tag does not have new line before headerGravatar Miika Turkia
When Subsurface adds start tag to CSV file, there is no new line after it. Thus changing XSLT to parse this way. Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Print correct template name on CSV exportGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Trip support for CSV export of dive detailsGravatar Miika Turkia
Debugging the tests with new test dive, I noticed that CSV export does not work, if the exported XML includes trips. Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Use single cylinder dive for testsGravatar Miika Turkia
Now that CSV export supports multiple cylinders and import doesn't, we need a test dive with single cylinder in it. (Multi-cylinder import from CSV will be supported for Subsurface style CSV export only, and not generic exports that are used here.) Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Initialize variable to silence compiler warningGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Add multicylinder support for Subsurface CSV importGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Take SAC into account on SubsurfaceCSV importGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26Multi cylinder support for CSV exportGravatar Miika Turkia
Fixes #2830 Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-26CSV export: Split printing of headerGravatar Miika Turkia
This will split the printing of header for CSV export. Cylinder information is printed by itself allowing me to later print it in a loop as many times as there are cylinders. Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
2020-05-25mobile/credentials: email address must be lower caseGravatar Dirk Hohndel
I could have sworn that I have fixed this several times in various places, but apparently (as shown by todays support emails) it's still possible to setup a mixed case email address. So let's try to solve this problem at the very top. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-05-25cleanup: whitespace fixes in TabDiveInformationGravatar Berthold Stoeger
Use C-style function definitions (squirly brackets on new lines) and remove empty lines at end of file. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-25desktop: localize salinity valueGravatar Berthold Stoeger
The salinity value was not displayed with localized thousands separators. E.g. to a user of a German locale the density read as slightly over 1 g/l, when it should be approximately 1000 g/l. For consistency, also localize that value. Also localize the CNS and OTU numbers, even though these should (hopefully!) never come with thousands separators. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-22cleanup: constify time_during_dive_with_offset() functionGravatar Berthold Stoeger
There is no reason to pass a non-const dive pointer as first argument. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-22cleanup: remove unused function get_dive_n_near()Gravatar Berthold Stoeger
The last caller was removed in 7eb422d98837b3cfb289a66fa0f3a8f78f222001. Since this is the only caller of dive_within_time_range(), remove that function as well. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-22cleanup: create common QDateTime -> timestamp conversion functionGravatar Berthold Stoeger
In analogy to the timestamp -> QDateTime conversion, create a common function. 1) For symmetry with the opposite conversion. 2) To remove numerous inconsistencies. 3) To remove use of the deprecated QDateTime::toTime_t() function. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-22cleanup: remove unused libc-structures from get_trip_date_string()Gravatar Berthold Stoeger
This must be an artifact from before using Qt's datetime functions. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-22cleanup: move timestampToDateTime() to qthelper.cppGravatar Berthold Stoeger
Move this function from maintab.cpp to qthelper.cpp. Since the functionality was used in numerous places, use the helper function there as well. This removes a number of inconsistencies. For example, sometime setTimeSpec(Qt::UTC) was called, even though the QDateTime object was already created with that time spec. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-22Fix incorrect Farenheit to Kelvin formula.Gravatar Paul Buxton
Use defined function instead. Signed-off-by: Paul Buxton <paulbuxton.mail@googlemail.com>
2020-05-22desktop: update date and time fields if user changes formatGravatar Berthold Stoeger
This was more painful than expected, because we get the "preferences" changed signal too early when the user switches to system format. The correct format is set by the preferences-widget, not the preferences subsystem. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-22desktop: refresh date/time format when switching to system defaultsGravatar Berthold Stoeger
When switching to system defaults, refresh the fields in the preferences UI so that the user can tell how the fields will be formatted. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-22cleanup: set long and short date formats in independent branchesGravatar Berthold Stoeger
The short and long date formats where initialized in a common if-branch. However, inside the if-branch the code rechecked which of the two should be initialized. This could make sense if there was some common code between the two, but there wasn't. Therefore, make this two independent branches to avoid one nesting-level. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
2020-05-18update CHANGELOGGravatar Dirk Hohndel
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2020-05-18mobile/dive-edit: use template components and theme colorsGravatar Dirk Hohndel
Another small step to make the dark theme at least marginally useful. We now use our template components and add the necessary elements to have consistent text color. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>