gallery button swap working