playlist fix, retina art size
This commit is contained in:
parent
c04b8f633b
commit
bbdeb4d638
3 changed files with 16 additions and 10 deletions
13
app/cyp.js
13
app/cyp.js
|
@ -816,7 +816,7 @@ class Menu extends Component {
|
|||
|
||||
customElements.define("cyp-menu", Menu);
|
||||
|
||||
const artSize = 96;
|
||||
const artSize = 96 * (window.devicePixelRatio || 1);
|
||||
const ytPath = "_youtube";
|
||||
let ytLimit = 3;
|
||||
|
||||
|
@ -1240,12 +1240,15 @@ class Queue extends Component {
|
|||
if (name === null) { return; }
|
||||
|
||||
name = escape(name);
|
||||
const commands = items.map(item => {
|
||||
return `playlistadd "${escape(name)}" "${escape(item.file)}"`;
|
||||
});
|
||||
commands.unshift(`rm "${escape(name)}"`);
|
||||
try { // might not exist
|
||||
await this._mpd.command(`rm "${name}"`);
|
||||
} catch (e) {}
|
||||
|
||||
const commands = items.map(item => {
|
||||
return `playlistadd "${name}" "${escape(item.file)}"`;
|
||||
});
|
||||
await this._mpd.command(commands);
|
||||
|
||||
sel.clear();
|
||||
}, {label:"Save", icon:"content-save"});
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
export const artSize = 96;
|
||||
export const artSize = 96 * (window.devicePixelRatio || 1);
|
||||
export const ytPath = "_youtube";
|
||||
export let ytLimit = 3;
|
||||
|
||||
|
|
|
@ -96,12 +96,15 @@ class Queue extends Component {
|
|||
if (name === null) { return; }
|
||||
|
||||
name = escape(name);
|
||||
const commands = items.map(item => {
|
||||
return `playlistadd "${escape(name)}" "${escape(item.file)}"`;
|
||||
});
|
||||
commands.unshift(`rm "${escape(name)}"`);
|
||||
try { // might not exist
|
||||
await this._mpd.command(`rm "${name}"`);
|
||||
} catch (e) {}
|
||||
|
||||
const commands = items.map(item => {
|
||||
return `playlistadd "${name}" "${escape(item.file)}"`;
|
||||
});
|
||||
await this._mpd.command(commands);
|
||||
|
||||
sel.clear();
|
||||
}, {label:"Save", icon:"content-save"});
|
||||
|
||||
|
|
Loading…
Reference in a new issue