Start adding file playback queue support
This commit is contained in:
parent
30d4e65061
commit
f2769e5062
6 changed files with 98 additions and 4 deletions
|
|
@ -310,7 +310,7 @@ PlaylistModule.prototype.handleQueue = function (user, data) {
|
|||
}
|
||||
|
||||
/* Specifying a custom title is currently only allowed for custom media */
|
||||
if (typeof data.title !== "string" || data.type !== "cu") {
|
||||
if (typeof data.title !== "string" || (data.type !== "cu" && data.type !== "fi")) {
|
||||
data.title = false;
|
||||
}
|
||||
|
||||
|
|
@ -860,6 +860,14 @@ PlaylistModule.prototype._addItem = function (media, data, user, cb) {
|
|||
});
|
||||
}
|
||||
|
||||
/* Warn about high bitrate for raw files */
|
||||
if (media.type === "fi" && media.meta.bitrate > 1000) {
|
||||
user.socket.emit("queueWarn", {
|
||||
msg: "This video has a bitrate over 1000kbps. Clients with slow " +
|
||||
"connections may experience lots of buffering."
|
||||
});
|
||||
}
|
||||
|
||||
var item = new PlaylistItem(media, {
|
||||
uid: self._nextuid++,
|
||||
temp: data.temp,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue