Skip to content

Commit

Permalink
Added audio enable and disable checkbox .
Browse files Browse the repository at this point in the history
  • Loading branch information
Zhou Chang committed Nov 17, 2012
1 parent e53f7c0 commit e7edf33
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 5 deletions.
13 changes: 9 additions & 4 deletions assets/droideye.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,15 +89,20 @@ var playClick = function () {
inStreaming = true;
$("#btn_play").val("Stop").button("refresh");
$("#resolution-choice").selectmenu("disable");
refreshLive();
$("#checkbox-audio").checkboxradio('disable');

var newClip = {'url':'stream/live.mp3?id='+audioCount,'autoplay':true};
audioCount ++;
audioPlayer.play(newClip);
refreshLive();

if ( $("#checkbox-audio").is(":checked") ) {
var newClip = {'url':'stream/live.mp3?id='+audioCount,'autoplay':true};
audioCount ++;
audioPlayer.play(newClip);
}
} else {
inStreaming = false;
$("#btn_play").val("Play").button("refresh");
$("#resolution-choice").selectmenu("enable");
$("#checkbox-audio").checkboxradio('enable');
audioPlayer.stop();
audioPlayer.close();
}
Expand Down
2 changes: 2 additions & 0 deletions assets/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@
<span>Video size:</span>
<select name="resolution-choice" id="resolution-choice" data-native-menu="false">
</select>
<input type="checkbox" id="checkbox-audio" class="custom" />
<label for="checkbox-audio">Enable Audio</label>
<input id="btn_play" type="button" value="Play Video"/>
</div>
</li>
Expand Down
Binary file removed libs/GoogleAdMobAdsSdk-6.1.0.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
<string name="msg_access_local">Open at local: </string>
<string name="msg_access_internet">Open at internet: </string>
<string name="msg_access_query">Detecting internet ... </string>
<string name="msg_access_query_error">Setup router manually to open at internet</string>
<string name="msg_access_query_error">Also you can setup your router to access from internet</string>
<string name="msg_error">Error: Please enable wifi</string>
</resources>

0 comments on commit e7edf33

Please sign in to comment.