+
+ // This is designed for replacing pixmap surfaces, but should work for window as well
+ // we need to delete the surface and renderable (pixmap / window)
+ // Then create a new pixmap/window and new surface
+ // If the new surface has a different display connection, then the context will be lost
+
+ mAdaptorInterfaces.GetDisplayConnectionInterface().Initialize();
+ newSurface->InitializeGraphics( mAdaptorInterfaces.GetGraphicsInterface(), mAdaptorInterfaces.GetDisplayConnectionInterface() );
+ newSurface->ReplaceGraphicsSurface();