From f12a07a364677839605e4c820a0f8abd3234f1af Mon Sep 17 00:00:00 2001 From: jrviz Date: Wed, 23 Feb 2022 11:25:46 +0000 Subject: [PATCH 1/2] Add upper case text option --- config.js | 1 + help.md | 8 +++++++- index.html | 42 +++++++++++++++++++++++++----------------- index.js | 32 +++++++++++++++++++------------- package.json | 2 +- 5 files changed, 53 insertions(+), 32 deletions(-) diff --git a/config.js b/config.js index 276910b..c685de8 100644 --- a/config.js +++ b/config.js @@ -7,6 +7,7 @@ module.exports = new Store({ propresenterPort: '49610', propresenterPassword: '', switch_PPimages: false, + switch_PPUCase: false, presentationbridgeHost: '', presentationbridgePort: '80', presentationbridgeID: '', diff --git a/help.md b/help.md index 5a721b5..183989f 100644 --- a/help.md +++ b/help.md @@ -4,7 +4,13 @@ This software is designed to work with your presentation lyrics software, access THe Settings window is used to configure the software for ProPresenter, PresentationBridge, midi-relay, Vista, Companion and HTTP. -Text on slides is sent to the bridge for display on devices that are connected. Images of the slides will be sent if the 'Send Images' switch in settings is on. The stage display shows the slide text and notes for both the current slide and next. +Text on slides is sent to the bridge for display on devices that are connected. + +Text will be converted to upper case if the 'Upper Case' switch is set. This is used to match text display if a ProPresenter upper case theme is being used. + +Images of the slides will be sent if the 'Send Images' switch in settings is on. + +The stage display shows the slide text and notes for both the current slide and next. In addition, using the notes section of a slide, this Client can also send commands using midi-relay, HTTP and Companion: * Send MIDI voice messages, using the free program [midi-relay](http://github.com/josephdadams/midi-relay) diff --git a/index.html b/index.html index 186cb6f..0a6946e 100644 --- a/index.html +++ b/index.html @@ -195,6 +195,7 @@ $('#divTopLine').html(' v' + package_json.version) $('#switchPPimages').prop('checked', config.get('switch_PPimages')); + $('#switchPPUCase').prop('checked', config.get('switch_PPUCase')); $('#txtProPresenterIP').val(config.get('propresenterIP')); $('#txtProPresenterPort').val(config.get('propresenterPort')); $('#txtProPresenterPassword').val(config.get('propresenterPassword')); @@ -354,6 +355,9 @@ case 'PPimages': enable = $('#switchPPimages').prop('checked'); break; + case 'PPUCase': + enable = $('#switchPPUCase').prop('checked'); + break; default: break; } @@ -395,15 +399,9 @@

Created by techministry.blog

ProPresenter: -
+
-
-
- - -
-
@@ -439,6 +437,20 @@

Created by techministry.blog

+
+
+
+ + +
+
+
+
+ + +
+
+
@@ -489,7 +501,6 @@

Created by techministry.blog

-

@@ -571,6 +582,12 @@

Created by techministry.blog

+
+
+ + +
+
@@ -588,15 +605,6 @@

Created by techministry.blog

-
-
-
-
- - -
-
-
diff --git a/index.js b/index.js index da85618..1061412 100644 --- a/index.js +++ b/index.js @@ -440,17 +440,19 @@ function propresenter_connect() { }); propresenter_socket.on('error', function (err) { - if (err.errno.indexOf('ECONNREFUSED') > -1) { - propresenter_status = 'econnrefused'; - SendStatusMessage(); - trayMenuItems[0].label = 'Connection Refused: ' + ip + ':' + port; - buildTray(); - } - else if (err.errno.indexOf('ETIMEDOUT') > -1) { - propresenter_status = 'etimedout'; - SendStatusMessage(); - trayMenuItems[0].label = 'Connection Timed Out: ' + ip + ':' + port; - buildTray(); + if (err.errno !== undefined){ + if (err.errno.indexOf('ECONNREFUSED') > -1) { + propresenter_status = 'econnrefused'; + SendStatusMessage(); + trayMenuItems[0].label = 'Connection Refused: ' + ip + ':' + port; + buildTray(); + } + else if (err.errno.indexOf('ETIMEDOUT') > -1) { + propresenter_status = 'etimedout'; + SendStatusMessage(); + trayMenuItems[0].label = 'Connection Timed Out: ' + ip + ':' + port; + buildTray(); + } } }); @@ -645,10 +647,14 @@ function handleStageDisplayMessage(message) { case 'fv': for (let i = 0; i < objData.ary.length; i++) { if (objData.ary[i].acn === 'cs') { - propresenter_cs = objData.ary[i].txt; + if(config.get('switch_PPUCase')) { + propresenter_cs = objData.ary[i].txt.toUpperCase(); + } else { + propresenter_cs = objData.ary[i].txt; + } if (lyrics_on) { if (bridgeConnected) { - bridgeIO.emit('current_slide', config.get('presentationbridgeID'), objData.ary[i].txt); + bridgeIO.emit('current_slide', config.get('presentationbridgeID'), propresenter_cs); if(config.get('switch_PPimages')) { sendProPresenterImage(objData.ary[i].uid) } diff --git a/package.json b/package.json index 21a622e..6e7c14e 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "presentationbridge-client", "productName": "PresentationBridge Client", - "version": "1.0.12", + "version": "1.0.13", "description": "Links data from your Presentation / lyrics software to other software.", "license": "MIT", "repository": "josephdadams/presentationbridge-client", From 1770be87f702ee7f607315f3931059871bfdaaae Mon Sep 17 00:00:00 2001 From: James Rankin Date: Wed, 23 Feb 2022 11:27:32 +0000 Subject: [PATCH 2/2] typo --- help.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/help.md b/help.md index 183989f..c017a6d 100644 --- a/help.md +++ b/help.md @@ -2,7 +2,7 @@ This software is designed to work with your presentation lyrics software, accessing slide data in real time and then performing custom actions. It integrates with PresentationBridge, a free server program that allows you to send lyric data to end devices such as phones, tablets, and tv sticks through the built in web browser on those devices. -THe Settings window is used to configure the software for ProPresenter, PresentationBridge, midi-relay, Vista, Companion and HTTP. +The Settings window is used to configure the software for ProPresenter, PresentationBridge, midi-relay, Vista, Companion and HTTP. Text on slides is sent to the bridge for display on devices that are connected. @@ -187,4 +187,4 @@ Format: `logo:[switch];` * `switch`: Either `on` or `off` -Example: `logo:on;` : To turn the logo on. \ No newline at end of file +Example: `logo:on;` : To turn the logo on.