1 // 2 // paramdialog.h 3 // 4 5 #ifndef __PARAMDIALOG_H__ 6 #define __PARAMDIALOG_H__ 7 8 #include "wx/dialog.h" 9 #include "wx/spinctrl.h" 10 #include "wx/string.h" 11 12 class Edge; 13 14 class wxWindow; 15 16 17 class ParamDialogIntInt : public wxDialog 18 { 19 public: 20 ParamDialogIntInt (wxWindow *parent, const wxString &title, 21 const wxString &prompt, long value1, long min1, long max1, 22 long value2, long min2, long max2); 23 GetValue1()24 long GetValue1 () const { return m_value1; } GetValue2()25 long GetValue2 () const { return m_value2; } 26 27 protected: 28 29 void OnOK (wxCommandEvent &event); 30 void OnCancel (wxCommandEvent &event); 31 32 wxSpinCtrl *m_spinctrl1, *m_spinctrl2; 33 34 long m_value1, m_min1, m_max1; 35 long m_value2, m_min2, m_max2; 36 37 private: 38 DECLARE_EVENT_TABLE() 39 }; 40 41 class ParamDialogEdge : public wxDialog 42 { 43 public: 44 ParamDialogEdge (wxWindow *parent, const wxString &title, 45 const Edge *e); GetWeight()46 long GetWeight () const { return m_weight; } GetFlow()47 long GetFlow () const { return m_flow; } GetDirection()48 long GetDirection () const { return m_dir; } 49 50 protected: 51 52 void OnOK (wxCommandEvent &event); 53 void OnCancel (wxCommandEvent &event); 54 void OnSpin (wxSpinEvent &event); 55 void OnEdgeDir (wxCommandEvent &event); 56 57 wxSpinCtrl *m_spinctrl_weight, *m_spinctrl_flow; 58 59 long m_weight, m_flow, m_dir; 60 bool dir_inverted; 61 62 private: 63 DECLARE_EVENT_TABLE() 64 }; 65 66 #endif //__PARAMDIALOG_H__ 67