The last SIGNAL/SLOT cannot be converted due to a limitation in the
new connect() syntax, it does not "understand" default parameters.
Signed-off-by: jan Iversen <jan@casacondor.com>
Change connect for QAbstractButton::clickedto new syntax.
Change connect for QDialogButtonBox::accepted/rejected to new syntax.
Signed-off-by: Jan Iversen <jan@casacondor.com>
correct SLOT was sec_bottomsac(double), which
is not reported as an error.
correct to set_bottomsac(double)
Signed-off-by: Jan Iversen <jan@casacondor.com>
QSignalMapper gives a warning that it is depreciated, and the
doc. states that using a lambda function is more efficient.
Replace use of QSignalMapper.
Signed-off-by: Jan Iversen <jan@casacondor.com>
QSignalMapper had a parameter convert problem, when mapping to
set_deco_mode in plannerShared.
Use lambda function in connect to avoid parameter convert problem.
Signed-off-by: Jan Iversen <jan@casacondor.com>
There were two cases that were handled incorrectly:
- if the user hasn't entered a salinity, obviously there shouldn't be a warning
- if this is a manually entered dive, there is no salinity downloaded from a
dive computer, so equally, no warning
Suggested-by: willemferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
We need to show this whenever the value in the dive (which could have been
entered by the user some other time) doesn't correspond to the value in the DC.
This, btw, will point out to the user if different DCs have different values.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
We were royally confused when we didn't know the salinity value (e.g., if the
dive computer didn't provide that information). We somehow treated this as the
same as wanting to use the salinity information in the dive computer. Which
makes no sense.
While cleaning this up, this also adds the textual representations of the water
types as a string list that corresponds to the enum values that we use - this
way it's easier to stay consistent.
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Added code for string translation.
Added code to improve UI on Windows.
Added some comments to make the code more understandable.
Enable salinity combobox for manually entered dives
Signed-off-by: willemferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
The user may modify the salinity by selecting a water type from the combobox.
The new datum does not replace the existing salinity value but is stored in a
separate variable within the dive structure. If the dc-based salinity is
overwritten, there is an exclamation mark next to the modified salinity value
to indicate that the salinity has been overwritten. The dc-derived salinity can
always be recovered by selecting the "use dc" option in the combobox.
Signed-off-by: willemferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Create a checkbox in the Preferences: General screen that enables or disables
editing of the salinity data. This preference is saved with all the other
preferences.
Signed-off-by: willemferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This is a cosmetic update to remove some warning messages
while building a fresh subsurface. These warnings were due to
duplicate label names in the .UI files.
Signed-off-by: willemferguson <willemferguson@zoology.up.ac.za>
Use plannerShared setter to update the variables in qPref.
This will also signal the cylindermodel to calculate a new bestmix.
variables:
bottompo2
decopo2
bestmixend
Signed-off-by: Jan Iversen <jan@casacondor.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Use plannerShared setter to update o2narcotic. This will also signal
the cylindermodel to calculate a new bestmix.
Signed-off-by: Jan Iversen <jan@casacondor.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
variables
bottomsac
decosac
problemsolvingtime
sacfactor
are not set in diveplanner.cpp, but instead
signals a slot in plannerModel.
change signals to slots in plannerShared
Signed-off-by: Jan Iversen <jan@casacondor.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
variables
min_switch_duration
are not set in diveplanner.cpp, but instead
signals a slot in plannerModel.
and are read from plannerShared which includes a conversion
change signals to slots in plannerShared
change read from prefs. to plannerShared
Signed-off-by: Jan Iversen <jan@casacondor.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
change local doo2breaks to plannerShared and update connect.
change signals to slots in plannerShared
Signed-off-by: Jan Iversen <jan@casacondor.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
variables
drop_stone_mode,
last_stop,
switch_at_req_stop
are not set in diveplanner.cpp, but instead
signals a slot in plannerModel.
change signals to slots in plannerShared
Signed-off-by: Jan Iversen <jan@casacondor.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
change local setBailout to plannerShared and update connect.
change signals to slots in plannerShared
Signed-off-by: Jan Iversen <jan@casacondor.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
planner_deco_mode is not set in diveplanner.cpp, but instead
signals a slot in plannerModel.
reserve_gas is not set in diveplanner.cpp, but instead
signals a slot in plannerModel.
change signals to slots in plannerShared
Signed-off-by: Jan Iversen <jan@casacondor.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit does some final cleaning up to the code, mostly deleting
white space and comments.
Signed-off-by: willemferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Add a separate preferences tab for resetting all preferences to their default values.
One or two very small alterations to other sections of the preferences UI code.
Signed-off-by: willemferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This adds a tab for dive log - related preferences.
A suitable test programs is still required.
Signed-off-by: willemferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Add a preferences tab for dive download, allowing resetting the
buttons representing download connections in the Download panel.
Signed-off-by: willemferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Remove the preference settings dealing with thumbnails (currently under
General preferences and Profile preferences) and put them in a newly-created
Media preference tab.
Signed-off-by: willemferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Remove the "Show unused cylinders" checkbox (Profile tab) and the
"Set default cylinder" qTextEdit box (General tab) and put them in a
separate and new Equipment tab. This sounds like a simple task but,
as can be seen from the files changed, was actually a complex matter.
Adapt the existing test programs (General and TechDetails) for creating
a test program that tests parts of the Equipment tab.
Signed-off-by: willemferguson <willemferguson@zoology.up.ac.za>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
WARNING: multi directory commit, needed to secure it builds.
move the core/plannerShared.* to backend-shared.
update CMakeLists.txt to include backend-shared lib in link process.
update ios project to reflect new directory
Signed-off-by: Jan Iversen <jan@casacondor.com>
WARNING: multi directory commit, needed to secure it builds.
move the core/exportfuncs.* to backend-shared.
update backend-shared/CMakeLists.txt to generate backend-shared lib
update CMakeLists.txt to include backend-shared lib in link process.
update ios project to reflect new directory
Signed-off-by: Jan Iversen <jan@casacondor.com>
change the settings variables using UNIT_FACTOR to use
plannerShared instead.
There are no changed functionality, it is simply removing calculations
from the UI.
Signed-off-by: Jan Iversen <jan@casacondor.com>