implementing gallery changes