Added more functionality to window example. Useful for testing on each platform.