rough implementation of slide management (not really functional yet)