Implement pieces move animations

This commit is contained in:
Loic Guegan 2022-12-29 10:08:22 +01:00
parent 7187e6d6ee
commit 3efabf1c33
10 changed files with 160 additions and 53 deletions

View file

@ -173,7 +173,7 @@ void EditorCanvas::SetMoves(HalfMove *moves, HalfMove *current) {
}
void EditorCanvas::OnKeyEvent(wxKeyEvent &event) {
if (event.GetKeyCode() == WXK_LEFT) {
/*if (event.GetKeyCode() == WXK_LEFT) {
wxCommandEvent previousEvent(PREVIOUS_MOVE_EVENT, GetId());
previousEvent.SetEventObject(this);
ProcessEvent(previousEvent);
@ -181,7 +181,7 @@ void EditorCanvas::OnKeyEvent(wxKeyEvent &event) {
wxCommandEvent nextEvent(NEXT_MOVE_EVENT, GetId());
nextEvent.SetEventObject(this);
ProcessEvent(nextEvent);
}
}*/
}
wxBEGIN_EVENT_TABLE(EditorCanvas, wxPanel) EVT_PAINT(EditorCanvas::OnPaint)