Clean up the gradient cache in the right context
Clean up the gradient cache in the right context

QGLGradientCache for the OpenGL1 paint engine has to destroy
the cached gradient textures if the QGLContext changes.
Problem is, it wasn't changing back to the previous context
to destroy those textures.

Task-number: 249919
Reviewed-by: Sarah Smith

pruiz/wkhtmltopdf-qt,pruiz/wkhtmltopdf-qt,radekp/qt,pruiz/wkhtmltopdf-qt,radekp/qt,pruiz/wkhtmltopdf-qt,igor-sfdc/qt-wk,igor-sfdc/qt-wk,radekp/qt,radekp/qt,pruiz/wkhtmltopdf-qt,radekp/qt,igor-sfdc/qt-wk,igor-sfdc/qt-wk,igor-sfdc/qt-wk,radekp/qt,pruiz/wkhtmltopdf-qt,radekp/qt,radekp/qt,pruiz/wkhtmltopdf-qt,igor-sfdc/qt-wk,igor-sfdc/qt-wk,pruiz/wkhtmltopdf-qt,pruiz/wkhtmltopdf-qt,radekp/qt,igor-sfdc/qt-wk,igor-sfdc/qt-wk,igor-sfdc/qt-wk,radekp/qt,pruiz/wkhtmltopdf-qt,igor-sfdc/qt-wk,pruiz/wkhtmltopdf-qt