mirror of
https://github.com/MaintainTeam/LastPipeBender.git
synced 2025-03-01 05:48:22 +03:00
Fix loading StreamInfo twice on first VideoDetailFragment opening
This commit is contained in:
parent
83f8141fe7
commit
ffe26d882b
1 changed files with 5 additions and 1 deletions
|
@ -452,8 +452,12 @@ public final class NavigationHelper {
|
||||||
if (fragment instanceof VideoDetailFragment && fragment.isVisible()) {
|
if (fragment instanceof VideoDetailFragment && fragment.isVisible()) {
|
||||||
onVideoDetailFragmentReady.run((VideoDetailFragment) fragment);
|
onVideoDetailFragmentReady.run((VideoDetailFragment) fragment);
|
||||||
} else {
|
} else {
|
||||||
|
// Specify no videoUrl here, otherwise the VideoDetailFragment will start loading the
|
||||||
|
// video automatically if it's the first time it is being opened, but then
|
||||||
|
// onVideoDetailFragmentReady will kick in and start another loading process.
|
||||||
|
// See VideoDetailFragment.wasCleared() and its usage in doInitialLoadLogic().
|
||||||
final VideoDetailFragment instance = VideoDetailFragment
|
final VideoDetailFragment instance = VideoDetailFragment
|
||||||
.getInstance(serviceId, url, title, playQueue);
|
.getInstance(serviceId, null, title, playQueue);
|
||||||
instance.setAutoPlay(autoPlay);
|
instance.setAutoPlay(autoPlay);
|
||||||
|
|
||||||
defaultTransaction(fragmentManager)
|
defaultTransaction(fragmentManager)
|
||||||
|
|
Loading…
Add table
Reference in a new issue