Fixed some memory leaks in the translation assistant detected by valgrind

Originally committed to SVN as r2961.
This commit is contained in:
harukalover 2009-05-21 18:37:36 +00:00
parent dd1c706d5c
commit 350d9e5db7
2 changed files with 9 additions and 0 deletions

View file

@ -161,6 +161,14 @@ DialogTranslation::DialogTranslation (wxWindow *parent,AssFile *_subs,SubtitlesG
}
//////////////
// Destructor
DialogTranslation::~DialogTranslation() {
TransText->PopEventHandler(true);
PreviewCheck->PopEventHandler(true);
}
//////////////////////////
// Jumps to line at block
bool DialogTranslation::JumpToLine(int n,int block) {

View file

@ -83,6 +83,7 @@ private:
public:
bool enablePreview;
DialogTranslation (wxWindow *parent,AssFile *subs,SubtitlesGrid *grid,int startrow=0,bool preview=false);
~DialogTranslation();
void OnTransBoxKey(wxKeyEvent &event);