diff options
author | Cheng-Yi Chiang <cychiang@chromium.org> | 2014-03-11 22:06:05 +0800 |
---|---|---|
committer | chrome-internal-fetch <chrome-internal-fetch@google.com> | 2014-03-17 08:42:00 +0000 |
commit | fee0261a882c659aaab25d98bad695755ab66cb2 (patch) | |
tree | d3807c5c15c37c1a397c7d30b192d2fc46f19a5c /scripts | |
parent | 91977cf7045d3610c574af49f69c41a856c83c57 (diff) | |
download | adhd-fee0261a882c659aaab25d98bad695755ab66cb2.tar.gz |
scripts: Fix audio-tuning frontend emphasis_disabled config setting
When setting config from UI or applying config from config file,
drc.emphasis_disabled should be skipped since it is a tag and is
different from other configs that can actually be set to the audio
processing graph.
BUG=chrome-os-partner:26686
TEST=run audio-tuning frontend and check console there is no error
message complaining 'config' is not defined.
Change-Id: Ia7cbfc09fb7a904bb81abd0ae9b44a9f4524e3f0
Reviewed-on: https://chromium-review.googlesource.com/189566
Reviewed-by: Chih-Chung Chang <chihchung@chromium.org>
Commit-Queue: Cheng-Yi Chiang <cychiang@chromium.org>
Tested-by: Cheng-Yi Chiang <cychiang@chromium.org>
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/audio_tuning/frontend/audio.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/scripts/audio_tuning/frontend/audio.js b/scripts/audio_tuning/frontend/audio.js index 51f2bdfb..4f09c1a2 100644 --- a/scripts/audio_tuning/frontend/audio.js +++ b/scripts/audio_tuning/frontend/audio.js @@ -541,7 +541,7 @@ function drc_3band() { function config(name, value) { if (name[1] == 'f') { xo.config(name, value); - } else { + } else if (name[0] != 'emphasis_disabled') { var n = parseInt(name[0]); drcs[n].config(name.slice(1), value); } @@ -1455,6 +1455,9 @@ function ui() { if (p == 'global') { global.config(name.slice(1), value); } else if (p == 'drc') { + if (name[1] == 'emphasis_disabled') { + return; + } drc_cards[i].config(s, value); } else if (p == 'eq') { eq_sections[i].config(s, value); |