Fixed state leaking from IECoreGL::ImmediateRendererImplementation.

This was leaking the viewport state, which interfered with the running of the test cases - some tests could fail if and only if they were run after the ImmediateRenderer test.
Fixed IECoreGL::PointsPrimitive selection.

Previously selection would fail when in Selector::IDRender mode, as demonstrated by the failure of Selection.testPointsPrimitiveSelect(). When in IDRender mode, the Selector installs a special ID shader in the state, and relies on using the override mode to ensure that the shader isn't replaced by others lower down in the hierarchy of the scene. However, the PointsPrimitive replaces the shader so that it can use its own vertex shader to perform the instancing necessary to render as disks and quads, causing the failure. Shader::Setup::ScopedBinding now registers all bound shaders with the current Selector wherever necessary, fixing the problem.
Fixed potential bug in IECoreGL::Selector::loadIDShader().

As documented in the deleted comment, it was possible for a shader to die and be replaced with another with the same GL ID. Now the Selector keeps a reference to the shader to prevent that happening.
Merge pull request #71 from johnhaddon/pointsPrimitiveSelection

Points primitive selection fix