Allow overriding CC, CXX, CFLAGS, CXXFLAGS from environment variables.
Add event mask manipulation to Window.