Skip to content

Commit

Permalink
some fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Ishan09811 authored Feb 12, 2024
1 parent 4d0a38e commit c9ef70e
Showing 1 changed file with 11 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -58,12 +58,20 @@ protected void finalize() throws Throwable {
}

private void showLoadingDialog() {
Handler mainHandler = new Handler(context.getMainLooper());

Runnable runnable = new Runnable() {
@Override
public void run() {
AlertDialog.Builder builder = new AlertDialog.Builder(context);
builder.setTitle("Loading Game")
.setCancelable(false)
.setView(R.layout.progress_dialog);
alertDialog = builder.create();
alertDialog.show();
}
};
mainHandler.post(runnable);
}

private void hideLoadingDialog() {
Expand Down Expand Up @@ -108,15 +116,8 @@ public void onSurfaceCreated(GL10 unused, EGLConfig config) {
AlberDriver.Initialize();
AlberDriver.setShaderJitEnabled(GlobalConfig.get(GlobalConfig.KEY_SHADER_JIT));

Handler mainHandler = new Handler(context.getMainLooper());

Runnable runnable = new Runnable() {
@Override
public void run() {
showLoadingDialog();
}
};
mainHandler.post(runnable);
showLoadingDialog();


new Handler().postDelayed(new Runnable() {
@Override
Expand Down Expand Up @@ -147,7 +148,7 @@ public void run() {
hideLoadingDialog();
}
}
}, 3000);
}, 10000);

// Load the SMDH
byte[] smdhData = AlberDriver.GetSmdh();
Expand Down

0 comments on commit c9ef70e

Please sign in to comment.