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

Side by Side Diff: third_party/WebKit/Source/web/InspectorOverlay.cpp

Issue 2014493002: Rename OwnPtr::clear() to reset() in web/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 283 matching lines...) Expand 10 before | Expand all | Expand 10 after
294 void InspectorOverlay::setPausedInDebuggerMessage(const String& message) 294 void InspectorOverlay::setPausedInDebuggerMessage(const String& message)
295 { 295 {
296 m_pausedInDebuggerMessage = message; 296 m_pausedInDebuggerMessage = message;
297 scheduleUpdate(); 297 scheduleUpdate();
298 } 298 }
299 299
300 void InspectorOverlay::hideHighlight() 300 void InspectorOverlay::hideHighlight()
301 { 301 {
302 m_highlightNode.clear(); 302 m_highlightNode.clear();
303 m_eventTargetNode.clear(); 303 m_eventTargetNode.clear();
304 m_highlightQuad.clear(); 304 m_highlightQuad.reset();
305 scheduleUpdate(); 305 scheduleUpdate();
306 } 306 }
307 307
308 void InspectorOverlay::highlightNode(Node* node, const InspectorHighlightConfig& highlightConfig, bool omitTooltip) 308 void InspectorOverlay::highlightNode(Node* node, const InspectorHighlightConfig& highlightConfig, bool omitTooltip)
309 { 309 {
310 highlightNode(node, nullptr, highlightConfig, omitTooltip); 310 highlightNode(node, nullptr, highlightConfig, omitTooltip);
311 } 311 }
312 312
313 void InspectorOverlay::highlightNode(Node* node, Node* eventTarget, const Inspec torHighlightConfig& highlightConfig, bool omitTooltip) 313 void InspectorOverlay::highlightNode(Node* node, Node* eventTarget, const Inspec torHighlightConfig& highlightConfig, bool omitTooltip)
314 { 314 {
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
360 if (m_suspendCount) 360 if (m_suspendCount)
361 return true; 361 return true;
362 bool hasVisibleElements = m_highlightNode || m_eventTargetNode || m_highligh tQuad || (m_resizeTimerActive && m_drawViewSize) || !m_pausedInDebuggerMessage. isNull(); 362 bool hasVisibleElements = m_highlightNode || m_eventTargetNode || m_highligh tQuad || (m_resizeTimerActive && m_drawViewSize) || !m_pausedInDebuggerMessage. isNull();
363 return !hasVisibleElements && m_inspectMode == InspectorDOMAgent::NotSearchi ng; 363 return !hasVisibleElements && m_inspectMode == InspectorDOMAgent::NotSearchi ng;
364 } 364 }
365 365
366 void InspectorOverlay::scheduleUpdate() 366 void InspectorOverlay::scheduleUpdate()
367 { 367 {
368 if (isEmpty()) { 368 if (isEmpty()) {
369 if (m_pageOverlay) 369 if (m_pageOverlay)
370 m_pageOverlay.clear(); 370 m_pageOverlay.reset();
371 return; 371 return;
372 } 372 }
373 m_needsUpdate = true; 373 m_needsUpdate = true;
374 FrameView* view = m_webViewImpl->mainFrameImpl()->frameView(); 374 FrameView* view = m_webViewImpl->mainFrameImpl()->frameView();
375 if (view) 375 if (view)
376 m_webViewImpl->page()->chromeClient().scheduleAnimation(view); 376 m_webViewImpl->page()->chromeClient().scheduleAnimation(view);
377 } 377 }
378 378
379 void InspectorOverlay::rebuildOverlayPage() 379 void InspectorOverlay::rebuildOverlayPage()
380 { 380 {
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after
776 776
777 void InspectorOverlay::initializeLayoutEditorIfNeeded(Node* node) 777 void InspectorOverlay::initializeLayoutEditorIfNeeded(Node* node)
778 { 778 {
779 if (m_inspectMode != InspectorDOMAgent::ShowLayoutEditor || !node || !node-> isElementNode() || !node->ownerDocument()->isActive() || !m_cssAgent || !m_domAg ent) 779 if (m_inspectMode != InspectorDOMAgent::ShowLayoutEditor || !node || !node-> isElementNode() || !node->ownerDocument()->isActive() || !m_cssAgent || !m_domAg ent)
780 return; 780 return;
781 m_layoutEditor = LayoutEditor::create(toElement(node), m_cssAgent, m_domAgen t, &overlayMainFrame()->script()); 781 m_layoutEditor = LayoutEditor::create(toElement(node), m_cssAgent, m_domAgen t, &overlayMainFrame()->script());
782 toChromeClientImpl(m_webViewImpl->page()->chromeClient()).setCursorOverridde n(true); 782 toChromeClientImpl(m_webViewImpl->page()->chromeClient()).setCursorOverridde n(true);
783 } 783 }
784 784
785 } // namespace blink 785 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/ExternalPopupMenu.cpp ('k') | third_party/WebKit/Source/web/LinkHighlightImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698