Save and load windows using localStorage