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){