Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #11317 from t895/dialog-adjustment
Android: Use progress indicator in short loading scenarios
  • Loading branch information
lioncash committed Dec 4, 2022
2 parents 2aa25c0 + 6a95c56 commit 51dfab6
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 6 deletions.
Expand Up @@ -208,7 +208,8 @@ public Settings loadGameSpecificSettings()
public void downloadGeckoCodes()
{
AlertDialog progressDialog = new MaterialAlertDialogBuilder(this)
.setMessage(R.string.cheats_downloading)
.setTitle(R.string.cheats_downloading)
.setView(R.layout.dialog_indeterminate_progress)
.setCancelable(false)
.show();

Expand Down
Expand Up @@ -240,8 +240,7 @@ public void showLoading()
{
dialog = new MaterialAlertDialogBuilder(this)
.setTitle(getString(R.string.load_settings))
.setView(getLayoutInflater().inflate(R.layout.dialog_indeterminate_progress, null,
false))
.setView(R.layout.dialog_indeterminate_progress)
.create();
}
dialog.show();
Expand Down
Expand Up @@ -31,6 +31,7 @@ public static void runOnThreadAndShowResult(Activity activity, int progressTitle
Resources resources = activity.getResources();
AlertDialog progressDialog = new MaterialAlertDialogBuilder(activity)
.setTitle(progressTitle)
.setView(R.layout.dialog_indeterminate_progress)
.setCancelable(false)
.create();

Expand Down
Expand Up @@ -4,11 +4,11 @@
android:layout_width="match_parent"
android:layout_height="match_parent">

<com.google.android.material.progressindicator.CircularProgressIndicator
android:layout_width="wrap_content"
<com.google.android.material.progressindicator.LinearProgressIndicator
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_margin="16dp"
android:layout_margin="24dp"
android:indeterminate="true"
app:trackCornerRadius="2dp" />

Expand Down

0 comments on commit 51dfab6

Please sign in to comment.