From d551c87276f3c211b3caf2ae6543ed83a1986587 Mon Sep 17 00:00:00 2001 From: kairusds <32636532+kairusds@users.noreply.github.com> Date: Thu, 17 Oct 2024 09:02:30 +0800 Subject: [PATCH] --- .../github/kairusds/libvlcandroidtest/MainActivity.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/src/main/java/github/kairusds/libvlcandroidtest/MainActivity.java b/app/src/main/java/github/kairusds/libvlcandroidtest/MainActivity.java index 19bfcf9..5dd0dab 100644 --- a/app/src/main/java/github/kairusds/libvlcandroidtest/MainActivity.java +++ b/app/src/main/java/github/kairusds/libvlcandroidtest/MainActivity.java @@ -40,7 +40,7 @@ public class MainActivity extends AppCompatActivity { private static final int FILE_ACCESS_REQUEST = 1; private final Handler handler = new Handler(Looper.getMainLooper()); - private final ExecutorService executor; + private ExecutorService executor; private VLCVideoLayout videoLayout = null; @@ -220,8 +220,8 @@ private void showFilePickerDialog(File dir){ return; } - ArrayAdapter adapter = new ArrayAdapter<>(getContext(), android.R.layout.select_dialog_item, fileList); - AlertDialog.Builder builder = new AlertDialog.Builder(getContext()); + ArrayAdapter adapter = new ArrayAdapter<>(MainActivty.this, android.R.layout.select_dialog_item, fileList); + AlertDialog.Builder builder = new AlertDialog.Builder(MainActivty.this); builder.setTitle("Choose a file or directory"); builder.setAdapter(adapter, (dialog, which) -> { if(which == 0){