refactor toolbar