* Fixed an issue with the translation assistant not remembering the last position it was placed at before closing it

* Fixed some memory leaks in the translation assistant

Originally committed to SVN as r3045.
This commit is contained in:
harukalover 2009-06-11 02:33:21 +00:00
parent 9abcbe19b3
commit 7ac69a31b3

View file

@ -254,7 +254,7 @@ void DialogTranslation::UpdatePreview () {
///////////////
// Event table
BEGIN_EVENT_TABLE(DialogTranslation, wxDialog)
EVT_BUTTON(wxID_CLOSE,DialogTranslation::OnClose)
EVT_BUTTON(wxID_CANCEL,DialogTranslation::OnClose)
EVT_BUTTON(BUTTON_TRANS_PLAY_VIDEO,DialogTranslation::OnPlayVideoButton)
EVT_BUTTON(BUTTON_TRANS_PLAY_AUDIO,DialogTranslation::OnPlayAudioButton)
END_EVENT_TABLE()
@ -419,7 +419,9 @@ void DialogTranslation::OnPlayAudioButton(wxCommandEvent &event) {
// Close
void DialogTranslation::OnClose (wxCommandEvent &event) {
GetPosition(&lastx, &lasty);
Close();
TransText->PopEventHandler(true);
PreviewCheck->PopEventHandler(true);
EndModal(0);
}