From 0bff490b7e60d9fcd60283f4cb9bd6bda9458d40 Mon Sep 17 00:00:00 2001 From: Thomas Goyne Date: Fri, 27 Jan 2012 23:35:31 +0000 Subject: [PATCH] Enable/disable the OK button in the TPP dialog when styles are (un)checked Originally committed to SVN as r6387. --- aegisub/src/dialog_timing_processor.cpp | 1 + aegisub/src/subs_edit_box.cpp | 1 + 2 files changed, 2 insertions(+) diff --git a/aegisub/src/dialog_timing_processor.cpp b/aegisub/src/dialog_timing_processor.cpp index f6b283b7a..260e41135 100644 --- a/aegisub/src/dialog_timing_processor.cpp +++ b/aegisub/src/dialog_timing_processor.cpp @@ -234,6 +234,7 @@ DialogTimingProcessor::DialogTimingProcessor(agi::Context *c) CenterOnParent(); Bind(wxEVT_COMMAND_CHECKBOX_CLICKED, bind(&DialogTimingProcessor::UpdateControls, this)); + Bind(wxEVT_COMMAND_CHECKLISTBOX_TOGGLED, bind(&DialogTimingProcessor::UpdateControls, this)); Bind(wxEVT_COMMAND_BUTTON_CLICKED, &DialogTimingProcessor::OnApply, this, wxID_OK); all->Bind(wxEVT_COMMAND_BUTTON_CLICKED, bind(&DialogTimingProcessor::CheckAll, this, true)); none->Bind(wxEVT_COMMAND_BUTTON_CLICKED, bind(&DialogTimingProcessor::CheckAll, this, false)); diff --git a/aegisub/src/subs_edit_box.cpp b/aegisub/src/subs_edit_box.cpp index d15bd3987..062241c33 100644 --- a/aegisub/src/subs_edit_box.cpp +++ b/aegisub/src/subs_edit_box.cpp @@ -206,6 +206,7 @@ SubsEditBox::SubsEditBox(wxWindow *parent, agi::Context *context) // Text editor TextEdit = new SubsTextEditCtrl(this, wxSize(300,50), wxBORDER_SUNKEN, c); + TextEdit->Bind(wxEVT_KEY_DOWN, &SubsEditBox::OnKeyDown, this); Bind(wxEVT_KEY_DOWN, &SubsEditBox::OnKeyDown, this); BottomSizer = new wxBoxSizer(wxHORIZONTAL); BottomSizer->Add(TextEdit,1,wxEXPAND,0);