fix changing predicates, some fixes in button handler