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

Unified Diff: Source/core/frame/FrameView.cpp

Issue 564133003: Make better use of MediaTypeNames (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add more Created 6 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/frame/FrameView.cpp
diff --git a/Source/core/frame/FrameView.cpp b/Source/core/frame/FrameView.cpp
index 0aead4777869975461aa32155082b51948005ade..2feb28d6a8d15f8c31df29bb1f358555cff3d069 100644
--- a/Source/core/frame/FrameView.cpp
+++ b/Source/core/frame/FrameView.cpp
@@ -28,6 +28,7 @@
#include "core/frame/FrameView.h"
#include "core/HTMLNames.h"
+#include "core/MediaTypeNames.h"
#include "core/accessibility/AXObjectCache.h"
#include "core/css/FontFaceSet.h"
#include "core/css/resolver/StyleResolver.h"
@@ -105,7 +106,7 @@ FrameView::FrameView(LocalFrame* frame)
, m_updateWidgetsTimer(this, &FrameView::updateWidgetsTimerFired)
, m_isTransparent(false)
, m_baseBackgroundColor(Color::white)
- , m_mediaType("screen")
+ , m_mediaType(MediaTypeNames::screen)
, m_overflowStatusDirty(true)
, m_viewportRenderer(0)
, m_wasScrolledByUser(false)
@@ -1105,7 +1106,7 @@ void FrameView::adjustMediaTypeForPrinting(bool printing)
if (printing) {
if (m_mediaTypeWhenNotPrinting.isNull())
m_mediaTypeWhenNotPrinting = mediaType();
- setMediaType("print");
+ setMediaType(MediaTypeNames::print);
} else {
if (!m_mediaTypeWhenNotPrinting.isNull())
setMediaType(m_mediaTypeWhenNotPrinting);

Powered by Google App Engine
This is Rietveld 408576698