Gallery functional.