0
\$\begingroup\$
Dialog dialog = new Dialog("Warning", skin, "dialog") {
    public void result(Object obj) {
        System.out.println("result "+obj);
        if(obj == true) {
            >> abort the dialog closing ? <<
        }
    }
};
dialog.text("Info?");
dialog.button("Yes", true);
dialog.button("No", false);
dialog.key(Keys.Enter, true);
dialog.show();

how to abort the closing of the dialog?

\$\endgroup\$
2
\$\begingroup\$

The documentation notes that when the result method is called, the dialog will be hidden unless cancel() is called.

So you'll want to invoke dialog.cancel() within your result callback somewhere.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.