Fixing inconsistent method prototype and implementation of -sharedWindow in