]> git.tdb.fi Git - r2c2.git/blobdiff - source/designer/zonebar.h
Don't crash if a train has no router
[r2c2.git] / source / designer / zonebar.h
index ded63ad6a8e81da7e94cd839215f5e267162969e..c9f0d62cadd164fff11a5bcdbd232fc17b3c2d8a 100644 (file)
@@ -1,10 +1,3 @@
-/* $Id$
-
-This file is part of R²C²
-Copyright © 2010 Mikkosoft Productions, Mikko Rasa
-Distributed under the GPL
-*/
-
 #ifndef ZONEBAR_H_
 #define ZONEBAR_H_
 
@@ -13,24 +6,25 @@ Distributed under the GPL
 
 class Designer;
 
-class Zonebar: public Toolbar
+class Zonebar: public Toolbar, public sigc::trackable
 {
 private:
        Designer &designer;
+       Msp::GLtk::BasicListData<std::string> groups;
        Msp::GLtk::Dropdown *drp_groups;
+       Msp::GLtk::FunctionListData<R2C2::Zone *> zones;
        Msp::GLtk::Dropdown *drp_numbers;
 
 public:
        Zonebar(Designer &);
 
 private:
-       void zone_added(R2C2::Zone &);
-       void zone_renamed(const std::string &, const std::string &, unsigned);
-       void group_selected(unsigned, const std::string &);
-       void number_selected(unsigned, const std::string &);
+       void track_chain_added(R2C2::TrackChain &);
+       void track_chain_removed(R2C2::TrackChain &);
+       void zone_renamed(R2C2::Zone &, const std::string &);
+       void group_selected(unsigned);
+       void number_selected(unsigned);
        void delete_zone_clicked();
-       void update_groups();
-       void update_numbers(const std::string &);
 };
 
 #endif