diff --git a/openlp/plugins/remotes/html/js/stage.js b/openlp/plugins/remotes/html/js/stage.js index 7da9ae840..7602b14ac 100644 --- a/openlp/plugins/remotes/html/js/stage.js +++ b/openlp/plugins/remotes/html/js/stage.js @@ -16,8 +16,8 @@ * with this program; if not, write to the Free Software Foundation, Inc., 59 * * Temple Place, Suite 330, Boston, MA 02111-1307 USA * ******************************************************************************/ - var lastChord; - +var lastChord; + function getTransposeValue(songId) { if (localStorage.getItem(songId + '_transposeValue')) {return localStorage.getItem(songId + '_transposeValue');} else {return 0;} @@ -78,7 +78,8 @@ function transposeChord(chord, transposeValue) { var OpenLPChordOverflowFillCount = 0; window.OpenLP = { - showchords:true, + showchords:false, + stageviewChords:false, loadService: function (event) { $.getJSON( "/api/service/list", @@ -251,11 +252,39 @@ window.OpenLP = { m = '0' + m + ''; div.html(h + ":" + m); }, + stageChords: function(stageviewChords) { + if (stageviewChords != OpenLP.stageviewChords) { + OpenLP.stageviewChords = stageviewChords; + OpenLP.showchords = stageviewChords; + if (!stageviewChords) { + $('#transpose').hide(); + $('#transposedown').hide(); + $('#transposevalue').hide(); + $('#transposeup').hide(); + $('#transposeup').hide(); + $('#capodisplay').hide(); + $('#chords').hide(); + $('#plus').hide(); + $('#minus').hide(); + } else { + $('#transpose').show(); + $('#transposedown').show(); + $('#transposevalue').show(); + $('#transposeup').show(); + $('#transposeup').show(); + $('#capodisplay').show(); + $('#chords').show(); + $('#plus').show(); + $('#minus').show(); + } + } + }, pollServer: function () { $.getJSON( "/api/poll", function (data, status) { OpenLP.updateClock(data); + OpenLP.stageChords(data.results.stageviewChords); if (OpenLP.currentItem != data.results.item || OpenLP.currentService != data.results.service) { OpenLP.currentItem = data.results.item; OpenLP.currentService = data.results.service; diff --git a/openlp/plugins/remotes/lib/httprouter.py b/openlp/plugins/remotes/lib/httprouter.py index 5e17088f3..f553da45d 100644 --- a/openlp/plugins/remotes/lib/httprouter.py +++ b/openlp/plugins/remotes/lib/httprouter.py @@ -477,7 +477,8 @@ class HttpRouter(RegistryProperties): 'display': self.live_controller.desktop_screen.isChecked(), 'version': 2, 'isSecure': Settings().value(self.settings_section + '/authentication enabled'), - 'isAuthorised': self.authorised + 'isAuthorised': self.authorised, + 'stageviewChords': Settings().value('songs/stageview chords'), } self.do_json_header() return json.dumps({'results': result}).encode() diff --git a/openlp/plugins/songs/songsplugin.py b/openlp/plugins/songs/songsplugin.py index de4acb686..79ffdcc54 100644 --- a/openlp/plugins/songs/songsplugin.py +++ b/openlp/plugins/songs/songsplugin.py @@ -66,9 +66,9 @@ __default_settings__ = { 'songs/songselect username': '', 'songs/songselect password': '', 'songs/songselect searches': '', - 'songs/chords': True, - 'songs/stageview chords': False, - 'songs/mainview chords': False + 'songs/stageview chords': True, + 'songs/mainview chords': False, + 'songs/disable chords import': False, }