Move nWorkspacesChanged above call