Stimfit  0.13.15
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines
stfcheckbox.h
Go to the documentation of this file.
00001 // This program is free software; you can redistribute it and/or
00002 // modify it under the terms of the GNU General Public License
00003 // as published by the Free Software Foundation; either version 2
00004 // of the License, or (at your option) any later version.
00005 
00006 // This program is distributed in the hope that it will be useful,
00007 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00008 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00009 // GNU General Public License for more details.
00010 
00011 // You should have received a copy of the GNU General Public License
00012 // along with this program; if not, write to the Free Software
00013 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
00014 
00021 #ifndef _STFCHECKBOX_H
00022 #define _STFCHECKBOX_H
00023 
00028 
00029 
00030 class wxStfCheckBox : public wxCheckBox {
00031 DECLARE_CLASS(wxStfCheckBox)
00032 public:
00034 
00044     wxStfCheckBox(
00045         wxWindow *parent,
00046         wxWindowID id,
00047         const wxString& label,
00048         stf::Event* pEvent,
00049         const wxPoint& pos = wxDefaultPosition,
00050         const wxSize& size = wxDefaultSize,
00051         long style = 0,
00052         const wxValidator& validator = wxDefaultValidator,
00053         const wxString& name = wxCheckBoxNameStr
00054     );
00055 
00057 
00059     void ResetEvent( stf::Event* pEvent ) { m_pEvent = pEvent; SetValue( !pEvent->GetDiscard() );}
00060 
00061 private:
00062     void OnKeyDown(wxKeyEvent& event);
00063     void OnStfClicked(wxMouseEvent& event);
00064 
00065     stf::Event* m_pEvent;
00066 
00067 DECLARE_EVENT_TABLE()
00068 };
00069 
00072 #endif
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Defines