mirror of
https://github.com/AngelAuraMC/Amethyst-Android.git
synced 2025-09-15 15:48:26 -04:00
- Restored delete account Dialog
This commit is contained in:
parent
74633d3aa0
commit
2bc8dc0218
@ -727,10 +727,21 @@ public class PojavLoginActivity extends BaseActivity
|
|||||||
final String selectedAccName = accountName.getText().toString();
|
final String selectedAccName = accountName.getText().toString();
|
||||||
@Override
|
@Override
|
||||||
public void onClick(View v) {
|
public void onClick(View v) {
|
||||||
new InvalidateTokenTask(PojavLoginActivity.this).execute(selectedAccName);
|
AlertDialog.Builder builder2 = new AlertDialog.Builder(PojavLoginActivity.this);
|
||||||
accountListLayout.removeViewsInLayout(0,1);
|
builder2.setTitle(selectedAccName);
|
||||||
//Resize the window
|
builder2.setMessage(R.string.warning_remove_account);
|
||||||
accountDialog.getWindow().setLayout((int)(xScreen*0.4),(int)Math.min((yScreen*0.8), 200 + accountListLayout.getChildCount()*150));
|
builder2.setPositiveButton(android.R.string.ok, new DialogInterface.OnClickListener(){
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onClick(DialogInterface p1, int p2) {
|
||||||
|
new InvalidateTokenTask(PojavLoginActivity.this).execute(selectedAccName);
|
||||||
|
accountListLayout.removeViewsInLayout(0,1);
|
||||||
|
//Resize the window
|
||||||
|
accountDialog.getWindow().setLayout((int)(xScreen*0.4),(int)Math.min((yScreen*0.8), 200 + accountListLayout.getChildCount()*150));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
builder2.setNegativeButton(android.R.string.cancel, null);
|
||||||
|
builder2.show();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user