Changed button order in app details dialog.
Most Android applications have the cancel button on the right, but this dialog had it on the left (Cancel/Install). It was especially confusing as pressing "Install" immediately leads to a system dialog with Install/Cancel buttons (i.e. in the opposite order).
This commit is contained in:
parent
b4ea49744a
commit
47a3db7767
@ -307,15 +307,8 @@ public class AppDetails extends ListActivity {
|
|||||||
}
|
}
|
||||||
p.setMessage(getString(R.string.isinst) + " " + installed);
|
p.setMessage(getString(R.string.isinst) + " " + installed);
|
||||||
|
|
||||||
p.setButton(getString(R.string.cancel),
|
|
||||||
new DialogInterface.OnClickListener() {
|
|
||||||
public void onClick(DialogInterface dialog, int which) {
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
if (caninstall) {
|
if (caninstall) {
|
||||||
p.setButton2(getString(R.string.install),
|
p.setButton(getString(R.string.install),
|
||||||
new DialogInterface.OnClickListener() {
|
new DialogInterface.OnClickListener() {
|
||||||
public void onClick(DialogInterface dialog, int which) {
|
public void onClick(DialogInterface dialog, int which) {
|
||||||
p.dismiss();
|
p.dismiss();
|
||||||
@ -323,7 +316,7 @@ public class AppDetails extends ListActivity {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
p.setButton2(getString(R.string.uninstall),
|
p.setButton(getString(R.string.uninstall),
|
||||||
new DialogInterface.OnClickListener() {
|
new DialogInterface.OnClickListener() {
|
||||||
public void onClick(DialogInterface dialog, int which) {
|
public void onClick(DialogInterface dialog, int which) {
|
||||||
p.dismiss();
|
p.dismiss();
|
||||||
@ -332,6 +325,13 @@ public class AppDetails extends ListActivity {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
p.setButton2(getString(R.string.cancel),
|
||||||
|
new DialogInterface.OnClickListener() {
|
||||||
|
public void onClick(DialogInterface dialog, int which) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
p.show();
|
p.show();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user