From aa524c8039c27b7b2f2e7be56045484ba9108ee6 Mon Sep 17 00:00:00 2001 From: kingosticks Date: Wed, 4 Mar 2015 21:41:52 +0000 Subject: [PATCH] Change play/pause control text with play state --- mopidy_musicbox_webclient/static/index.html | 8 ++++---- mopidy_musicbox_webclient/static/js/controls.js | 4 ++++ 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/mopidy_musicbox_webclient/static/index.html b/mopidy_musicbox_webclient/static/index.html index 123b148..2a9a02f 100644 --- a/mopidy_musicbox_webclient/static/index.html +++ b/mopidy_musicbox_webclient/static/index.html @@ -433,7 +433,7 @@
Play + alt="Play" id="playimg" title="Play"/>
@@ -447,9 +447,9 @@

- -   -   + +   +  
diff --git a/mopidy_musicbox_webclient/static/js/controls.js b/mopidy_musicbox_webclient/static/js/controls.js index 407ef92..07a324d 100644 --- a/mopidy_musicbox_webclient/static/js/controls.js +++ b/mopidy_musicbox_webclient/static/js/controls.js @@ -262,10 +262,14 @@ function doShuffle() { function setPlayState(nwplay) { if (nwplay) { $("#playimg").attr('src', 'images/icons/pause_32x32.png'); + $("#playimg").attr('title', 'Pause'); $("#btplayNowPlaying >i").removeClass('fa-play').addClass('fa-pause'); + $("#btplayNowPlaying").attr('title', 'Pause'); } else { $("#playimg").attr('src', 'images/icons/play_alt_32x32.png'); + $("#playimg").attr('title', 'Play'); $("#btplayNowPlaying >i").removeClass('fa-pause').addClass('fa-play'); + $("#btplayNowPlaying").attr('title', 'Play'); } play = nwplay; }