Implements 2-way binding for checkboxes