]> git.tdb.fi Git - r2c2.git/blobdiff - source/libmarklin/trackpart.h
Fix memory leaks and other bad stuff
[r2c2.git] / source / libmarklin / trackpart.h
index 05fa0ba9dabd594cd2d882c99f579f1bdf165e50..0411d72ab3ee2d649851656dea18c6efd2dcb8a7 100644 (file)
@@ -16,26 +16,21 @@ namespace Marklin {
 
 struct TrackPart
 {
-       class Loader: public Msp::DataFile::Loader
+       class Loader: public Msp::DataFile::BasicLoader<TrackPart>
        {
-       private:
-               TrackPart &part;
-
        public:
                Loader(TrackPart &);
-               TrackPart &get_object() { return part; }
        private:
                virtual void finish();
-
                void start(float, float, float);
        };
 
-       Point    pos;
-       float    dir;
-       float    length;
-       float    radius;
-       unsigned route;
-       bool     dead_end;
+       Point pos;
+       float dir;
+       float length;
+       float radius;
+       unsigned path;
+       bool dead_end;
 
        TrackPart();