final version--checks for win, integrates with reset button in layout file