Don't redraw popups unnecessarily (patch from Aleksandr Samusenko).