Guest User

Untitled

a guest
Jul 15th, 2018
153
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.60 KB | None | 0 0
  1. diff --git a/WebKit2/ChangeLog b/WebKit2/ChangeLog
  2. index 5443f24..2bd4661 100644
  3. --- a/WebKit2/ChangeLog
  4. +++ b/WebKit2/ChangeLog
  5. @@ -1,5 +1,17 @@
  6. 2010-11-24 Andreas Kling <kling@webkit.org>
  7.  
  8. + Reviewed by NOBODY (OOPS!).
  9. +
  10. + [Qt][WK2] Make deep copies of tile images
  11. +
  12. + We need the tile images we get from UpdateChunk::createImage() to persist,
  13. + so we should take a copy() of them.
  14. +
  15. + * UIProcess/qt/TiledDrawingAreaTileQt.cpp:
  16. + (WebKit::TiledDrawingAreaTile::updateFromChunk):
  17. +
  18. +2010-11-24 Andreas Kling <kling@webkit.org>
  19. +
  20. Reviewed by Kenneth Rohde Christiansen.
  21.  
  22. [Qt] Fix uninitialized variable in QGraphicsWKViewPrivate
  23. diff --git a/WebKit2/UIProcess/qt/TiledDrawingAreaTileQt.cpp b/WebKit2/UIProcess/qt/TiledDrawingAreaTileQt.cpp
  24. index f4ca678..5f95d02 100644
  25. --- a/WebKit2/UIProcess/qt/TiledDrawingAreaTileQt.cpp
  26. +++ b/WebKit2/UIProcess/qt/TiledDrawingAreaTileQt.cpp
  27. @@ -170,9 +170,10 @@ void TiledDrawingAreaTile::updateFromChunk(UpdateChunk* updateChunk, float)
  28. #ifdef TILE_DEBUG_LOG
  29. qDebug() << "tile updated id=" << ID() << " rect=" << QRect(updateChunkRect);
  30. #endif
  31. - if (updateChunkRect.size() == m_proxy->tileSize())
  32. - m_backBuffer = QPixmap::fromImage(image);
  33. - else {
  34. + if (updateChunkRect.size() == m_proxy->tileSize()) {
  35. + // Make a deep copy of the image since it's in shared memory.
  36. + m_backBuffer = QPixmap::fromImage(image.copy());
  37. + } else {
  38. if (m_backBuffer.isNull())
  39. m_backBuffer = m_buffer.isNull() ? QPixmap(m_proxy->tileSize()) : m_buffer;
  40. QPainter painter(&m_backBuffer);
Add Comment
Please, Sign In to add comment