summaryrefslogtreecommitdiff
path: root/plugins/gtkui
diff options
context:
space:
mode:
authorGravatar Alexey Yakovenko <waker@users.sourceforge.net>2014-07-10 20:02:13 +0200
committerGravatar Alexey Yakovenko <waker@users.sourceforge.net>2014-07-10 20:02:13 +0200
commitd1748031d9a296056f92f9aadc8abe76ae74e7bd (patch)
tree0f49dcb732b32cce6945c47168f39dec063b5873 /plugins/gtkui
parentc8938c7bf2dbcbbc68c92140d6dd4b3c566e7d3e (diff)
fixed "play" action when nothing is selected and playback is stopped (bug #1148)
Diffstat (limited to 'plugins/gtkui')
-rw-r--r--plugins/gtkui/callbacks.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/plugins/gtkui/callbacks.c b/plugins/gtkui/callbacks.c
index 913a17fb..981e2a63 100644
--- a/plugins/gtkui/callbacks.c
+++ b/plugins/gtkui/callbacks.c
@@ -153,6 +153,9 @@ on_playbtn_clicked (GtkButton *button,
cur = deadbeef->plt_get_cursor (plt, PL_MAIN);
deadbeef->plt_unref (plt);
}
+ if (cur == -1) {
+ cur = 0;
+ }
deadbeef->sendmessage (DB_EV_PLAY_NUM, 0, cur, 0);
}
}