changed interface of controller, added possibility of working with subfolders