1.1 --- a/gui/map_win.h Mon Nov 21 09:08:16 2005 +0000
1.2 +++ b/gui/map_win.h Mon Nov 21 12:07:05 2005 +0000
1.3 @@ -9,7 +9,6 @@
1.4 #include "graph_displayer_canvas.h"
1.5 #include "mapstorage.h"
1.6 #include "new_map_win.h"
1.7 -#include "mapselector.h"
1.8 #include <libgnomecanvasmm.h>
1.9 #include <libgnomecanvasmm/polygon.h>
1.10
1.11 @@ -18,6 +17,61 @@
1.12 ///assigned to maps.
1.13 class MapWin : public Gtk::Window
1.14 {
1.15 +
1.16 + class MapSelector : public Gtk::HBox
1.17 + {
1.18 + protected:
1.19 + GraphDisplayerCanvas & gdc;
1.20 + ///The \ref MapStorage in which the visualizable maps are stored
1.21 + MapStorage & ms;
1.22 + NewMapWin & nmw;
1.23 +
1.24 + int id;
1.25 +
1.26 + bool itisedge;
1.27 +
1.28 + bool default_state;
1.29 +
1.30 + bool set_new_map;
1.31 +
1.32 + Gtk::ComboBoxText cbt;
1.33 +
1.34 + Gtk::Button * newbut, * defbut;
1.35 +
1.36 + Gtk::HBox hbox;
1.37 +
1.38 + Gtk::Label * label;
1.39 +
1.40 + Node node_to_update;
1.41 + Edge edge_to_update;
1.42 +
1.43 +
1.44 + public:
1.45 +
1.46 + MapSelector(GraphDisplayerCanvas &, MapStorage &, NewMapWin &, int, bool);
1.47 +
1.48 + void update_list();
1.49 +
1.50 + ///If a radiobutton is clicked, this function determines
1.51 + ///which button was that and after that calls the
1.52 + ///appropriate function of the \ref GraphDisplayerCanvas
1.53 + ///to change the visible values of that attribute.
1.54 + virtual void comboChanged();
1.55 +
1.56 + virtual void new_but_pressed();
1.57 +
1.58 + virtual void reset();
1.59 +
1.60 + virtual void update(Node node);
1.61 + virtual void update(Edge edge);
1.62 +
1.63 + Glib::ustring get_active_text();
1.64 + void set_active_text(Glib::ustring);
1.65 + void append_text(Glib::ustring);
1.66 + };
1.67 +
1.68 +
1.69 +
1.70 protected:
1.71 ///The \ref GraphDisplayerCanvas on which the graph will be drawn.
1.72 ///It has to be known for this class, because