KiCad PCB EDA Suite
WDO_ENABLE_DISABLE Class Reference

Toggle a window's "enable" status to disabled, then enabled on destruction. More...

Public Member Functions

 WDO_ENABLE_DISABLE (wxWindow *aWindow)
 
 ~WDO_ENABLE_DISABLE ()
 

Private Attributes

wxWindow * m_win
 

Detailed Description

Toggle a window's "enable" status to disabled, then enabled on destruction.

Definition at line 33 of file dialog_shim.cpp.

Constructor & Destructor Documentation

WDO_ENABLE_DISABLE::WDO_ENABLE_DISABLE ( wxWindow *  aWindow)
inline

Definition at line 39 of file dialog_shim.cpp.

39  :
40  m_win( aWindow )
41  {
42  if( m_win )
43  m_win->Disable();
44  }
WDO_ENABLE_DISABLE::~WDO_ENABLE_DISABLE ( )
inline

Definition at line 46 of file dialog_shim.cpp.

47  {
48  if( m_win )
49  {
50  m_win->Enable();
51  m_win->SetFocus(); // let's focus back on the parent window
52  }
53  }

Member Data Documentation

wxWindow* WDO_ENABLE_DISABLE::m_win
private

Definition at line 35 of file dialog_shim.cpp.


The documentation for this class was generated from the following file: