/home/enzo/treballs/fib/pfc/nanocomp/src/forbiddenPatternView.hpp

Go to the documentation of this file.
00001 /*
00002  *                                                                         *
00003  *   This program is free software; you can redistribute it and/or modify  *
00004  *   it under the terms of the GNU General Public License as published by  *
00005  *   the Free Software Foundation; either version 2 of the License, or     *
00006  *   (at your option) any later version.                                   *
00007  *                                                                         *
00008  *   This program is distributed in the hope that it will be useful,       *
00009  *   but WITHOUT ANY WARRANTY; without even the implied warranty of        *
00010  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the         *
00011  *   GNU General Public License for more details.                          *
00012  *                                                                         *
00013  *   You should have received a copy of the GNU General Public License     *
00014  *   along with this program; if not, write to the                         *
00015  *   Free Software Foundation, Inc.,                                       *
00016  *   59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.             *
00017                                                                           */
00028 #ifndef FORBIDDENPATTERNVIEW_HPP_
00029 #define FORBIDDENPATTERNVIEW_HPP_
00030 
00031 #include <wx/wx.h>
00032 
00033 #include "layoutCanvas.hpp"
00034 #include "forbiddenPatternManager.hpp"
00035 
00036 class ForbiddenPatternManager;
00037 
00038 class ForbiddenPatternView : public wxPanel
00039 {
00040 public:
00041         ForbiddenPatternView(wxWindow* parent, wxWindowID id, ForbiddenPatternManager *controller);
00042         virtual ~ForbiddenPatternView();
00043     void updateGrids(Grid grid, bool changed);
00044     void updateList(wxArrayString strings);
00045     void selectFP(unsigned int rule);
00046     bool msgYesNo(wxString message);
00047     void errorMsg(wxString message);
00048     void setListMessage(int id, wxString message);
00049     void resetListItem(int id);
00050         
00051 private:
00052     DECLARE_EVENT_TABLE()
00053     void initControls();
00054     void initSizers();
00055     void OnClick(LayoutCanvasEvent &event);
00056     void OnNew(wxCommandEvent &event);
00057     void OnSelection(wxCommandEvent &event);
00058     void OnRemove(wxCommandEvent &event);
00059     void OnSave(wxCommandEvent& event);
00060     void OnSaveAs(wxCommandEvent& event);
00061     void OnOpen(wxCommandEvent& event);
00062     void OnCheck(wxCommandEvent& event);
00063     
00064     ForbiddenPatternManager *controller;
00065     //Labels
00066     wxStaticText *labelTitle;
00067     wxStaticText *labelFP;
00068     
00069     //Buttons
00070     wxBitmapButton *buttonNew;
00071     wxBitmapButton *buttonOpen;
00072     wxBitmapButton *buttonSave;
00073     wxBitmapButton *buttonSaveAs;
00074     wxBitmapButton *buttonRemove;
00075     wxButton *buttonCheck;
00076     
00077     //Other controls
00078     wxListBox *listFP;
00079     LayoutCanvas *canvas;
00080 };
00081 
00082 #endif /*FORBIDDENPATTERNVIEW_HPP_*/

Generated on Fri Sep 1 23:55:13 2006 for NanoComp by  doxygen 1.4.6