ClickableStaticText.cpp

Go to the documentation of this file.
00001 
00010 #include "ClickableStaticText.h"
00011 
00012 BEGIN_EVENT_TABLE( ClickableStaticText, wxStaticText)
00013          EVT_LEFT_DOWN( ClickableStaticText::ClickThis)
00014 END_EVENT_TABLE() 
00015 
00025 ClickableStaticText::ClickableStaticText(
00027     wxWindow *parent,
00029     wxWindowID id,
00031     const wxString& label,
00033     const wxPoint& pos,
00035     const wxSize& size,
00037     long style,
00039     const wxString& name)
00040     : wxStaticText(parent, id, label, pos, size, style, name)
00041 {
00042     m_cb = NULL;
00043 }
00044 
00053 void ClickableStaticText::SetCheckBox(wxCheckBox* cb)
00054 {
00055     m_cb = cb;
00056 }
00057 
00069 void ClickableStaticText::ClickThis(wxMouseEvent &event)
00070 {
00071     if(m_cb)
00072     {
00073         m_cb->SetValue(!m_cb->IsChecked());
00074     }
00075 }

Generated on Mon Nov 15 11:15:47 2010 for PublicKeyInfrastructureFramework(PKIF) by  doxygen 1.5.6