static Runnable buttonActionWithCloseablePre(Runnable r, IF1 pre) { ret -> { JButton button = heldInstance(JButton); var closeable = pre?.get(button); thread { pcallF(r); close(closeable); } }; }