KiCad PCB EDA Suite
dialog_shim.cpp File Reference
#include <dialog_shim.h>
#include <kiway_player.h>
#include <wx/evtloop.h>
#include <pgm_base.h>
#include <tool/tool_manager.h>
#include <eda_rect.h>
#include <wx/display.h>
#include <wx/grid.h>
#include <hashtables.h>
#include <typeinfo>

Go to the source code of this file.

Classes

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

Functions

static void selectAllInTextCtrls (wxWindowList &children)
 

Variables

static RECT_MAP class_map
 

Function Documentation

◆ selectAllInTextCtrls()

static void selectAllInTextCtrls ( wxWindowList &  children)
static

Definition at line 280 of file dialog_shim.cpp.

281 {
282  for( wxWindow* child : children )
283  {
284  wxTextCtrl* childTextCtrl = dynamic_cast<wxTextCtrl*>( child );
285  if( childTextCtrl )
286  {
287  wxTextEntry* asTextEntry = dynamic_cast<wxTextEntry*>( childTextCtrl );
288 
289  // Respect an existing selection
290  if( asTextEntry->GetStringSelection().IsEmpty() )
291  asTextEntry->SelectAll();
292  }
293  else
294  selectAllInTextCtrls( child->GetChildren() );
295  }
296 }
static void selectAllInTextCtrls(wxWindowList &children)

Referenced by DIALOG_SHIM::OnPaint().

Variable Documentation

◆ class_map

RECT_MAP class_map
static

Definition at line 177 of file dialog_shim.cpp.

Referenced by DIALOG_SHIM::ResetSize(), and DIALOG_SHIM::Show().