hook up gallery GUI to backend