fixed styling issues; returning early in pauseActiveTorrents.
This commit is contained in:
@@ -88,13 +88,13 @@ module.exports = class PlaybackController {
|
|||||||
|
|
||||||
pauseActiveTorrents (infoHash) {
|
pauseActiveTorrents (infoHash) {
|
||||||
// Playback Priority: pause all active torrents if needed.
|
// Playback Priority: pause all active torrents if needed.
|
||||||
if (this.state.saved.prefs.highestPlaybackPriority) {
|
if (!this.state.saved.prefs.highestPlaybackPriority) return
|
||||||
// Do not pause active torrents if playing a fully downloaded torrent.
|
|
||||||
var torrentSummary = TorrentSummary.getByKey(this.state, infoHash)
|
|
||||||
if (torrentSummary.status === 'seeding') return
|
|
||||||
|
|
||||||
dispatch('prioritizeTorrent', infoHash)
|
// Do not pause active torrents if playing a fully downloaded torrent.
|
||||||
}
|
const torrentSummary = TorrentSummary.getByKey(this.state, infoHash)
|
||||||
|
if (torrentSummary.status === 'seeding') return
|
||||||
|
|
||||||
|
dispatch('prioritizeTorrent', infoHash)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Play next file in list (if any)
|
// Play next file in list (if any)
|
||||||
|
|||||||
@@ -122,7 +122,7 @@ module.exports = class TorrentListController {
|
|||||||
this.startTorrentingSummary(torrentSummary.torrentKey)
|
this.startTorrentingSummary(torrentSummary.torrentKey)
|
||||||
sound.play('ENABLE')
|
sound.play('ENABLE')
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
this.pauseTorrent(torrentSummary, true)
|
this.pauseTorrent(torrentSummary, true)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ class PreferencesPage extends React.Component {
|
|||||||
className='control'
|
className='control'
|
||||||
checked={this.props.state.unsaved.prefs.highestPlaybackPriority}
|
checked={this.props.state.unsaved.prefs.highestPlaybackPriority}
|
||||||
label={'Highest Playback Priority'}
|
label={'Highest Playback Priority'}
|
||||||
onCheck={this.handleHighestPlaybackPriorityChange}
|
onCheck={this.handleHighestPlaybackPriorityChange}
|
||||||
/>
|
/>
|
||||||
<p>Pauses all active torrents to allow playback to use all of the available bandwidth.</p>
|
<p>Pauses all active torrents to allow playback to use all of the available bandwidth.</p>
|
||||||
</Preference>
|
</Preference>
|
||||||
|
|||||||
Reference in New Issue
Block a user