Moved window creation out of context creation in it's own class.