2 Commits
Author SHA1 Message Date
mmacierzanka 97f1988a11 0.3.1 2021-05-30 01:09:08 +02:00
mmacierzanka e4a5088ce2 fixed a bug that could crash the program when no file was selected 2021-05-30 01:07:32 +02:00
2 changed files with 3 additions and 3 deletions

No files matched your search

BIN
View File
Binary file not shown.
+3 -3
View File
@@ -234,16 +234,16 @@ LRESULT CALLBACK WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam) {
else if ((HWND)lParam == playButton) {
switch (currentState) {
case 0:
Play(path, selected);
SendMessage(mainWindow, STATE_CHANGE, 1, NULL);
Play(path, selected);
break;
case 1:
mciSendString(L"pause mp3", NULL, 0, NULL);
SendMessage(mainWindow, STATE_CHANGE, 2, NULL);
mciSendString(L"pause mp3", NULL, 0, NULL);
break;
case 2:
mciSendString(L"resume mp3", NULL, 0, NULL);
SendMessage(mainWindow, STATE_CHANGE, 1, NULL);
mciSendString(L"resume mp3", NULL, 0, NULL);
break;
}
}