Hack to for now work around dpy == null crashing CppunitTest_chart2_*

...since 2fc4f5cd750cc3899ffc6b2f831edcb01e7773b4 "Register OpenGL windows to
ScGridWindow upon file load."  Should be revisited and fixed properly.

Change-Id: I5a3d08cb750fd9ec7c98d5b85250eaabd1c7a8b2