added functionality for checking and unchecking all