setBlackOrWhite refactor