Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 0 additions & 7 deletions app/src/main/java/org/schabi/newpipe/player/BasePlayer.java
Original file line number Diff line number Diff line change
Expand Up @@ -225,13 +225,6 @@ public void onReceive(final Context ctx, final Intent intent) {
this.renderFactory = new DefaultRenderersFactory(context);
}

public void setup() {
if (simpleExoPlayer == null) {
initPlayer(true);
}
initListeners();
}

public void initPlayer(final boolean playOnReady) {
if (DEBUG) {
Log.d(TAG, "initPlayer() called with: playOnReady = [" + playOnReady + "]");
Expand Down
7 changes: 4 additions & 3 deletions app/src/main/java/org/schabi/newpipe/player/MainPlayer.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,15 +26,16 @@
import android.os.IBinder;
import android.util.DisplayMetrics;
import android.util.Log;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.view.WindowManager;

import androidx.annotation.Nullable;
import androidx.core.content.ContextCompat;

import org.schabi.newpipe.databinding.PlayerBinding;
import org.schabi.newpipe.App;
import org.schabi.newpipe.R;
import org.schabi.newpipe.util.ThemeHelper;

import static org.schabi.newpipe.util.Localization.assureCorrectAppLanguage;
Expand Down Expand Up @@ -102,10 +103,10 @@ public void onCreate() {
}

private void createView() {
final View layout = View.inflate(this, R.layout.player, null);
final PlayerBinding binding = PlayerBinding.inflate(LayoutInflater.from(this));

playerImpl = new VideoPlayerImpl(this);
playerImpl.setup(layout);
playerImpl.setup(binding);
playerImpl.shouldUpdateOnProgress = true;

NotificationUtil.getInstance().createNotificationAndStartForeground(playerImpl, this);
Expand Down
Loading