diff options
Diffstat (limited to 'src/main.c')
-rw-r--r-- | src/main.c | 16 |
1 files changed, 16 insertions, 0 deletions
@@ -320,6 +320,7 @@ int main (int argc, char **argv) { struct pollfd polls = {fileno (stdin), POLLIN, POLLIN}; char buf, yesnoBuf; char *lineBuf, *musicId; + PianoStation_t *moveStation; if (poll (&polls, 1, 1000) > 0) { read (fileno (stdin), &buf, sizeof (buf)); @@ -417,6 +418,21 @@ int main (int argc, char **argv) { case 'n': player.doQuit = 1; break; + + case 'm': + moveStation = BarUiSelectStation (&ph); + if (moveStation != NULL) { + printf ("Moving song to \"%s\"...", moveStation->name); + fflush (stdout); + if (PianoMoveSong (&ph, curStation, moveStation, + curSong) == PIANO_RET_OK) { + printf ("Ok.\n"); + player.doQuit = 1; + } else { + printf ("Error.\n"); + } + } + break; case 'p': player.doPause = !player.doPause; |