From 69e721e5cf52837c30bf1ddfd6d59f242777d2d2 Mon Sep 17 00:00:00 2001 From: Ylian Saint-Hilaire Date: Fri, 4 Oct 2019 17:32:23 -0700 Subject: [PATCH] Added desktop toolbar support in debug mode. --- package.json | 2 +- views/default-min.handlebars | 2 +- views/default.handlebars | 7 +++++-- 3 files changed, 7 insertions(+), 4 deletions(-) diff --git a/package.json b/package.json index 36e1b4b5..f7cf3e00 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "meshcentral", - "version": "0.4.1-t", + "version": "0.4.1-u", "keywords": [ "Remote Management", "Intel AMT", diff --git a/views/default-min.handlebars b/views/default-min.handlebars index 6c7f7d99..9bf81382 100644 --- a/views/default-min.handlebars +++ b/views/default-min.handlebars @@ -1 +1 @@ - {{{title}}}
{{{title}}}
{{{title2}}}

{{{logoutControl}}}

 

\ No newline at end of file + {{{title}}}
{{{title}}}
{{{title2}}}

{{{logoutControl}}}

 

\ No newline at end of file diff --git a/views/default.handlebars b/views/default.handlebars index c7889394..9cf5d6e1 100644 --- a/views/default.handlebars +++ b/views/default.handlebars @@ -6942,7 +6942,7 @@ var consent = 0; if (currentMesh.consent) { consent = currentMesh.consent; } if (serverinfo.consent) { consent |= serverinfo.consent; } - if (consent & 0x0008) { meshFeatures.push('Desktop Prompt'); } else { if (consent & 0x0001) { meshFeatures.push('Desktop Notify'); } } + if ((consent & 0x0040) && (consent & 0x0008)) { meshFeatures.push('Desktop Prompt+Toolbar'); } else if (consent & 0x0040) { meshFeatures.push('Desktop Toolbar'); } else if (consent & 0x0008) { meshFeatures.push('Desktop Prompt'); } else { if (consent & 0x0001) { meshFeatures.push('Desktop Notify'); } } if (consent & 0x0010) { meshFeatures.push('Terminal Prompt'); } else { if (consent & 0x0002) { meshFeatures.push('Terminal Notify'); } } if (consent & 0x0020) { meshFeatures.push('Files Prompt'); } else { if (consent & 0x0004) { meshFeatures.push('Files Notify'); } } if (consent == 7) { meshFeatures = ['Always Notify']; } @@ -7142,9 +7142,9 @@ if (xxdialogMode) return; var x = '', consent = (currentMesh.consent) ? currentMesh.consent : 0; x += '
Desktop
'; - if (debugmode) { x += "
"; } x += "
"; x += "
"; + if (debugmode) { x += "
"; } x += '
Terminal
'; x += "
"; x += "
"; @@ -7159,12 +7159,14 @@ if (serverinfo.consent & 0x0010) { Q('d20flag4').checked = true; } if (serverinfo.consent & 0x0004) { Q('d20flag5').checked = true; } if (serverinfo.consent & 0x0020) { Q('d20flag6').checked = true; } + if (serverinfo.consent & 0x0040) { Q('d20flag7').checked = true; } QE('d20flag1', !(serverinfo.consent & 0x0001)); QE('d20flag2', !(serverinfo.consent & 0x0008)); QE('d20flag3', !(serverinfo.consent & 0x0002)); QE('d20flag4', !(serverinfo.consent & 0x0010)); QE('d20flag5', !(serverinfo.consent & 0x0004)); QE('d20flag6', !(serverinfo.consent & 0x0020)); + QE('d20flag7', !(serverinfo.consent & 0x0040)); } } @@ -7176,6 +7178,7 @@ if (Q('d20flag4').checked) { consent += 0x0010; } if (Q('d20flag5').checked) { consent += 0x0004; } if (Q('d20flag6').checked) { consent += 0x0020; } + if (Q('d20flag7').checked) { consent += 0x0040; } meshserver.send({ action: 'editmesh', meshid: currentMesh._id, consent: consent }); }