Remove some unused stuff in the kanji timer

Originally committed to SVN as r6608.
This commit is contained in:
Thomas Goyne 2012-03-27 00:48:38 +00:00
parent 2ef193e197
commit f9e8d89059
2 changed files with 5 additions and 20 deletions

View File

@ -76,9 +76,7 @@ enum {
BUTTON_KTSKIPSOURCE,
BUTTON_KTSKIPDEST,
BUTTON_KTGOBACK,
BUTTON_KTACCEPT,
TEXT_SOURCE,
TEXT_DEST
BUTTON_KTACCEPT
};
/// DOCME
@ -726,8 +724,6 @@ BEGIN_EVENT_TABLE(DialogKanjiTimer,wxDialog)
EVT_BUTTON(BUTTON_KTGOBACK,DialogKanjiTimer::OnGoBack)
EVT_BUTTON(BUTTON_KTACCEPT,DialogKanjiTimer::OnAccept)
EVT_KEY_DOWN(DialogKanjiTimer::OnKeyDown)
EVT_TEXT_ENTER(TEXT_SOURCE,DialogKanjiTimer::OnKeyEnter)
EVT_TEXT_ENTER(TEXT_DEST,DialogKanjiTimer::OnKeyEnter)
END_EVENT_TABLE()
void DialogKanjiTimer::OnClose(wxCommandEvent &) {
@ -823,26 +819,16 @@ void DialogKanjiTimer::OnKeyDown(wxKeyEvent &event) {
display->DecreaseSourceMatch();
break;
case WXK_RETURN :
OnKeyEnter(evt);
if (display->GetRemainingSource() == 0 && display->GetRemainingDestination() == 0)
OnAccept(evt);
else
OnLink(evt);
break;
default :
event.Skip();
}
}
void DialogKanjiTimer::OnKeyEnter(wxCommandEvent &) {
wxCommandEvent evt;
if (display->GetRemainingSource() == 0 && display->GetRemainingDestination() == 0)
{
OnAccept(evt);
}
else
{
OnLink(evt);
}
}
void DialogKanjiTimer::ResetForNewLine()
{
AssDialogue *src = 0;

View File

@ -90,7 +90,6 @@ class DialogKanjiTimer : public wxDialog {
void OnSkipDest(wxCommandEvent &event);
void OnGoBack(wxCommandEvent &event);
void OnAccept(wxCommandEvent &event);
inline void OnKeyEnter(wxCommandEvent &event);
void OnKeyDown(wxKeyEvent &event);
void ResetForNewLine();