disable absolute locktime if sequence disabled

This commit is contained in:
Craig Raw 2020-08-20 17:40:56 +02:00
parent 03c488cf4d
commit f723d20c9a

View file

@ -313,12 +313,13 @@ public class HeadersController extends TransactionFormController implements Init
} }
}); });
locktimeNoneType.setDisable(!headersForm.isEditable()); boolean locktimeEnabled = headersForm.getTransaction().isLocktimeSequenceEnabled();
locktimeBlockType.setDisable(!headersForm.isEditable()); locktimeNoneType.setDisable(!headersForm.isEditable() || !locktimeEnabled);
locktimeDateType.setDisable(!headersForm.isEditable()); locktimeBlockType.setDisable(!headersForm.isEditable() || !locktimeEnabled);
locktimeBlock.setDisable(!headersForm.isEditable()); locktimeDateType.setDisable(!headersForm.isEditable() || !locktimeEnabled);
locktimeDate.setDisable(!headersForm.isEditable()); locktimeBlock.setDisable(!headersForm.isEditable() || !locktimeEnabled);
locktimeCurrentHeight.setDisable(!headersForm.isEditable()); locktimeDate.setDisable(!headersForm.isEditable() || !locktimeEnabled);
locktimeCurrentHeight.setDisable(!headersForm.isEditable() || !locktimeEnabled);
updateSize(); updateSize();