mirror of
https://github.com/github/codeql.git
synced 2025-12-24 20:56:33 +01:00
19 lines
381 B
Java
19 lines
381 B
Java
public class Dialog
|
|
{
|
|
// ...
|
|
|
|
private void validate() {
|
|
// TODO: check that this covers all cases
|
|
if ((id != null && id.length() == 0) ||
|
|
((partner == null || partner.id == -1) &&
|
|
((option == Options.SHORT && parameter.length() == 0) ||
|
|
(option == Options.LONG && parameter.length() < 8))))
|
|
{
|
|
disableOKButton();
|
|
} else {
|
|
enableOKButton();
|
|
}
|
|
}
|
|
|
|
// ...
|
|
} |