check window reference