mirror of
https://github.com/jellyfin/jellyfin-web.git
synced 2024-11-20 04:18:19 -07:00
Switch wrong condition for the new previous track behaviour and fix lint
This commit is contained in:
parent
f9119cc2f6
commit
5a87754c2a
@ -159,7 +159,7 @@ define(['require', 'datetime', 'itemHelper', 'events', 'browser', 'imageLoader',
|
|||||||
|
|
||||||
elem.querySelector('.previousTrackButton').addEventListener('click', function (e) {
|
elem.querySelector('.previousTrackButton').addEventListener('click', function (e) {
|
||||||
if (currentPlayer) {
|
if (currentPlayer) {
|
||||||
if (currentPlayer.id === 'htmlaudioplayer' && (currentPlayer._currentTime <= 5 || !playbackManager.previousTrack(currentPlayer))) {
|
if (currentPlayer.id === 'htmlaudioplayer' && (currentPlayer._currentTime >= 5 || !playbackManager.previousTrack(currentPlayer))) {
|
||||||
// Cancel this event if doubleclick is fired
|
// Cancel this event if doubleclick is fired
|
||||||
if (e.detail > 1 && playbackManager.previousTrack(currentPlayer)) {
|
if (e.detail > 1 && playbackManager.previousTrack(currentPlayer)) {
|
||||||
return;
|
return;
|
||||||
|
@ -364,6 +364,7 @@
|
|||||||
padding-left: 7.3%;
|
padding-left: 7.3%;
|
||||||
padding-right: 7.3%;
|
padding-right: 7.3%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.playlistSectionButtonTransparent {
|
.playlistSectionButtonTransparent {
|
||||||
background: rgba(0, 0, 0, 0) !important;
|
background: rgba(0, 0, 0, 0) !important;
|
||||||
}
|
}
|
||||||
|
@ -705,7 +705,7 @@ define(['browser', 'datetime', 'backdrop', 'libraryBrowser', 'listView', 'imageL
|
|||||||
|
|
||||||
context.querySelector('.btnPreviousTrack').addEventListener('click', function (e) {
|
context.querySelector('.btnPreviousTrack').addEventListener('click', function (e) {
|
||||||
if (currentPlayer) {
|
if (currentPlayer) {
|
||||||
if (currentPlayer.id === 'htmlaudioplayer' && (currentPlayer._currentTime <= 5 || !playbackManager.previousTrack(currentPlayer))) {
|
if (currentPlayer.id === 'htmlaudioplayer' && (currentPlayer._currentTime >= 5 || !playbackManager.previousTrack(currentPlayer))) {
|
||||||
// Cancel this event if doubleclick is fired
|
// Cancel this event if doubleclick is fired
|
||||||
if (e.detail > 1 && playbackManager.previousTrack(currentPlayer)) {
|
if (e.detail > 1 && playbackManager.previousTrack(currentPlayer)) {
|
||||||
return;
|
return;
|
||||||
|
Loading…
Reference in New Issue
Block a user