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

Unified Diff: Source/core/html/shadow/ClearButtonElement.cpp

Issue 23819007: Have Node::document() return a reference instead of a pointer (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Rebase on master Created 7 years, 4 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
« no previous file with comments | « Source/core/html/parser/HTMLDocumentParser.cpp ('k') | Source/core/html/shadow/DateTimeEditElement.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/shadow/ClearButtonElement.cpp
diff --git a/Source/core/html/shadow/ClearButtonElement.cpp b/Source/core/html/shadow/ClearButtonElement.cpp
index c3eb8e91b3cecfeaebedf3b774e12a64be1a854c..5f3eab77c7073a321197c4d87d99978e17c67d3a 100644
--- a/Source/core/html/shadow/ClearButtonElement.cpp
+++ b/Source/core/html/shadow/ClearButtonElement.cpp
@@ -54,7 +54,7 @@ PassRefPtr<ClearButtonElement> ClearButtonElement::create(Document* document, Cl
void ClearButtonElement::detach(const AttachContext& context)
{
if (m_capturing) {
- if (Frame* frame = document()->frame())
+ if (Frame* frame = document().frame())
frame->eventHandler()->setCapturingMouseEventsNode(0);
}
HTMLDivElement::detach(context);
@@ -65,7 +65,7 @@ void ClearButtonElement::releaseCapture()
if (!m_capturing)
return;
- if (Frame* frame = document()->frame()) {
+ if (Frame* frame = document().frame()) {
frame->eventHandler()->setCapturingMouseEventsNode(0);
m_capturing = false;
}
@@ -87,7 +87,7 @@ void ClearButtonElement::defaultEventHandler(Event* event)
if (event->type() == eventNames().mousedownEvent && event->isMouseEvent() && toMouseEvent(event)->button() == LeftButton) {
if (renderer() && renderer()->visibleToHitTesting()) {
- if (Frame* frame = document()->frame()) {
+ if (Frame* frame = document().frame()) {
frame->eventHandler()->setCapturingMouseEventsNode(this);
m_capturing = true;
}
@@ -97,7 +97,7 @@ void ClearButtonElement::defaultEventHandler(Event* event)
}
if (event->type() == eventNames().mouseupEvent && event->isMouseEvent() && toMouseEvent(event)->button() == LeftButton) {
if (m_capturing) {
- if (Frame* frame = document()->frame()) {
+ if (Frame* frame = document().frame()) {
frame->eventHandler()->setCapturingMouseEventsNode(0);
m_capturing = false;
}
« no previous file with comments | « Source/core/html/parser/HTMLDocumentParser.cpp ('k') | Source/core/html/shadow/DateTimeEditElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698