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

Unified Diff: Source/core/html/shadow/SpinButtonElement.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
Index: Source/core/html/shadow/SpinButtonElement.cpp
diff --git a/Source/core/html/shadow/SpinButtonElement.cpp b/Source/core/html/shadow/SpinButtonElement.cpp
index 998f1d448aab20a96d3c5259fa2718ae9d49ea45..ad03f48eb09cd540599df84cf59a1f09e9a20fe5 100644
--- a/Source/core/html/shadow/SpinButtonElement.cpp
+++ b/Source/core/html/shadow/SpinButtonElement.cpp
@@ -116,10 +116,10 @@ void SpinButtonElement::defaultEventHandler(Event* event)
else if (event->type() == eventNames().mousemoveEvent) {
if (box->pixelSnappedBorderBoxRect().contains(local)) {
if (!m_capturing) {
- if (Frame* frame = document()->frame()) {
+ if (Frame* frame = document().frame()) {
frame->eventHandler()->setCapturingMouseEventsNode(this);
m_capturing = true;
- if (Page* page = document()->page())
+ if (Page* page = document().page())
page->chrome().registerPopupOpeningObserver(this);
}
}
@@ -192,10 +192,10 @@ void SpinButtonElement::releaseCapture()
{
stopRepeatingTimer();
if (m_capturing) {
- if (Frame* frame = document()->frame()) {
+ if (Frame* frame = document().frame()) {
frame->eventHandler()->setCapturingMouseEventsNode(0);
m_capturing = false;
- if (Page* page = document()->page())
+ if (Page* page = document().page())
page->chrome().unregisterPopupOpeningObserver(this);
}
}
« no previous file with comments | « Source/core/html/shadow/SliderThumbElement.cpp ('k') | Source/core/html/shadow/TextControlInnerElements.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698