Corrected valtext.cpp for disabled controls; added Dialog Editor fixes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@1963 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
cc385968c4
commit
6cd47507e8
@ -128,9 +128,9 @@ bool wxTextValidator::Validate(wxWindow *parent)
|
||||
|
||||
wxTextCtrl *control = (wxTextCtrl *) m_validatorWindow ;
|
||||
|
||||
// If window is disabled, don't validate
|
||||
// If window is disabled, simply return
|
||||
if ( !control->Enabled() )
|
||||
return FALSE;
|
||||
return TRUE;
|
||||
|
||||
wxString val(control->GetValue());
|
||||
|
||||
|
@ -2357,7 +2357,6 @@ void wxResourceSymbolValidator::OnEdit(wxProperty *property, wxPropertyListView
|
||||
{
|
||||
wxString symbolName(dialog->GetSymbol());
|
||||
long id = dialog->GetId();
|
||||
dialog->Destroy();
|
||||
|
||||
wxString str;
|
||||
str.Printf("%d", id);
|
||||
@ -2367,6 +2366,8 @@ void wxResourceSymbolValidator::OnEdit(wxProperty *property, wxPropertyListView
|
||||
view->UpdatePropertyDisplayInList(property);
|
||||
view->OnPropertyChanged(property);
|
||||
}
|
||||
// Moved from the 'if' branch on suggestion of Roman Pavlov
|
||||
dialog->Destroy();
|
||||
}
|
||||
|
||||
BEGIN_EVENT_TABLE(wxResourceSymbolDialog, wxDialog)
|
||||
|
@ -78,8 +78,8 @@ int g_WindowStylesGaugeCount = sizeof(g_WindowStylesGauge)/sizeof(wxWindowStyleP
|
||||
|
||||
/* wxTextCtrl */
|
||||
static wxWindowStylePair g_WindowStylesTextCtrl[] = {
|
||||
{ "wxPASSWORD", wxPASSWORD},
|
||||
{ "wxPROCESS_ENTER", wxPROCESS_ENTER},
|
||||
// { "wxPASSWORD", wxPASSWORD},
|
||||
// { "wxPROCESS_ENTER", wxPROCESS_ENTER},
|
||||
{ "wxTE_PASSWORD", wxTE_PASSWORD},
|
||||
{ "wxTE_READONLY", wxTE_READONLY},
|
||||
{ "wxTE_PROCESS_ENTER", wxTE_PROCESS_ENTER},
|
||||
|
Loading…
Reference in New Issue
Block a user