Title: [181721] trunk/Source/WebKit2
- Revision
- 181721
- Author
- simon.fra...@apple.com
- Date
- 2015-03-18 19:16:12 -0700 (Wed, 18 Mar 2015)
Log Message
Don't paint PDFs on every scroll
https://bugs.webkit.org/show_bug.cgi?id=142857
rdar://problem/20130207
Reviewed by Tim Horton.
Don't push a scale factor onto the PDF layer controller if it hasn't
changed, since doing so causes a repaint.
* WebProcess/Plugins/PDF/PDFPlugin.mm:
(WebKit::PDFPlugin::updatePageAndDeviceScaleFactors):
Modified Paths
Diff
Modified: trunk/Source/WebKit2/ChangeLog (181720 => 181721)
--- trunk/Source/WebKit2/ChangeLog 2015-03-19 02:15:00 UTC (rev 181720)
+++ trunk/Source/WebKit2/ChangeLog 2015-03-19 02:16:12 UTC (rev 181721)
@@ -1,3 +1,17 @@
+2015-03-18 Simon Fraser <simon.fra...@apple.com>
+
+ Don't paint PDFs on every scroll
+ https://bugs.webkit.org/show_bug.cgi?id=142857
+ rdar://problem/20130207
+
+ Reviewed by Tim Horton.
+
+ Don't push a scale factor onto the PDF layer controller if it hasn't
+ changed, since doing so causes a repaint.
+
+ * WebProcess/Plugins/PDF/PDFPlugin.mm:
+ (WebKit::PDFPlugin::updatePageAndDeviceScaleFactors):
+
2015-03-18 Anders Carlsson <ander...@apple.com>
Use && instead of & when deciding if the network cache should be cleared
Modified: trunk/Source/WebKit2/WebProcess/Plugins/PDF/PDFPlugin.mm (181720 => 181721)
--- trunk/Source/WebKit2/WebProcess/Plugins/PDF/PDFPlugin.mm 2015-03-19 02:15:00 UTC (rev 181720)
+++ trunk/Source/WebKit2/WebProcess/Plugins/PDF/PDFPlugin.mm 2015-03-19 02:16:12 UTC (rev 181721)
@@ -1030,7 +1030,8 @@
if (!handlesPageScaleFactor())
newScaleFactor *= webFrame()->page()->pageScaleFactor();
- [m_pdfLayerController setDeviceScaleFactor:newScaleFactor];
+ if (newScaleFactor != [m_pdfLayerController deviceScaleFactor])
+ [m_pdfLayerController setDeviceScaleFactor:newScaleFactor];
}
void PDFPlugin::contentsScaleFactorChanged(float)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes