diff options
| author | Jules Laplace <jules@okfoc.us> | 2016-09-11 15:50:47 -0400 |
|---|---|---|
| committer | Jules Laplace <jules@okfoc.us> | 2016-09-11 15:50:47 -0400 |
| commit | 7243fd7cf75e59b2ea45def413788020a663679f (patch) | |
| tree | 5322fe964fa613d1938faee31b063b1eae7fc957 /env.js | |
| parent | 642a0e99cfb4aeaa71cc1ac51739608ef6225b99 (diff) | |
is stated
Diffstat (limited to 'env.js')
| -rw-r--r-- | env.js | 11 |
1 files changed, 7 insertions, 4 deletions
@@ -18,14 +18,16 @@ var environment = (function(){ ] environment.init = function(){ - environment.ready() + if (is_mobile) { + environment.request_audio_context() + } + else { + environment.ready() + } } environment.ready = function(){ environment.build() environment.bind() - if (is_mobile) { - environment.request_audio_context() - } } environment.request_audio_context = function(){ var element = $("<div>", {"id" : "MobileStart"}).appendTo("body") @@ -34,6 +36,7 @@ var environment = (function(){ StartAudioContext.on(button) StartAudioContext.onStarted(function(){ element.remove() + environment.ready() }) } environment.build = function(){ |
