From aca234ebcc8ffd6e4b7ffa7c88551f93916efc6a Mon Sep 17 00:00:00 2001 From: Niels Martin Hansen Date: Wed, 10 Sep 2008 14:56:29 +0000 Subject: [PATCH] Fix bugs #775 and #776, missing initialisation of controls in Auto4 Lua dialogues. (Untested.) Originally committed to SVN as r2335. --- aegisub/auto4_lua_dialog.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/aegisub/auto4_lua_dialog.cpp b/aegisub/auto4_lua_dialog.cpp index 0664d4a9d..8c9361e16 100644 --- a/aegisub/auto4_lua_dialog.cpp +++ b/aegisub/auto4_lua_dialog.cpp @@ -418,7 +418,7 @@ nospin: typedef wxValidator FloatTextValidator; wxControl *Create(wxWindow *parent) { - cw = new wxTextCtrl(parent, -1, text, wxDefaultPosition, wxDefaultSize, 0); //, FloatTextValidator()); + cw = new wxTextCtrl(parent, -1, PrettyFloatF(value), wxDefaultPosition, wxDefaultSize, 0); //, FloatTextValidator()); cw->SetToolTip(hint); return cw; } @@ -543,6 +543,7 @@ nospin: { cw = new wxCheckBox(parent, -1, label); cw->SetToolTip(hint); + static_cast(cw)->SetValue(value); return cw; }