Fix buffer remake cache behavior
Fix close preview window problem