Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(787)

Unified Diff: Source/core/dom/Document.cpp

Issue 23861003: Enable srcset support in HTMLImageElement (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Added a run-time flag, marking this feature as experimental Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/dom/Document.cpp
diff --git a/Source/core/dom/Document.cpp b/Source/core/dom/Document.cpp
index 85cc254ebfd767776ee4879b903ed8441e0ea780..088d77dd37de8b6f688e5c16e9606735e4151621 100644
--- a/Source/core/dom/Document.cpp
+++ b/Source/core/dom/Document.cpp
@@ -5317,6 +5317,14 @@ void Document::didAssociateFormControlsTimerFired(Timer<Document>* timer)
m_associatedFormControls.clear();
}
+float Document::devicePixelRatio() const
+{
+ float devicePixelRatio = 1.0;
do-not-use 2013/09/12 08:23:53 nit: return m_frame ? m_frame->devicePixelRatio()
+ if (m_frame)
+ devicePixelRatio = m_frame->devicePixelRatio();
+ return devicePixelRatio;
+}
+
PassOwnPtr<LifecycleNotifier> Document::createLifecycleNotifier()
{
return DocumentLifecycleNotifier::create(this);

Powered by Google App Engine
This is Rietveld 408576698