@jellybrick/mpris-service 2.1.5 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +2244 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +314 -0
- package/dist/index.d.mts +314 -0
- package/dist/index.mjs +2244 -0
- package/dist/index.mjs.map +1 -0
- package/package.json +46 -28
- package/.dockerignore +0 -1
- package/.travis.yml +0 -9
- package/Dockerfile +0 -31
- package/Makefile +0 -14
- package/dist/constants.js +0 -20
- package/dist/constants.js.map +0 -1
- package/dist/index.js +0 -442
- package/dist/index.js.map +0 -1
- package/dist/interfaces/mpris-interface.js +0 -49
- package/dist/interfaces/mpris-interface.js.map +0 -1
- package/dist/interfaces/player.js +0 -406
- package/dist/interfaces/player.js.map +0 -1
- package/dist/interfaces/playlists.js +0 -139
- package/dist/interfaces/playlists.js.map +0 -1
- package/dist/interfaces/root.js +0 -216
- package/dist/interfaces/root.js.map +0 -1
- package/dist/interfaces/tracklist.js +0 -160
- package/dist/interfaces/tracklist.js.map +0 -1
- package/dist/interfaces/types.js +0 -78
- package/dist/interfaces/types.js.map +0 -1
- package/dist/logging.js +0 -14
- package/dist/logging.js.map +0 -1
- package/src/constants.js +0 -31
- package/src/index.js +0 -477
- package/src/interfaces/mpris-interface.js +0 -53
- package/src/interfaces/player.js +0 -204
- package/src/interfaces/playlists.js +0 -84
- package/src/interfaces/root.js +0 -99
- package/src/interfaces/tracklist.js +0 -85
- package/src/interfaces/types.js +0 -75
- package/src/logging.js +0 -13
|
@@ -1,406 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
function _decorate(e, r, t, i) { var o = _getDecoratorsApi(); if (i) for (var n = 0; n < i.length; n++) o = i[n](o); var s = r(function (e) { o.initializeInstanceElements(e, a.elements); }, t), a = o.decorateClass(_coalesceClassElements(s.d.map(_createElementDescriptor)), e); return o.initializeClassElements(s.F, a.elements), o.runClassFinishers(s.F, a.finishers); }
|
|
4
|
-
function _getDecoratorsApi() { _getDecoratorsApi = function () { return e; }; var e = { elementsDefinitionOrder: [["method"], ["field"]], initializeInstanceElements: function (e, r) { ["method", "field"].forEach(function (t) { r.forEach(function (r) { r.kind === t && "own" === r.placement && this.defineClassElement(e, r); }, this); }, this); }, initializeClassElements: function (e, r) { var t = e.prototype; ["method", "field"].forEach(function (i) { r.forEach(function (r) { var o = r.placement; if (r.kind === i && ("static" === o || "prototype" === o)) { var n = "static" === o ? e : t; this.defineClassElement(n, r); } }, this); }, this); }, defineClassElement: function (e, r) { var t = r.descriptor; if ("field" === r.kind) { var i = r.initializer; t = { enumerable: t.enumerable, writable: t.writable, configurable: t.configurable, value: void 0 === i ? void 0 : i.call(e) }; } Object.defineProperty(e, r.key, t); }, decorateClass: function (e, r) { var t = [], i = [], o = { static: [], prototype: [], own: [] }; if (e.forEach(function (e) { this.addElementPlacement(e, o); }, this), e.forEach(function (e) { if (!_hasDecorators(e)) return t.push(e); var r = this.decorateElement(e, o); t.push(r.element), t.push.apply(t, r.extras), i.push.apply(i, r.finishers); }, this), !r) return { elements: t, finishers: i }; var n = this.decorateConstructor(t, r); return i.push.apply(i, n.finishers), n.finishers = i, n; }, addElementPlacement: function (e, r, t) { var i = r[e.placement]; if (!t && -1 !== i.indexOf(e.key)) throw new TypeError("Duplicated element (" + e.key + ")"); i.push(e.key); }, decorateElement: function (e, r) { for (var t = [], i = [], o = e.decorators, n = o.length - 1; n >= 0; n--) { var s = r[e.placement]; s.splice(s.indexOf(e.key), 1); var a = this.fromElementDescriptor(e), l = this.toElementFinisherExtras((0, o[n])(a) || a); e = l.element, this.addElementPlacement(e, r), l.finisher && i.push(l.finisher); var c = l.extras; if (c) { for (var p = 0; p < c.length; p++) this.addElementPlacement(c[p], r); t.push.apply(t, c); } } return { element: e, finishers: i, extras: t }; }, decorateConstructor: function (e, r) { for (var t = [], i = r.length - 1; i >= 0; i--) { var o = this.fromClassDescriptor(e), n = this.toClassDescriptor((0, r[i])(o) || o); if (void 0 !== n.finisher && t.push(n.finisher), void 0 !== n.elements) { e = n.elements; for (var s = 0; s < e.length - 1; s++) for (var a = s + 1; a < e.length; a++) if (e[s].key === e[a].key && e[s].placement === e[a].placement) throw new TypeError("Duplicated element (" + e[s].key + ")"); } } return { elements: e, finishers: t }; }, fromElementDescriptor: function (e) { var r = { kind: e.kind, key: e.key, placement: e.placement, descriptor: e.descriptor }; return Object.defineProperty(r, Symbol.toStringTag, { value: "Descriptor", configurable: !0 }), "field" === e.kind && (r.initializer = e.initializer), r; }, toElementDescriptors: function (e) { if (void 0 !== e) return _toArray(e).map(function (e) { var r = this.toElementDescriptor(e); return this.disallowProperty(e, "finisher", "An element descriptor"), this.disallowProperty(e, "extras", "An element descriptor"), r; }, this); }, toElementDescriptor: function (e) { var r = e.kind + ""; if ("method" !== r && "field" !== r) throw new TypeError('An element descriptor\'s .kind property must be either "method" or "field", but a decorator created an element descriptor with .kind "' + r + '"'); var t = _toPropertyKey(e.key), i = e.placement + ""; if ("static" !== i && "prototype" !== i && "own" !== i) throw new TypeError('An element descriptor\'s .placement property must be one of "static", "prototype" or "own", but a decorator created an element descriptor with .placement "' + i + '"'); var o = e.descriptor; this.disallowProperty(e, "elements", "An element descriptor"); var n = { kind: r, key: t, placement: i, descriptor: Object.assign({}, o) }; return "field" !== r ? this.disallowProperty(e, "initializer", "A method descriptor") : (this.disallowProperty(o, "get", "The property descriptor of a field descriptor"), this.disallowProperty(o, "set", "The property descriptor of a field descriptor"), this.disallowProperty(o, "value", "The property descriptor of a field descriptor"), n.initializer = e.initializer), n; }, toElementFinisherExtras: function (e) { return { element: this.toElementDescriptor(e), finisher: _optionalCallableProperty(e, "finisher"), extras: this.toElementDescriptors(e.extras) }; }, fromClassDescriptor: function (e) { var r = { kind: "class", elements: e.map(this.fromElementDescriptor, this) }; return Object.defineProperty(r, Symbol.toStringTag, { value: "Descriptor", configurable: !0 }), r; }, toClassDescriptor: function (e) { var r = e.kind + ""; if ("class" !== r) throw new TypeError('A class descriptor\'s .kind property must be "class", but a decorator created a class descriptor with .kind "' + r + '"'); this.disallowProperty(e, "key", "A class descriptor"), this.disallowProperty(e, "placement", "A class descriptor"), this.disallowProperty(e, "descriptor", "A class descriptor"), this.disallowProperty(e, "initializer", "A class descriptor"), this.disallowProperty(e, "extras", "A class descriptor"); var t = _optionalCallableProperty(e, "finisher"); return { elements: this.toElementDescriptors(e.elements), finisher: t }; }, runClassFinishers: function (e, r) { for (var t = 0; t < r.length; t++) { var i = (0, r[t])(e); if (void 0 !== i) { if ("function" != typeof i) throw new TypeError("Finishers must return a constructor."); e = i; } } return e; }, disallowProperty: function (e, r, t) { if (void 0 !== e[r]) throw new TypeError(t + " can't have a ." + r + " property."); } }; return e; }
|
|
5
|
-
function _createElementDescriptor(e) { var r, t = _toPropertyKey(e.key); "method" === e.kind ? r = { value: e.value, writable: !0, configurable: !0, enumerable: !1 } : "get" === e.kind ? r = { get: e.value, configurable: !0, enumerable: !1 } : "set" === e.kind ? r = { set: e.value, configurable: !0, enumerable: !1 } : "field" === e.kind && (r = { configurable: !0, writable: !0, enumerable: !0 }); var i = { kind: "field" === e.kind ? "field" : "method", key: t, placement: e.static ? "static" : "field" === e.kind ? "own" : "prototype", descriptor: r }; return e.decorators && (i.decorators = e.decorators), "field" === e.kind && (i.initializer = e.value), i; }
|
|
6
|
-
function _coalesceGetterSetter(e, r) { void 0 !== e.descriptor.get ? r.descriptor.get = e.descriptor.get : r.descriptor.set = e.descriptor.set; }
|
|
7
|
-
function _coalesceClassElements(e) { for (var r = [], isSameElement = function (e) { return "method" === e.kind && e.key === o.key && e.placement === o.placement; }, t = 0; t < e.length; t++) { var i, o = e[t]; if ("method" === o.kind && (i = r.find(isSameElement))) { if (_isDataDescriptor(o.descriptor) || _isDataDescriptor(i.descriptor)) { if (_hasDecorators(o) || _hasDecorators(i)) throw new ReferenceError("Duplicated methods (" + o.key + ") can't be decorated."); i.descriptor = o.descriptor; } else { if (_hasDecorators(o)) { if (_hasDecorators(i)) throw new ReferenceError("Decorators can't be placed on different accessors with for the same property (" + o.key + ")."); i.decorators = o.decorators; } _coalesceGetterSetter(o, i); } } else r.push(o); } return r; }
|
|
8
|
-
function _hasDecorators(e) { return e.decorators && e.decorators.length; }
|
|
9
|
-
function _isDataDescriptor(e) { return void 0 !== e && !(void 0 === e.value && void 0 === e.writable); }
|
|
10
|
-
function _optionalCallableProperty(e, r) { var t = e[r]; if (void 0 !== t && "function" != typeof t) throw new TypeError("Expected '" + r + "' to be a function"); return t; }
|
|
11
|
-
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
12
|
-
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
13
|
-
function _toArray(r) { return _arrayWithHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableRest(); }
|
|
14
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
15
|
-
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
16
|
-
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
17
|
-
function _iterableToArray(r) { if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r); }
|
|
18
|
-
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
19
|
-
const dbus = require('@jellybrick/dbus-next');
|
|
20
|
-
const MprisInterface = require('./mpris-interface');
|
|
21
|
-
const constants = require('../constants');
|
|
22
|
-
const {
|
|
23
|
-
property,
|
|
24
|
-
method,
|
|
25
|
-
signal,
|
|
26
|
-
ACCESS_READ
|
|
27
|
-
} = dbus.interface;
|
|
28
|
-
const DBusError = dbus.DBusError;
|
|
29
|
-
let PlayerInterface = _decorate(null, function (_initialize, _MprisInterface) {
|
|
30
|
-
class PlayerInterface extends _MprisInterface {
|
|
31
|
-
constructor(player) {
|
|
32
|
-
super('org.mpris.MediaPlayer2.Player', player);
|
|
33
|
-
_initialize(this);
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
return {
|
|
37
|
-
F: PlayerInterface,
|
|
38
|
-
d: [{
|
|
39
|
-
kind: "field",
|
|
40
|
-
key: "_CanControl",
|
|
41
|
-
value() {
|
|
42
|
-
return true;
|
|
43
|
-
}
|
|
44
|
-
}, {
|
|
45
|
-
kind: "field",
|
|
46
|
-
key: "_CanPause",
|
|
47
|
-
value() {
|
|
48
|
-
return true;
|
|
49
|
-
}
|
|
50
|
-
}, {
|
|
51
|
-
kind: "field",
|
|
52
|
-
key: "_CanPlay",
|
|
53
|
-
value() {
|
|
54
|
-
return true;
|
|
55
|
-
}
|
|
56
|
-
}, {
|
|
57
|
-
kind: "field",
|
|
58
|
-
key: "_CanSeek",
|
|
59
|
-
value() {
|
|
60
|
-
return true;
|
|
61
|
-
}
|
|
62
|
-
}, {
|
|
63
|
-
kind: "field",
|
|
64
|
-
key: "_CanGoNext",
|
|
65
|
-
value() {
|
|
66
|
-
return true;
|
|
67
|
-
}
|
|
68
|
-
}, {
|
|
69
|
-
kind: "field",
|
|
70
|
-
key: "_CanGoPrevious",
|
|
71
|
-
value() {
|
|
72
|
-
return true;
|
|
73
|
-
}
|
|
74
|
-
}, {
|
|
75
|
-
kind: "field",
|
|
76
|
-
key: "_Metadata",
|
|
77
|
-
value() {
|
|
78
|
-
return {};
|
|
79
|
-
}
|
|
80
|
-
}, {
|
|
81
|
-
kind: "field",
|
|
82
|
-
key: "_MaximumRate",
|
|
83
|
-
value() {
|
|
84
|
-
return 1;
|
|
85
|
-
}
|
|
86
|
-
}, {
|
|
87
|
-
kind: "field",
|
|
88
|
-
key: "_MinimumRate",
|
|
89
|
-
value() {
|
|
90
|
-
return 1;
|
|
91
|
-
}
|
|
92
|
-
}, {
|
|
93
|
-
kind: "field",
|
|
94
|
-
key: "_Rate",
|
|
95
|
-
value() {
|
|
96
|
-
return 1;
|
|
97
|
-
}
|
|
98
|
-
}, {
|
|
99
|
-
kind: "field",
|
|
100
|
-
key: "_Shuffle",
|
|
101
|
-
value() {
|
|
102
|
-
return false;
|
|
103
|
-
}
|
|
104
|
-
}, {
|
|
105
|
-
kind: "field",
|
|
106
|
-
key: "_Volume",
|
|
107
|
-
value() {
|
|
108
|
-
return 0;
|
|
109
|
-
}
|
|
110
|
-
}, {
|
|
111
|
-
kind: "field",
|
|
112
|
-
key: "_LoopStatus",
|
|
113
|
-
value() {
|
|
114
|
-
return constants.LOOP_STATUS_NONE;
|
|
115
|
-
}
|
|
116
|
-
}, {
|
|
117
|
-
kind: "field",
|
|
118
|
-
key: "_PlaybackStatus",
|
|
119
|
-
value() {
|
|
120
|
-
return constants.PLAYBACK_STATUS_STOPPED;
|
|
121
|
-
}
|
|
122
|
-
}, {
|
|
123
|
-
kind: "get",
|
|
124
|
-
decorators: [property({
|
|
125
|
-
signature: 'b',
|
|
126
|
-
access: ACCESS_READ
|
|
127
|
-
})],
|
|
128
|
-
key: "CanControl",
|
|
129
|
-
value: function () {
|
|
130
|
-
return this._CanControl;
|
|
131
|
-
}
|
|
132
|
-
}, {
|
|
133
|
-
kind: "get",
|
|
134
|
-
decorators: [property({
|
|
135
|
-
signature: 'b',
|
|
136
|
-
access: ACCESS_READ
|
|
137
|
-
})],
|
|
138
|
-
key: "CanPause",
|
|
139
|
-
value: function () {
|
|
140
|
-
return this._CanPause;
|
|
141
|
-
}
|
|
142
|
-
}, {
|
|
143
|
-
kind: "get",
|
|
144
|
-
decorators: [property({
|
|
145
|
-
signature: 'b',
|
|
146
|
-
access: ACCESS_READ
|
|
147
|
-
})],
|
|
148
|
-
key: "CanPlay",
|
|
149
|
-
value: function () {
|
|
150
|
-
return this._CanPlay;
|
|
151
|
-
}
|
|
152
|
-
}, {
|
|
153
|
-
kind: "get",
|
|
154
|
-
decorators: [property({
|
|
155
|
-
signature: 'b',
|
|
156
|
-
access: ACCESS_READ
|
|
157
|
-
})],
|
|
158
|
-
key: "CanSeek",
|
|
159
|
-
value: function () {
|
|
160
|
-
return this._CanSeek;
|
|
161
|
-
}
|
|
162
|
-
}, {
|
|
163
|
-
kind: "get",
|
|
164
|
-
decorators: [property({
|
|
165
|
-
signature: 'b',
|
|
166
|
-
access: ACCESS_READ
|
|
167
|
-
})],
|
|
168
|
-
key: "CanGoNext",
|
|
169
|
-
value: function () {
|
|
170
|
-
return this._CanGoNext;
|
|
171
|
-
}
|
|
172
|
-
}, {
|
|
173
|
-
kind: "get",
|
|
174
|
-
decorators: [property({
|
|
175
|
-
signature: 'b',
|
|
176
|
-
access: ACCESS_READ
|
|
177
|
-
})],
|
|
178
|
-
key: "CanGoPrevious",
|
|
179
|
-
value: function () {
|
|
180
|
-
return this._CanGoPrevious;
|
|
181
|
-
}
|
|
182
|
-
}, {
|
|
183
|
-
kind: "get",
|
|
184
|
-
decorators: [property({
|
|
185
|
-
signature: 'a{sv}',
|
|
186
|
-
access: ACCESS_READ
|
|
187
|
-
})],
|
|
188
|
-
key: "Metadata",
|
|
189
|
-
value: function () {
|
|
190
|
-
return this._Metadata;
|
|
191
|
-
}
|
|
192
|
-
}, {
|
|
193
|
-
kind: "get",
|
|
194
|
-
decorators: [property({
|
|
195
|
-
signature: 'd',
|
|
196
|
-
access: ACCESS_READ
|
|
197
|
-
})],
|
|
198
|
-
key: "MaximumRate",
|
|
199
|
-
value: function () {
|
|
200
|
-
return this._MaximumRate;
|
|
201
|
-
}
|
|
202
|
-
}, {
|
|
203
|
-
kind: "get",
|
|
204
|
-
decorators: [property({
|
|
205
|
-
signature: 'd',
|
|
206
|
-
access: ACCESS_READ
|
|
207
|
-
})],
|
|
208
|
-
key: "MinimumRate",
|
|
209
|
-
value: function () {
|
|
210
|
-
return this._MinimumRate;
|
|
211
|
-
}
|
|
212
|
-
}, {
|
|
213
|
-
kind: "get",
|
|
214
|
-
decorators: [property({
|
|
215
|
-
signature: 'd'
|
|
216
|
-
})],
|
|
217
|
-
key: "Rate",
|
|
218
|
-
value: function () {
|
|
219
|
-
return this._Rate;
|
|
220
|
-
}
|
|
221
|
-
}, {
|
|
222
|
-
kind: "set",
|
|
223
|
-
key: "Rate",
|
|
224
|
-
value: function (value) {
|
|
225
|
-
this._setPropertyInternal('Rate', value);
|
|
226
|
-
}
|
|
227
|
-
}, {
|
|
228
|
-
kind: "get",
|
|
229
|
-
decorators: [property({
|
|
230
|
-
signature: 'b'
|
|
231
|
-
})],
|
|
232
|
-
key: "Shuffle",
|
|
233
|
-
value: function () {
|
|
234
|
-
return this._Shuffle;
|
|
235
|
-
}
|
|
236
|
-
}, {
|
|
237
|
-
kind: "set",
|
|
238
|
-
key: "Shuffle",
|
|
239
|
-
value: function (value) {
|
|
240
|
-
this._setPropertyInternal('Shuffle', value);
|
|
241
|
-
}
|
|
242
|
-
}, {
|
|
243
|
-
kind: "get",
|
|
244
|
-
decorators: [property({
|
|
245
|
-
signature: 'd'
|
|
246
|
-
})],
|
|
247
|
-
key: "Volume",
|
|
248
|
-
value: function () {
|
|
249
|
-
return this._Volume;
|
|
250
|
-
}
|
|
251
|
-
}, {
|
|
252
|
-
kind: "set",
|
|
253
|
-
key: "Volume",
|
|
254
|
-
value: function (value) {
|
|
255
|
-
this._setPropertyInternal('Volume', value);
|
|
256
|
-
}
|
|
257
|
-
}, {
|
|
258
|
-
kind: "get",
|
|
259
|
-
decorators: [property({
|
|
260
|
-
signature: 'x',
|
|
261
|
-
access: ACCESS_READ
|
|
262
|
-
})],
|
|
263
|
-
key: "Position",
|
|
264
|
-
value: function () {
|
|
265
|
-
let playerPosition = this.player.getPosition();
|
|
266
|
-
let position = Math.floor(playerPosition || 0);
|
|
267
|
-
if (isNaN(position)) {
|
|
268
|
-
const err = 'github.mpris_service.InvalidPositionError';
|
|
269
|
-
const message = `The player has set an invalid position: ${playerPosition}`;
|
|
270
|
-
throw new DBusError(err, message);
|
|
271
|
-
}
|
|
272
|
-
return position;
|
|
273
|
-
}
|
|
274
|
-
}, {
|
|
275
|
-
kind: "get",
|
|
276
|
-
decorators: [property({
|
|
277
|
-
signature: 's'
|
|
278
|
-
})],
|
|
279
|
-
key: "LoopStatus",
|
|
280
|
-
value: function () {
|
|
281
|
-
if (!constants.isLoopStatusValid(this._LoopStatus)) {
|
|
282
|
-
const err = 'github.mpris_service.InvalidLoopStatusError';
|
|
283
|
-
const message = `The player has set an invalid loop status: ${this._LoopStatus}`;
|
|
284
|
-
throw new DBusError(err, message);
|
|
285
|
-
}
|
|
286
|
-
return this._LoopStatus;
|
|
287
|
-
}
|
|
288
|
-
}, {
|
|
289
|
-
kind: "set",
|
|
290
|
-
key: "LoopStatus",
|
|
291
|
-
value: function (value) {
|
|
292
|
-
if (!constants.isLoopStatusValid(value)) {
|
|
293
|
-
const err = 'github.mpris_service.InvalidLoopStatusError';
|
|
294
|
-
const message = `Tried to set loop status to an invalid value: ${value}`;
|
|
295
|
-
throw new DBusError(err, message);
|
|
296
|
-
}
|
|
297
|
-
this._setPropertyInternal('LoopStatus', value);
|
|
298
|
-
}
|
|
299
|
-
}, {
|
|
300
|
-
kind: "get",
|
|
301
|
-
decorators: [property({
|
|
302
|
-
signature: 's',
|
|
303
|
-
access: ACCESS_READ
|
|
304
|
-
})],
|
|
305
|
-
key: "PlaybackStatus",
|
|
306
|
-
value: function () {
|
|
307
|
-
if (!constants.isPlaybackStatusValid(this._PlaybackStatus)) {
|
|
308
|
-
const err = 'github.mpris_service.InvalidPlaybackStatusError';
|
|
309
|
-
const message = `The player has set an invalid playback status: ${this._PlaybackStatus}`;
|
|
310
|
-
throw new DBusError(err, message);
|
|
311
|
-
}
|
|
312
|
-
return this._PlaybackStatus;
|
|
313
|
-
}
|
|
314
|
-
}, {
|
|
315
|
-
kind: "method",
|
|
316
|
-
decorators: [method({})],
|
|
317
|
-
key: "Next",
|
|
318
|
-
value: function Next() {
|
|
319
|
-
this.player.emit('next');
|
|
320
|
-
}
|
|
321
|
-
}, {
|
|
322
|
-
kind: "method",
|
|
323
|
-
decorators: [method({})],
|
|
324
|
-
key: "Previous",
|
|
325
|
-
value: function Previous() {
|
|
326
|
-
this.player.emit('previous');
|
|
327
|
-
}
|
|
328
|
-
}, {
|
|
329
|
-
kind: "method",
|
|
330
|
-
decorators: [method({})],
|
|
331
|
-
key: "Pause",
|
|
332
|
-
value: function Pause() {
|
|
333
|
-
this.player.emit('pause');
|
|
334
|
-
}
|
|
335
|
-
}, {
|
|
336
|
-
kind: "method",
|
|
337
|
-
decorators: [method({})],
|
|
338
|
-
key: "PlayPause",
|
|
339
|
-
value: function PlayPause() {
|
|
340
|
-
this.player.emit('playpause');
|
|
341
|
-
}
|
|
342
|
-
}, {
|
|
343
|
-
kind: "method",
|
|
344
|
-
decorators: [method({})],
|
|
345
|
-
key: "Stop",
|
|
346
|
-
value: function Stop() {
|
|
347
|
-
this.player.emit('stop');
|
|
348
|
-
}
|
|
349
|
-
}, {
|
|
350
|
-
kind: "method",
|
|
351
|
-
decorators: [method({})],
|
|
352
|
-
key: "Play",
|
|
353
|
-
value: function Play() {
|
|
354
|
-
this.player.emit('play');
|
|
355
|
-
}
|
|
356
|
-
}, {
|
|
357
|
-
kind: "method",
|
|
358
|
-
decorators: [method({
|
|
359
|
-
inSignature: 'x'
|
|
360
|
-
})],
|
|
361
|
-
key: "Seek",
|
|
362
|
-
value: function Seek(offset) {
|
|
363
|
-
// XXX overflow
|
|
364
|
-
offset = Number(offset);
|
|
365
|
-
this.player.emit('seek', offset);
|
|
366
|
-
}
|
|
367
|
-
}, {
|
|
368
|
-
kind: "method",
|
|
369
|
-
decorators: [method({
|
|
370
|
-
inSignature: 'ox'
|
|
371
|
-
})],
|
|
372
|
-
key: "SetPosition",
|
|
373
|
-
value: function SetPosition(trackId, position) {
|
|
374
|
-
let e = {
|
|
375
|
-
trackId: trackId,
|
|
376
|
-
// XXX overflow
|
|
377
|
-
position: Number(position)
|
|
378
|
-
};
|
|
379
|
-
this.player.emit('position', e);
|
|
380
|
-
}
|
|
381
|
-
}, {
|
|
382
|
-
kind: "method",
|
|
383
|
-
decorators: [method({
|
|
384
|
-
inSignature: 's'
|
|
385
|
-
})],
|
|
386
|
-
key: "OpenUri",
|
|
387
|
-
value: function OpenUri(uri) {
|
|
388
|
-
let e = {
|
|
389
|
-
uri
|
|
390
|
-
};
|
|
391
|
-
this.player.emit('open', e);
|
|
392
|
-
}
|
|
393
|
-
}, {
|
|
394
|
-
kind: "method",
|
|
395
|
-
decorators: [signal({
|
|
396
|
-
signature: 'x'
|
|
397
|
-
})],
|
|
398
|
-
key: "Seeked",
|
|
399
|
-
value: function Seeked(position) {
|
|
400
|
-
return position;
|
|
401
|
-
}
|
|
402
|
-
}]
|
|
403
|
-
};
|
|
404
|
-
}, MprisInterface);
|
|
405
|
-
module.exports = PlayerInterface;
|
|
406
|
-
//# sourceMappingURL=player.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"player.js","names":["dbus","require","MprisInterface","constants","property","method","signal","ACCESS_READ","interface","DBusError","PlayerInterface","_decorate","_initialize","_MprisInterface","constructor","player","F","d","kind","key","value","LOOP_STATUS_NONE","PLAYBACK_STATUS_STOPPED","decorators","signature","access","_CanControl","_CanPause","_CanPlay","_CanSeek","_CanGoNext","_CanGoPrevious","_Metadata","_MaximumRate","_MinimumRate","_Rate","_setPropertyInternal","_Shuffle","_Volume","playerPosition","getPosition","position","Math","floor","isNaN","err","message","isLoopStatusValid","_LoopStatus","isPlaybackStatusValid","_PlaybackStatus","Next","emit","Previous","Pause","PlayPause","Stop","Play","inSignature","Seek","offset","Number","SetPosition","trackId","e","OpenUri","uri","Seeked","module","exports"],"sourceRoot":"../../src/","sources":["interfaces/player.js"],"sourcesContent":["const dbus = require('@jellybrick/dbus-next');\nconst MprisInterface = require('./mpris-interface');\n\nconst constants = require('../constants');\n\nconst {\n property,\n method,\n signal,\n ACCESS_READ\n} = dbus.interface;\nconst DBusError = dbus.DBusError;\n\nclass PlayerInterface extends MprisInterface {\n constructor(player) {\n super('org.mpris.MediaPlayer2.Player', player);\n }\n\n _CanControl = true;\n _CanPause = true;\n _CanPlay = true;\n _CanSeek = true;\n _CanGoNext = true;\n _CanGoPrevious = true;\n _Metadata = {};\n _MaximumRate = 1;\n _MinimumRate = 1;\n _Rate = 1;\n _Shuffle = false;\n _Volume = 0;\n _LoopStatus = constants.LOOP_STATUS_NONE;\n _PlaybackStatus = constants.PLAYBACK_STATUS_STOPPED;\n\n @property({signature: 'b', access: ACCESS_READ})\n get CanControl() {\n return this._CanControl;\n }\n\n @property({signature: 'b', access: ACCESS_READ})\n get CanPause() {\n return this._CanPause;\n }\n\n @property({signature: 'b', access: ACCESS_READ})\n get CanPlay() {\n return this._CanPlay;\n }\n\n @property({signature: 'b', access: ACCESS_READ})\n get CanSeek() {\n return this._CanSeek;\n }\n\n @property({signature: 'b', access: ACCESS_READ})\n get CanGoNext() {\n return this._CanGoNext;\n }\n\n @property({signature: 'b', access: ACCESS_READ})\n get CanGoPrevious() {\n return this._CanGoPrevious;\n }\n\n @property({signature: 'a{sv}', access: ACCESS_READ})\n get Metadata() {\n return this._Metadata;\n }\n\n @property({signature: 'd', access: ACCESS_READ})\n get MaximumRate() {\n return this._MaximumRate;\n }\n\n @property({signature: 'd', access: ACCESS_READ})\n get MinimumRate() {\n return this._MinimumRate;\n }\n\n @property({signature: 'd'})\n get Rate() {\n return this._Rate;\n }\n set Rate(value) {\n this._setPropertyInternal('Rate', value);\n }\n\n @property({signature: 'b'})\n get Shuffle() {\n return this._Shuffle;\n }\n set Shuffle(value) {\n this._setPropertyInternal('Shuffle', value);\n }\n\n @property({signature: 'd'})\n get Volume() {\n return this._Volume;\n }\n set Volume(value) {\n this._setPropertyInternal('Volume', value);\n }\n\n @property({signature: 'x', access: ACCESS_READ})\n get Position() {\n let playerPosition = this.player.getPosition();\n let position = Math.floor(playerPosition || 0);\n if (isNaN(position)) {\n const err = 'github.mpris_service.InvalidPositionError';\n const message = `The player has set an invalid position: ${playerPosition}`;\n throw new DBusError(err, message);\n }\n return position;\n }\n\n @property({signature: 's'})\n get LoopStatus() {\n if (!constants.isLoopStatusValid(this._LoopStatus)) {\n const err = 'github.mpris_service.InvalidLoopStatusError';\n const message = `The player has set an invalid loop status: ${this._LoopStatus}`;\n throw new DBusError(err, message);\n }\n\n return this._LoopStatus;\n }\n set LoopStatus(value) {\n if (!constants.isLoopStatusValid(value)) {\n const err = 'github.mpris_service.InvalidLoopStatusError';\n const message = `Tried to set loop status to an invalid value: ${value}`;\n throw new DBusError(err, message);\n }\n this._setPropertyInternal('LoopStatus', value);\n }\n\n @property({signature: 's', access: ACCESS_READ})\n get PlaybackStatus() {\n if (!constants.isPlaybackStatusValid(this._PlaybackStatus)) {\n const err = 'github.mpris_service.InvalidPlaybackStatusError';\n const message = `The player has set an invalid playback status: ${this._PlaybackStatus}`;\n throw new DBusError(err, message);\n }\n\n return this._PlaybackStatus;\n }\n\n @method({})\n Next() {\n this.player.emit('next');\n }\n\n @method({})\n Previous() {\n this.player.emit('previous');\n }\n\n @method({})\n Pause() {\n this.player.emit('pause');\n }\n\n @method({})\n PlayPause() {\n this.player.emit('playpause');\n }\n\n @method({})\n Stop() {\n this.player.emit('stop');\n }\n\n @method({})\n Play() {\n this.player.emit('play');\n }\n\n @method({inSignature: 'x'})\n Seek(offset) {\n // XXX overflow\n offset = Number(offset);\n this.player.emit('seek', offset);\n }\n\n @method({inSignature: 'ox'})\n SetPosition(trackId, position) {\n let e = {\n trackId: trackId,\n // XXX overflow\n position: Number(position)\n };\n this.player.emit('position', e);\n }\n\n @method({inSignature: 's'})\n OpenUri(uri) {\n let e = { uri };\n this.player.emit('open', e);\n }\n\n @signal({signature: 'x'})\n Seeked(position) {\n return position;\n }\n}\n\nmodule.exports = PlayerInterface;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA,MAAMA,IAAI,GAAGC,OAAO,CAAC,uBAAuB,CAAC;AAC7C,MAAMC,cAAc,GAAGD,OAAO,CAAC,mBAAmB,CAAC;AAEnD,MAAME,SAAS,GAAGF,OAAO,CAAC,cAAc,CAAC;AAEzC,MAAM;EACJG,QAAQ;EACRC,MAAM;EACNC,MAAM;EACNC;AACF,CAAC,GAAGP,IAAI,CAACQ,SAAS;AAClB,MAAMC,SAAS,GAAGT,IAAI,CAACS,SAAS;AAAC,IAE3BC,eAAe,GAAAC,SAAA,iBAAAC,WAAA,EAAAC,eAAA;EAArB,MAAMH,eAAe,SAAAG,eAAA,CAAwB;IAC3CC,WAAWA,CAACC,MAAM,EAAE;MAClB,KAAK,CAAC,+BAA+B,EAAEA,MAAM,CAAC;MAACH,WAAA;IACjD;EAyLF;EAAC;IAAAI,CAAA,EA5LKN,eAAe;IAAAO,CAAA;MAAAC,IAAA;MAAAC,GAAA;MAAAC,MAAA;QAAA,OAKL,IAAI;MAAA;IAAA;MAAAF,IAAA;MAAAC,GAAA;MAAAC,MAAA;QAAA,OACN,IAAI;MAAA;IAAA;MAAAF,IAAA;MAAAC,GAAA;MAAAC,MAAA;QAAA,OACL,IAAI;MAAA;IAAA;MAAAF,IAAA;MAAAC,GAAA;MAAAC,MAAA;QAAA,OACJ,IAAI;MAAA;IAAA;MAAAF,IAAA;MAAAC,GAAA;MAAAC,MAAA;QAAA,OACF,IAAI;MAAA;IAAA;MAAAF,IAAA;MAAAC,GAAA;MAAAC,MAAA;QAAA,OACA,IAAI;MAAA;IAAA;MAAAF,IAAA;MAAA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QAAQ,EAAE;QACf,OAAOA,QAAQ;MACjB;IAAC;EAAA;AAAA,GA3L2BvC,cAAc;AA8L5CkE,MAAM,CAACC,OAAO,GAAG3D,eAAe","ignoreList":[]}
|
|
@@ -1,139 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
function _decorate(e, r, t, i) { var o = _getDecoratorsApi(); if (i) for (var n = 0; n < i.length; n++) o = i[n](o); var s = r(function (e) { o.initializeInstanceElements(e, a.elements); }, t), a = o.decorateClass(_coalesceClassElements(s.d.map(_createElementDescriptor)), e); return o.initializeClassElements(s.F, a.elements), o.runClassFinishers(s.F, a.finishers); }
|
|
4
|
-
function _getDecoratorsApi() { _getDecoratorsApi = function () { return e; }; var e = { elementsDefinitionOrder: [["method"], ["field"]], initializeInstanceElements: function (e, r) { ["method", "field"].forEach(function (t) { r.forEach(function (r) { r.kind === t && "own" === r.placement && this.defineClassElement(e, r); }, this); }, this); }, initializeClassElements: function (e, r) { var t = e.prototype; ["method", "field"].forEach(function (i) { r.forEach(function (r) { var o = r.placement; if (r.kind === i && ("static" === o || "prototype" === o)) { var n = "static" === o ? e : t; this.defineClassElement(n, r); } }, this); }, this); }, defineClassElement: function (e, r) { var t = r.descriptor; if ("field" === r.kind) { var i = r.initializer; t = { enumerable: t.enumerable, writable: t.writable, configurable: t.configurable, value: void 0 === i ? void 0 : i.call(e) }; } Object.defineProperty(e, r.key, t); }, decorateClass: function (e, r) { var t = [], i = [], o = { static: [], prototype: [], own: [] }; if (e.forEach(function (e) { this.addElementPlacement(e, o); }, this), e.forEach(function (e) { if (!_hasDecorators(e)) return t.push(e); var r = this.decorateElement(e, o); t.push(r.element), t.push.apply(t, r.extras), i.push.apply(i, r.finishers); }, this), !r) return { elements: t, finishers: i }; var n = this.decorateConstructor(t, r); return i.push.apply(i, n.finishers), n.finishers = i, n; }, addElementPlacement: function (e, r, t) { var i = r[e.placement]; if (!t && -1 !== i.indexOf(e.key)) throw new TypeError("Duplicated element (" + e.key + ")"); i.push(e.key); }, decorateElement: function (e, r) { for (var t = [], i = [], o = e.decorators, n = o.length - 1; n >= 0; n--) { var s = r[e.placement]; s.splice(s.indexOf(e.key), 1); var a = this.fromElementDescriptor(e), l = this.toElementFinisherExtras((0, o[n])(a) || a); e = l.element, this.addElementPlacement(e, r), l.finisher && i.push(l.finisher); var c = l.extras; if (c) { for (var p = 0; p < c.length; p++) this.addElementPlacement(c[p], r); t.push.apply(t, c); } } return { element: e, finishers: i, extras: t }; }, decorateConstructor: function (e, r) { for (var t = [], i = r.length - 1; i >= 0; i--) { var o = this.fromClassDescriptor(e), n = this.toClassDescriptor((0, r[i])(o) || o); if (void 0 !== n.finisher && t.push(n.finisher), void 0 !== n.elements) { e = n.elements; for (var s = 0; s < e.length - 1; s++) for (var a = s + 1; a < e.length; a++) if (e[s].key === e[a].key && e[s].placement === e[a].placement) throw new TypeError("Duplicated element (" + e[s].key + ")"); } } return { elements: e, finishers: t }; }, fromElementDescriptor: function (e) { var r = { kind: e.kind, key: e.key, placement: e.placement, descriptor: e.descriptor }; return Object.defineProperty(r, Symbol.toStringTag, { value: "Descriptor", configurable: !0 }), "field" === e.kind && (r.initializer = e.initializer), r; }, toElementDescriptors: function (e) { if (void 0 !== e) return _toArray(e).map(function (e) { var r = this.toElementDescriptor(e); return this.disallowProperty(e, "finisher", "An element descriptor"), this.disallowProperty(e, "extras", "An element descriptor"), r; }, this); }, toElementDescriptor: function (e) { var r = e.kind + ""; if ("method" !== r && "field" !== r) throw new TypeError('An element descriptor\'s .kind property must be either "method" or "field", but a decorator created an element descriptor with .kind "' + r + '"'); var t = _toPropertyKey(e.key), i = e.placement + ""; if ("static" !== i && "prototype" !== i && "own" !== i) throw new TypeError('An element descriptor\'s .placement property must be one of "static", "prototype" or "own", but a decorator created an element descriptor with .placement "' + i + '"'); var o = e.descriptor; this.disallowProperty(e, "elements", "An element descriptor"); var n = { kind: r, key: t, placement: i, descriptor: Object.assign({}, o) }; return "field" !== r ? this.disallowProperty(e, "initializer", "A method descriptor") : (this.disallowProperty(o, "get", "The property descriptor of a field descriptor"), this.disallowProperty(o, "set", "The property descriptor of a field descriptor"), this.disallowProperty(o, "value", "The property descriptor of a field descriptor"), n.initializer = e.initializer), n; }, toElementFinisherExtras: function (e) { return { element: this.toElementDescriptor(e), finisher: _optionalCallableProperty(e, "finisher"), extras: this.toElementDescriptors(e.extras) }; }, fromClassDescriptor: function (e) { var r = { kind: "class", elements: e.map(this.fromElementDescriptor, this) }; return Object.defineProperty(r, Symbol.toStringTag, { value: "Descriptor", configurable: !0 }), r; }, toClassDescriptor: function (e) { var r = e.kind + ""; if ("class" !== r) throw new TypeError('A class descriptor\'s .kind property must be "class", but a decorator created a class descriptor with .kind "' + r + '"'); this.disallowProperty(e, "key", "A class descriptor"), this.disallowProperty(e, "placement", "A class descriptor"), this.disallowProperty(e, "descriptor", "A class descriptor"), this.disallowProperty(e, "initializer", "A class descriptor"), this.disallowProperty(e, "extras", "A class descriptor"); var t = _optionalCallableProperty(e, "finisher"); return { elements: this.toElementDescriptors(e.elements), finisher: t }; }, runClassFinishers: function (e, r) { for (var t = 0; t < r.length; t++) { var i = (0, r[t])(e); if (void 0 !== i) { if ("function" != typeof i) throw new TypeError("Finishers must return a constructor."); e = i; } } return e; }, disallowProperty: function (e, r, t) { if (void 0 !== e[r]) throw new TypeError(t + " can't have a ." + r + " property."); } }; return e; }
|
|
5
|
-
function _createElementDescriptor(e) { var r, t = _toPropertyKey(e.key); "method" === e.kind ? r = { value: e.value, writable: !0, configurable: !0, enumerable: !1 } : "get" === e.kind ? r = { get: e.value, configurable: !0, enumerable: !1 } : "set" === e.kind ? r = { set: e.value, configurable: !0, enumerable: !1 } : "field" === e.kind && (r = { configurable: !0, writable: !0, enumerable: !0 }); var i = { kind: "field" === e.kind ? "field" : "method", key: t, placement: e.static ? "static" : "field" === e.kind ? "own" : "prototype", descriptor: r }; return e.decorators && (i.decorators = e.decorators), "field" === e.kind && (i.initializer = e.value), i; }
|
|
6
|
-
function _coalesceGetterSetter(e, r) { void 0 !== e.descriptor.get ? r.descriptor.get = e.descriptor.get : r.descriptor.set = e.descriptor.set; }
|
|
7
|
-
function _coalesceClassElements(e) { for (var r = [], isSameElement = function (e) { return "method" === e.kind && e.key === o.key && e.placement === o.placement; }, t = 0; t < e.length; t++) { var i, o = e[t]; if ("method" === o.kind && (i = r.find(isSameElement))) { if (_isDataDescriptor(o.descriptor) || _isDataDescriptor(i.descriptor)) { if (_hasDecorators(o) || _hasDecorators(i)) throw new ReferenceError("Duplicated methods (" + o.key + ") can't be decorated."); i.descriptor = o.descriptor; } else { if (_hasDecorators(o)) { if (_hasDecorators(i)) throw new ReferenceError("Decorators can't be placed on different accessors with for the same property (" + o.key + ")."); i.decorators = o.decorators; } _coalesceGetterSetter(o, i); } } else r.push(o); } return r; }
|
|
8
|
-
function _hasDecorators(e) { return e.decorators && e.decorators.length; }
|
|
9
|
-
function _isDataDescriptor(e) { return void 0 !== e && !(void 0 === e.value && void 0 === e.writable); }
|
|
10
|
-
function _optionalCallableProperty(e, r) { var t = e[r]; if (void 0 !== t && "function" != typeof t) throw new TypeError("Expected '" + r + "' to be a function"); return t; }
|
|
11
|
-
function _toPropertyKey(t) { var i = _toPrimitive(t, "string"); return "symbol" == typeof i ? i : i + ""; }
|
|
12
|
-
function _toPrimitive(t, r) { if ("object" != typeof t || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || "default"); if ("object" != typeof i) return i; throw new TypeError("@@toPrimitive must return a primitive value."); } return ("string" === r ? String : Number)(t); }
|
|
13
|
-
function _toArray(r) { return _arrayWithHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableRest(); }
|
|
14
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
15
|
-
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
|
16
|
-
function _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }
|
|
17
|
-
function _iterableToArray(r) { if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r); }
|
|
18
|
-
function _arrayWithHoles(r) { if (Array.isArray(r)) return r; }
|
|
19
|
-
// TODO proper import
|
|
20
|
-
const MprisInterface = require('./mpris-interface');
|
|
21
|
-
const dbus = require('@jellybrick/dbus-next');
|
|
22
|
-
const types = require('./types');
|
|
23
|
-
const {
|
|
24
|
-
property,
|
|
25
|
-
method,
|
|
26
|
-
signal,
|
|
27
|
-
ACCESS_READ
|
|
28
|
-
} = dbus.interface;
|
|
29
|
-
let PlaylistsInterface = _decorate(null, function (_initialize, _MprisInterface) {
|
|
30
|
-
class PlaylistsInterface extends _MprisInterface {
|
|
31
|
-
constructor(player) {
|
|
32
|
-
super('org.mpris.MediaPlayer2.Playlists', player);
|
|
33
|
-
_initialize(this);
|
|
34
|
-
}
|
|
35
|
-
}
|
|
36
|
-
return {
|
|
37
|
-
F: PlaylistsInterface,
|
|
38
|
-
d: [{
|
|
39
|
-
kind: "field",
|
|
40
|
-
key: "_ActivePlaylist",
|
|
41
|
-
value() {
|
|
42
|
-
return [false, types.emptyPlaylist];
|
|
43
|
-
}
|
|
44
|
-
}, {
|
|
45
|
-
kind: "field",
|
|
46
|
-
key: "_PlaylistCount",
|
|
47
|
-
value() {
|
|
48
|
-
return 0;
|
|
49
|
-
}
|
|
50
|
-
}, {
|
|
51
|
-
kind: "get",
|
|
52
|
-
decorators: [property({
|
|
53
|
-
signature: 'u',
|
|
54
|
-
access: ACCESS_READ
|
|
55
|
-
})],
|
|
56
|
-
key: "PlaylistCount",
|
|
57
|
-
value: function () {
|
|
58
|
-
return this._PlaylistCount;
|
|
59
|
-
}
|
|
60
|
-
}, {
|
|
61
|
-
kind: "get",
|
|
62
|
-
decorators: [property({
|
|
63
|
-
signature: 'as',
|
|
64
|
-
access: ACCESS_READ
|
|
65
|
-
})],
|
|
66
|
-
key: "Orderings",
|
|
67
|
-
value: function () {
|
|
68
|
-
return ['Alphabetical', 'UserDefined'];
|
|
69
|
-
}
|
|
70
|
-
}, {
|
|
71
|
-
kind: "get",
|
|
72
|
-
decorators: [property({
|
|
73
|
-
signature: '(b(oss))',
|
|
74
|
-
access: ACCESS_READ
|
|
75
|
-
})],
|
|
76
|
-
key: "ActivePlaylist",
|
|
77
|
-
value: function () {
|
|
78
|
-
return this._ActivePlaylist;
|
|
79
|
-
}
|
|
80
|
-
}, {
|
|
81
|
-
kind: "method",
|
|
82
|
-
key: "setActivePlaylistId",
|
|
83
|
-
value: function setActivePlaylistId(playlistId) {
|
|
84
|
-
let i = this.player.getPlaylistIndex(playlistId);
|
|
85
|
-
this.setProperty('ActivePlaylist', this.player.playlists[i] || null);
|
|
86
|
-
}
|
|
87
|
-
}, {
|
|
88
|
-
kind: "method",
|
|
89
|
-
decorators: [method({
|
|
90
|
-
inSignature: 'o'
|
|
91
|
-
})],
|
|
92
|
-
key: "ActivatePlaylist",
|
|
93
|
-
value: function ActivatePlaylist(playlistId) {
|
|
94
|
-
this.player.emit('activatePlaylist', playlistId);
|
|
95
|
-
}
|
|
96
|
-
}, {
|
|
97
|
-
kind: "method",
|
|
98
|
-
decorators: [method({
|
|
99
|
-
inSignature: 'uusb',
|
|
100
|
-
outSignature: 'a(oss)'
|
|
101
|
-
})],
|
|
102
|
-
key: "GetPlaylists",
|
|
103
|
-
value: function GetPlaylists(index, maxCount, order, reverseOrder) {
|
|
104
|
-
if (!this.player.playlists) {
|
|
105
|
-
return [];
|
|
106
|
-
}
|
|
107
|
-
let result = this.player.playlists.sort(function (a, b) {
|
|
108
|
-
let ret = 1;
|
|
109
|
-
switch (order) {
|
|
110
|
-
case 'Alphabetical':
|
|
111
|
-
ret = a.Name > b.Name ? 1 : -1;
|
|
112
|
-
break;
|
|
113
|
-
//case 'CreationDate':
|
|
114
|
-
//case 'ModifiedDate':
|
|
115
|
-
//case 'LastPlayDate':
|
|
116
|
-
case 'UserDefined':
|
|
117
|
-
break;
|
|
118
|
-
}
|
|
119
|
-
return ret;
|
|
120
|
-
}).slice(index, maxCount + index).map(types.playlistToDbus);
|
|
121
|
-
if (reverseOrder) {
|
|
122
|
-
result.reverse();
|
|
123
|
-
}
|
|
124
|
-
return result;
|
|
125
|
-
}
|
|
126
|
-
}, {
|
|
127
|
-
kind: "method",
|
|
128
|
-
decorators: [signal({
|
|
129
|
-
signature: '(oss)'
|
|
130
|
-
})],
|
|
131
|
-
key: "PlaylistChanged",
|
|
132
|
-
value: function PlaylistChanged(playlist) {
|
|
133
|
-
return types.playlistToDbus(playlist);
|
|
134
|
-
}
|
|
135
|
-
}]
|
|
136
|
-
};
|
|
137
|
-
}, MprisInterface);
|
|
138
|
-
module.exports = PlaylistsInterface;
|
|
139
|
-
//# sourceMappingURL=playlists.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"playlists.js","names":["MprisInterface","require","dbus","types","property","method","signal","ACCESS_READ","interface","PlaylistsInterface","_decorate","_initialize","_MprisInterface","constructor","player","F","d","kind","key","value","emptyPlaylist","decorators","signature","access","_PlaylistCount","_ActivePlaylist","setActivePlaylistId","playlistId","i","getPlaylistIndex","setProperty","playlists","inSignature","ActivatePlaylist","emit","outSignature","GetPlaylists","index","maxCount","order","reverseOrder","result","sort","a","b","ret","Name","slice","map","playlistToDbus","reverse","PlaylistChanged","playlist","module","exports"],"sourceRoot":"../../src/","sources":["interfaces/playlists.js"],"sourcesContent":["// TODO proper import\nconst MprisInterface = require('./mpris-interface');\nconst dbus = require('@jellybrick/dbus-next');\n\nconst types = require('./types');\n\nconst {\n property,\n method,\n signal,\n ACCESS_READ\n} = dbus.interface;\n\nclass PlaylistsInterface extends MprisInterface {\n constructor(player) {\n super('org.mpris.MediaPlayer2.Playlists', player);\n }\n\n _ActivePlaylist = [ false, types.emptyPlaylist ];\n _PlaylistCount = 0;\n\n @property({signature: 'u', access: ACCESS_READ})\n get PlaylistCount() {\n return this._PlaylistCount;\n }\n\n @property({signature: 'as', access: ACCESS_READ})\n get Orderings() {\n return ['Alphabetical', 'UserDefined'];\n }\n\n @property({signature: '(b(oss))', access: ACCESS_READ})\n get ActivePlaylist() {\n return this._ActivePlaylist;\n }\n\n setActivePlaylistId(playlistId) {\n let i = this.player.getPlaylistIndex(playlistId);\n\n this.setProperty('ActivePlaylist', this.player.playlists[i] || null);\n }\n\n @method({inSignature: 'o'})\n ActivatePlaylist(playlistId) {\n this.player.emit('activatePlaylist', playlistId);\n }\n\n @method({inSignature: 'uusb', outSignature: 'a(oss)'})\n GetPlaylists(index, maxCount, order, reverseOrder) {\n if (!this.player.playlists) {\n return [];\n }\n\n let result = this.player.playlists.sort(function(a, b) {\n let ret = 1;\n switch (order) {\n case 'Alphabetical':\n ret = (a.Name > b.Name) ? 1 : -1;\n break;\n //case 'CreationDate':\n //case 'ModifiedDate':\n //case 'LastPlayDate':\n case 'UserDefined':\n break;\n }\n return ret;\n })\n .slice(index, maxCount + index)\n .map(types.playlistToDbus);\n\n if (reverseOrder) {\n result.reverse();\n }\n\n return result;\n }\n\n @signal({signature: '(oss)'})\n PlaylistChanged(playlist) {\n return types.playlistToDbus(playlist);\n }\n}\n\nmodule.exports = PlaylistsInterface;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AACA,MAAMA,cAAc,GAAGC,OAAO,CAAC,mBAAmB,CAAC;AACnD,MAAMC,IAAI,GAAGD,OAAO,CAAC,uBAAuB,CAAC;AAE7C,MAAME,KAAK,GAAGF,OAAO,CAAC,SAAS,CAAC;AAEhC,MAAM;EACJG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