From db0301c8ccba4468191b0deb0ba5802f93162af2 Mon Sep 17 00:00:00 2001 From: jmoenig Date: Wed, 6 Mar 2019 17:08:53 +0100 Subject: [PATCH] let users turn off microphone manually in the settings menu (in the offline version) --- HISTORY.md | 1 + snap.html | 2 +- src/gui.js | 8 +++++++- 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/HISTORY.md b/HISTORY.md index 0460f661..072d7921 100755 --- a/HISTORY.md +++ b/HISTORY.md @@ -53,6 +53,7 @@ * removed "loudness / microphone" block from AudioComp lib (turned into primitive) * new "microphone" reporter in Sensing for getting volume, signals and frequencies * Objects: keep microphone always on when running Snap! locally +* GUI: let users turn off microphone manually in the settings menu (in the offline version) ### 2019-03-05 * GUI: added "globe" icon to language menu item diff --git a/snap.html b/snap.html index 3611a7bf..0e5885a3 100755 --- a/snap.html +++ b/snap.html @@ -9,7 +9,7 @@ - + diff --git a/src/gui.js b/src/gui.js index d31e7da2..14441630 100644 --- a/src/gui.js +++ b/src/gui.js @@ -75,7 +75,7 @@ isRetinaSupported, SliderMorph, Animation, BoxMorph, MediaRecorder*/ // Global stuff //////////////////////////////////////////////////////// -modules.gui = '2019-March-05'; +modules.gui = '2019-March-06'; // Declarations @@ -2773,6 +2773,12 @@ IDE_Morph.prototype.settingsMenu = function () { new Color(100, 0, 0) ); } + if (stage.microphone.isReady) { + menu.addItem( + '\u2611 ' + localize('Microphone'), + function () {stage.microphone.stop(); } + ); + } menu.addLine(); /* addPreference(