COIN-OR::LEMON - Graph Library

Changeset 1876:5ad84ad1b68f in lemon-0.x for gui/algowin.h


Ignore:
Timestamp:
01/04/06 19:05:55 (16 years ago)
Author:
Hegyi Péter
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2451
Message:

Communication with algorithm window is developed.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • gui/algowin.h

    r1871 r1876  
    1111#include <libgnomecanvasmm/polygon.h>
    1212
    13 enum {GENERAL, ALGO_NUM}; // algorithm IDs;
     13enum {GENERAL, KRUSKAL, ALGO_NUM}; // algorithm IDs;
    1414
    15 class AlgoWin : public Gtk::Dialog
     15class AlgoWin : public Gtk::Window
    1616{
    1717private:
    1818  AlgoBox * ab;
     19  Gtk::Button * runbutton;
     20  Gtk::Button * closebutton;
    1921
    2022protected:
    2123  sigc::signal<void, AlgoWin *> signal_closed; 
     24  sigc::signal<void, AlgoWin *, std::string> signal_maplist_need; 
    2225
    2326public:
    24   sigc::signal<void, AlgoWin *> signal_closing()
    25   {
    26     return signal_closed;
    27   }
     27  bool closeIfEscapeIsPressed(GdkEventKey* e);
    2828
    29   AlgoWin(int algoid, std::vector<std::string> tabnames)
    30     {
    31       Gtk::VBox * vbox=get_vbox();
    32      
    33       ab=new AlgoBox(tabnames);
    34      
    35       vbox->pack_start(*ab);
    36      
    37       add_button(Gtk::Stock::OK, Gtk::RESPONSE_OK);
    38      
    39       show_all_children();
    40     };
     29  sigc::signal<void, AlgoWin *> signal_closing();
     30  sigc::signal<void, AlgoWin *, std::string> signal_maplist_needed();
    4131
    42   void update_tablist(std::vector<std::string> tabnames)
    43   {
    44     ab->update_tablist(tabnames);
    45   }
     32  void emit_tab_change(std::string);
    4633
    47   void on_hide()
    48   {
    49     signal_closed.emit(this);
    50     Gtk::Dialog::on_hide();
    51   }
     34  AlgoWin(int, std::vector<std::string>, std::vector<std::string>, std::vector<std::string>);
     35
     36  void update_tablist(std::vector<std::string> tabnames);
     37  void update_maplist(std::vector<std::string>, std::vector<std::string>);
     38
     39  void on_hide();
    5240};
    5341#endif //ALGOWIN_H
Note: See TracChangeset for help on using the changeset viewer.