mirror of
https://github.com/2009scape/2009Scape-mobile.git
synced 2025-12-12 01:21:09 -07:00
Set solid color background drawable with TextureView
This commit is contained in:
parent
2041834e6f
commit
b81c7c4303
1 changed files with 4 additions and 2 deletions
|
|
@ -14,6 +14,8 @@ import android.app.*;
|
|||
import android.content.*;
|
||||
import android.content.pm.PackageManager;
|
||||
import android.content.res.Configuration;
|
||||
import android.graphics.Color;
|
||||
import android.graphics.drawable.ColorDrawable;
|
||||
import android.os.*;
|
||||
import android.util.*;
|
||||
import android.view.*;
|
||||
|
|
@ -85,8 +87,8 @@ public class MainActivity extends BaseActivity {
|
|||
CallbackBridge.addGrabListener(minecraftGLView);
|
||||
|
||||
// Enabling this on TextureView results in a broken white result
|
||||
if(PREF_USE_ALTERNATE_SURFACE)
|
||||
getWindow().setBackgroundDrawable(null);
|
||||
if(PREF_USE_ALTERNATE_SURFACE) getWindow().setBackgroundDrawable(null);
|
||||
else getWindow().setBackgroundDrawable(new ColorDrawable(Color.BLACK));
|
||||
|
||||
// Set the sustained performance mode for available APIs
|
||||
if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.N)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue