fixed refresh functionality, including forced buffer refresh