toggle button uses thread now