summaryrefslogtreecommitdiffhomepage
path: root/spline/spline.cpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2017-10-24 11:32:00 +0200
committerStanislaw Halik <sthalik@misaki.pl>2017-10-27 16:42:58 +0200
commit68790fd7b8c24cf8a7e9132211338d76d2238af5 (patch)
tree9336d950f852fd2fec416cd64810b0151635f580 /spline/spline.cpp
parentb15fe980671e028d0849e11878e0edf9a88669a5 (diff)
spline: use default initialization
Diffstat (limited to 'spline/spline.cpp')
-rw-r--r--spline/spline.cpp15
1 files changed, 6 insertions, 9 deletions
diff --git a/spline/spline.cpp b/spline/spline.cpp
index 2e29997a..e3cd2d6f 100644
--- a/spline/spline.cpp
+++ b/spline/spline.cpp
@@ -24,16 +24,13 @@
#include <QDebug>
-constexpr int spline::value_count;
+using namespace spline_detail;
+
+constexpr std::size_t spline::value_count;
spline::spline(const QString& name, const QString& axis_name, Axis axis) :
- s(nullptr),
- data(value_count, -16),
- _mutex(QMutex::Recursive),
ctx(std::make_shared<QObject>()),
- axis(axis),
- activep(false),
- validp(false)
+ axis(axis)
{
set_bundle(options::make_bundle(name), axis_name, axis);
}
@@ -460,13 +457,13 @@ void spline::ensure_valid(QList<QPointF>& the_points)
}
// the return value is only safe to use with no spline::set_bundle calls
-std::shared_ptr<spline::settings> spline::get_settings()
+std::shared_ptr<settings> spline::get_settings()
{
QMutexLocker foo(&_mutex);
return s;
}
-std::shared_ptr<const spline::settings> spline::get_settings() const
+std::shared_ptr<const settings> spline::get_settings() const
{
QMutexLocker foo(&_mutex);
return s;