summaryrefslogtreecommitdiff
path: root/smarttv-client/Javascript/Player.js
diff options
context:
space:
mode:
authorthlo <smarttv640@gmail.com>2013-01-05 22:57:10 +0100
committerthlo <t.lohmar@gmx.de>2013-01-05 22:57:10 +0100
commit67628780e113ae61ef49b1e458f531b7197ee93b (patch)
tree0b12bca3721b960105e454f85ab19134c07fb802 /smarttv-client/Javascript/Player.js
parent0adab5a1ba140dda76e34a9347d69247c4de2263 (diff)
downloadvdr-plugin-smarttvweb-67628780e113ae61ef49b1e458f531b7197ee93b.tar.gz
vdr-plugin-smarttvweb-67628780e113ae61ef49b1e458f531b7197ee93b.tar.bz2
Disable screen saver during playback.
Basic BD Player Front Panel Feedback. Fix for native Vol OSD. Bug Fixes.
Diffstat (limited to 'smarttv-client/Javascript/Player.js')
-rwxr-xr-xsmarttv-client/Javascript/Player.js33
1 files changed, 23 insertions, 10 deletions
diff --git a/smarttv-client/Javascript/Player.js b/smarttv-client/Javascript/Player.js
index d54a761..72c6d30 100755
--- a/smarttv-client/Javascript/Player.js
+++ b/smarttv-client/Javascript/Player.js
@@ -5,6 +5,8 @@
var Player =
{
plugin : null,
+ pluginBD : null,
+ mFrontPanel : null,
isLive : false,
isRecording : false,
@@ -42,7 +44,9 @@ Player.init = function() {
this.state = this.STOPPED;
this.plugin = document.getElementById("pluginPlayer");
-
+ this.pluginBD = document.getElementById("pluginBD");
+ this.pluginBD.DisplayVFD_Show(0101); // Stop
+
/* var pl_version = "";
try {
pl_version = this.plugin.GetPlayerVersion();
@@ -148,9 +152,11 @@ Player.playVideo = function() {
if (this.url == null) {
Main.log("No videos to play");
}
- else
- {
+ else {
+ Player.bufferState = 0;
+ Display.bufferUpdate();
+
// Player.curPlayTime = 0;
Display.updatePlayTime();
@@ -159,31 +165,35 @@ Player.playVideo = function() {
Display.showProgress();
this.state = this.PLAYING;
- if (this.plugin.InitPlayer(this.url) == false)
- Display.showPopup("InitPlayer returns false");
+// if (this.plugin.InitPlayer(this.url) == false)
+// Display.showPopup("InitPlayer returns false");
Player.setBuffer(15000000.0);
Player.ResetTrickPlay();
Player.skipDuration = Config.skipDuration; // reset
Main.log ("StartPlayback for " + this.url);
- if (this.plugin.StartPlayback() == false)
- Display.showPopup("StartPlayback returns false");
+// if (this.plugin.StartPlayback() == false)
+// Display.showPopup("StartPlayback returns false");
-// this.plugin.Play( this.url );
+ this.plugin.Play( this.url );
Audio.plugin.SetSystemMute(false);
+ pluginObj.setOffScreenSaver();
+ this.pluginBD.DisplayVFD_Show(0100); // Play
}
};
Player.pauseVideo = function() {
Display.showProgress();
Main.logToServer("pauseVideo");
-
+
this.state = this.PAUSED;
Display.status("Pause");
var res = this.plugin.Pause();
if (res == false)
Display.showPopup("pause ret= " + ((res == true) ? "True" : "False"));
+ pluginAPI.setOnScreenSaver();
+ this.pluginBD.DisplayVFD_Show(0102); // Pause
};
Player.stopVideo = function() {
@@ -197,6 +207,8 @@ Player.stopVideo = function() {
if (this.stopCallback) {
this.stopCallback();
}
+ pluginAPI.setOnScreenSaver();
+ this.pluginBD.DisplayVFD_Show(0101); // Stop
}
else {
Main.log("Ignoring stop request, not in correct state");
@@ -211,7 +223,8 @@ Player.resumeVideo = function() {
var res = this.plugin.Resume();
if (res == false)
Display.showPopup("resume ret= " + ((res == true) ? "True" : "False"));
-
+ pluginObj.setOffScreenSaver();
+ this.pluginBD.DisplayVFD_Show(0100); // Play
};
Player.jumpToVideo = function(percent) {