diff --git a/common/dialog_shim.cpp b/common/dialog_shim.cpp
index 47066e77c7..1d50a08908 100644
--- a/common/dialog_shim.cpp
+++ b/common/dialog_shim.cpp
@@ -46,7 +46,17 @@ static RECT_MAP class_map;
bool DIALOG_SHIM::Show( bool show )
{
bool ret;
- const char* classname = typeid(*this).name();
+ const char* hash_key;
+
+ if( m_hash_key.size() )
+ {
+ // a special case like EDA_LIST_DIALOG, which has multiple uses.
+ hash_key = m_hash_key.c_str();
+ }
+ else
+ {
+ hash_key = typeid(*this).name();
+ }
// Show or hide the window. If hiding, save current position and size.
// If showing, use previous position and size.
@@ -55,7 +65,7 @@ bool DIALOG_SHIM::Show( bool show )
ret = wxDialog::Show( show );
// classname is key, returns a zeroed out default EDA_RECT if none existed before.
- EDA_RECT r = class_map[ classname ];
+ EDA_RECT r = class_map[ hash_key ];
if( r.GetSize().x != 0 && r.GetSize().y != 0 )
SetSize( r.GetPosition().x, r.GetPosition().y, r.GetSize().x, r.GetSize().y, 0 );
@@ -64,7 +74,7 @@ bool DIALOG_SHIM::Show( bool show )
{
// Save the dialog's position & size before hiding, using classname as key
EDA_RECT r( wxDialog::GetPosition(), wxDialog::GetSize() );
- class_map[ classname ] = r;
+ class_map[ hash_key ] = r;
ret = wxDialog::Show( show );
}
diff --git a/common/dialogs/dialog_get_component_base.cpp b/common/dialogs/dialog_get_component_base.cpp
index 452a27a065..8e8810c5d0 100644
--- a/common/dialogs/dialog_get_component_base.cpp
+++ b/common/dialogs/dialog_get_component_base.cpp
@@ -1,5 +1,5 @@
///////////////////////////////////////////////////////////////////////////
-// C++ code generated with wxFormBuilder (version Apr 10 2012)
+// C++ code generated with wxFormBuilder (version Nov 5 2013)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
@@ -24,6 +24,7 @@ DIALOG_GET_COMPONENT_BASE::DIALOG_GET_COMPONENT_BASE( wxWindow* parent, wxWindow
bSizerLeft->Add( m_staticTextName, 0, wxTOP|wxRIGHT|wxLEFT, 5 );
m_textCmpNameCtrl = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
+ m_textCmpNameCtrl->SetMaxLength( 0 );
bSizerLeft->Add( m_textCmpNameCtrl, 0, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 );
m_staticTextHistory = new wxStaticText( this, wxID_ANY, _("History list:"), wxDefaultPosition, wxDefaultSize, 0 );
@@ -63,6 +64,7 @@ DIALOG_GET_COMPONENT_BASE::DIALOG_GET_COMPONENT_BASE( wxWindow* parent, wxWindow
this->SetSizer( bSizerMain );
this->Layout();
+ bSizerMain->Fit( this );
this->Centre( wxBOTH );
diff --git a/common/dialogs/dialog_get_component_base.fbp b/common/dialogs/dialog_get_component_base.fbp
index a39d3372e4..10a950c93f 100644
--- a/common/dialogs/dialog_get_component_base.fbp
+++ b/common/dialogs/dialog_get_component_base.fbp
@@ -20,8 +20,10 @@
.
1
+ 1
1
1
+ UI
0
0