]> git.tdb.fi Git - r2c2.git/blobdiff - source/engineer/trainproperties.h
Fix a segfault in removing vehicles when creating a new train
[r2c2.git] / source / engineer / trainproperties.h
index c75015b08f4b27f8c5b009af0af17aa572352713..465154d2948789734672233ad7b0f39d8766978f 100644 (file)
@@ -21,18 +21,21 @@ private:
        Engineer &engineer;
        Marklin::Train *train;
        Msp::GLtk::Entry *ent_addr;
+       Msp::GLtk::Dropdown *drp_protocol;
        Msp::GLtk::Dropdown *drp_type;
        Msp::GLtk::Entry *ent_name;
        Msp::GLtk::Dropdown *drp_priority;
        Msp::GLtk::List *lst_vehicles;
        Msp::GLtk::Dropdown *drp_new_vehicle;
        std::vector<const Marklin::VehicleType *> add_vehicles;
+       std::set<unsigned> rem_vehicles;
 
 public:
-       TrainProperties(Engineer &, const Msp::GLtk::Resources &, Marklin::Train *);
+       TrainProperties(Engineer &, Marklin::Train *);
 private:
        virtual void on_ok_clicked();
        void new_vehicle_selected(unsigned, const std::string &);
+       void remove_vehicle_clicked();
        const Marklin::VehicleType &get_vehicle_type(unsigned, bool);
 };