summaryrefslogtreecommitdiffstats
path: root/qt-ui/models.cpp
diff options
context:
space:
mode:
authorGravatar Tomaz Canabrava <tcanabrava@kde.org>2014-04-16 23:56:42 -0300
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-04-17 08:33:51 -0700
commitf14c14c383763c73de1a6ec681b017517235f2f6 (patch)
tree3c9c624e51c8e602a8ba085d56411c839fc05b80 /qt-ui/models.cpp
parent1a1cbc296be806a2117a5969443917d96bcb096a (diff)
downloadsubsurface-f14c14c383763c73de1a6ec681b017517235f2f6.tar.gz
Mark a lot of TODO's where I think it should be moved to C code.
This marks a lot of todo's where I think there's core stuff being mangled on the interface - we should remove this from the interface to make testing and maintenability easier. Signed-off-by: Tomaz Canabrava <tomaz.canabrava@intel.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/models.cpp')
-rw-r--r--qt-ui/models.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/qt-ui/models.cpp b/qt-ui/models.cpp
index 6d64da44b..0564add12 100644
--- a/qt-ui/models.cpp
+++ b/qt-ui/models.cpp
@@ -444,7 +444,7 @@ void WeightModel::passInData(const QModelIndex &index, const QVariant &value)
}
}
}
-
+//TODO: Move to C
weight_t string_to_weight(const char *str)
{
const char *end;
@@ -469,6 +469,7 @@ lbs:
return weight;
}
+//TODO: Move to C.
depth_t string_to_depth(const char *str)
{
const char *end;
@@ -492,6 +493,7 @@ ft:
return depth;
}
+//TODO: Move to C.
pressure_t string_to_pressure(const char *str)
{
const char *end;
@@ -515,6 +517,7 @@ psi:
return pressure;
}
+//TODO: Move to C.
/* Imperial cylinder volumes need working pressure to be meaningful */
volume_t string_to_volume(const char *str, pressure_t workp)
{
@@ -547,6 +550,7 @@ l:
return volume;
}
+//TODO: Move to C.
fraction_t string_to_fraction(const char *str)
{
const char *end;
@@ -564,6 +568,7 @@ bool WeightModel::setData(const QModelIndex &index, const QVariant &value, int r
switch (index.column()) {
case TYPE:
if (!value.isNull()) {
+ //TODO: C-function weigth_system_set_description ?
if (!ws->description || gettextFromC::instance()->tr(ws->description) != vString) {
// loop over translations to see if one matches
int i = -1;