mirror of
https://github.com/moparisthebest/open-keychain
synced 2024-11-23 17:22:16 -05:00
Adding a min date not to go below creation date
This commit is contained in:
parent
a1230bbe53
commit
7a95784074
@ -106,7 +106,8 @@ public class KeyEditor extends LinearLayout implements Editor, OnClickListener {
|
||||
mDeleteButton.setOnClickListener(this);
|
||||
|
||||
setExpiryDate(null);
|
||||
|
||||
String creationDate = mCreationDate.getText().toString();
|
||||
Date date = DateFormat.getDateInstance().parse(creationDate);
|
||||
mExpiryDateButton.setOnClickListener(new OnClickListener() {
|
||||
public void onClick(View v) {
|
||||
GregorianCalendar date = mExpiryDate;
|
||||
@ -129,6 +130,7 @@ public class KeyEditor extends LinearLayout implements Editor, OnClickListener {
|
||||
}
|
||||
}
|
||||
});
|
||||
dialog.getDatePicker().setMinDate(date.getTime());
|
||||
dialog.show();
|
||||
}
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user