Make percent_cb independant of class