gui/algowin.h
author hegyi
Thu, 05 Jan 2006 12:30:09 +0000
changeset 1878 409a31271efd
parent 1876 5ad84ad1b68f
child 1879 01d41844ef46
permissions -rw-r--r--
Several changes. \n If new map is added to mapstorage it emits signal with the name of the new map. This was important, because from now on not only tha mapwin should be updated. \n Furthermore algobox gets a pointer to mapstorage instead of only the mapnames from it. This is important because without it it would be complicated to pass all of the required maps to algobox.
     1 // -*- C++ -*- //
     2 
     3 #ifndef ALGOWIN_H
     4 #define ALGOWIN_H
     5 
     6 class AlgoWin;
     7 
     8 #include <all_include.h>
     9 #include <algobox.h>
    10 #include <libgnomecanvasmm.h>
    11 #include <libgnomecanvasmm/polygon.h>
    12 
    13 enum {GENERAL, KRUSKAL, ALGO_NUM}; // algorithm IDs;
    14 
    15 class AlgoWin : public Gtk::Window
    16 {
    17 private:
    18   AlgoBox * ab;
    19   Gtk::Button * runbutton;
    20   Gtk::Button * closebutton;
    21 
    22 protected:
    23   sigc::signal<void, AlgoWin *> signal_closed;  
    24   sigc::signal<void, AlgoWin *, std::string> signal_maplist_need;  
    25 
    26 public:
    27   bool closeIfEscapeIsPressed(GdkEventKey* e);
    28 
    29   sigc::signal<void, AlgoWin *> signal_closing();
    30   sigc::signal<void, AlgoWin *, std::string> signal_maplist_needed();
    31 
    32   void emit_tab_change(std::string);
    33 
    34   AlgoWin(int, std::vector<std::string>);
    35 
    36   void update_tablist(std::vector<std::string> tabnames);
    37   void update_maplist( void *);
    38 
    39   void on_hide();
    40 };
    41 #endif //ALGOWIN_H