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

Unified Diff: Source/core/html/HTMLPlugInElement.cpp

Issue 977113003: Rename renderer() to layoutObject(). (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase to master Created 5 years, 10 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/html/HTMLPlugInElement.cpp
diff --git a/Source/core/html/HTMLPlugInElement.cpp b/Source/core/html/HTMLPlugInElement.cpp
index 8bdde345283af03b7b29bf6a24f48181f1ac4c7f..8b9508203788d1ae7fcd75b8b62315cdb4b86239 100644
--- a/Source/core/html/HTMLPlugInElement.cpp
+++ b/Source/core/html/HTMLPlugInElement.cpp
@@ -140,7 +140,7 @@ bool HTMLPlugInElement::willRespondToMouseClickEvents()
{
if (isDisabledFormControl())
return false;
- LayoutObject* r = renderer();
+ LayoutObject* r = layoutObject();
return r && (r->isEmbeddedObject() || r->isLayoutPart());
}
@@ -164,7 +164,7 @@ void HTMLPlugInElement::attach(const AttachContext& context)
{
HTMLFrameOwnerElement::attach(context);
- if (!renderer() || useFallbackContent())
+ if (!layoutObject() || useFallbackContent())
return;
if (isImageType()) {
@@ -201,7 +201,7 @@ void HTMLPlugInElement::requestPluginCreationWithoutRendererIfPossible()
|| !document().frame()->loader().client()->canCreatePluginWithoutRenderer(m_serviceType))
return;
- if (renderer() && renderer()->isLayoutPart())
+ if (layoutObject() && layoutObject()->isLayoutPart())
return;
createPluginWithoutRenderer();
@@ -233,7 +233,7 @@ void HTMLPlugInElement::detach(const AttachContext& context)
{
// Update the widget the next time we attach (detaching destroys the plugin).
// FIXME: None of this "needsWidgetUpdate" related code looks right.
- if (renderer() && !useFallbackContent())
+ if (layoutObject() && !useFallbackContent())
setNeedsWidgetUpdate(true);
if (m_isDelayingLoadEvent) {
m_isDelayingLoadEvent = false;
@@ -374,7 +374,7 @@ void HTMLPlugInElement::defaultEventHandler(Event* event)
// FIXME: Mouse down and scroll events are passed down to plug-in via custom
// code in EventHandler; these code paths should be united.
- LayoutObject* r = renderer();
+ LayoutObject* r = layoutObject();
Julien - ping for review 2015/03/05 16:19:16 Note that s/renderer/layoutObject/ applies to |r|
if (!r || !r->isLayoutPart())
return;
if (r->isEmbeddedObject()) {
@@ -428,9 +428,9 @@ bool HTMLPlugInElement::rendererIsFocusable() const
if (HTMLFrameOwnerElement::supportsFocus() && HTMLFrameOwnerElement::rendererIsFocusable())
return true;
- if (useFallbackContent() || !renderer() || !renderer()->isEmbeddedObject())
+ if (useFallbackContent() || !layoutObject() || !layoutObject()->isEmbeddedObject())
return false;
- return !toLayoutEmbeddedObject(renderer())->showsUnavailablePluginIndicator();
+ return !toLayoutEmbeddedObject(layoutObject())->showsUnavailablePluginIndicator();
}
NPObject* HTMLPlugInElement::getNPObject()
@@ -466,9 +466,9 @@ LayoutEmbeddedObject* HTMLPlugInElement::layoutEmbeddedObject() const
{
// HTMLObjectElement and HTMLEmbedElement may return arbitrary renderers
// when using fallback content.
- if (!renderer() || !renderer()->isEmbeddedObject())
+ if (!layoutObject() || !layoutObject()->isEmbeddedObject())
return nullptr;
- return toLayoutEmbeddedObject(renderer());
+ return toLayoutEmbeddedObject(layoutObject());
}
// We don't use m_url, as it may not be the final URL that the object loads,
@@ -674,7 +674,7 @@ bool HTMLPlugInElement::useFallbackContent() const
void HTMLPlugInElement::lazyReattachIfNeeded()
{
- if (!useFallbackContent() && !usePlaceholderContent() && needsWidgetUpdate() && renderer() && !isImageType())
+ if (!useFallbackContent() && !usePlaceholderContent() && needsWidgetUpdate() && layoutObject() && !isImageType())
lazyReattachIfAttached();
}

Powered by Google App Engine
This is Rietveld 408576698