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

Unified Diff: Source/devtools/front_end/SourceFrame.js

Issue 203433002: DevTools: Reuse _showSourceLocation for execution line changes handling in sources panel (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 9 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/devtools/front_end/SourceFrame.js
diff --git a/Source/devtools/front_end/SourceFrame.js b/Source/devtools/front_end/SourceFrame.js
index 03f73d4a75011fa448add1d5bcd04190ab83fd76..f4401d99814a1ed065e489dd6775b2bb91224626 100644
--- a/Source/devtools/front_end/SourceFrame.js
+++ b/Source/devtools/front_end/SourceFrame.js
@@ -126,7 +126,6 @@ WebInspector.SourceFrame.prototype = {
WebInspector.View.prototype.willHide.call(this);
this._clearPositionHighlight();
- this._clearLineToReveal();
},
/**
@@ -213,7 +212,6 @@ WebInspector.SourceFrame.prototype = {
*/
highlightPosition: function(line, column)
{
- this._clearLineToReveal();
this._clearLineToScrollTo();
this._clearSelectionToSet();
this._positionToHighlight = { line: line, column: column };
@@ -241,37 +239,9 @@ WebInspector.SourceFrame.prototype = {
/**
* @param {number} line
*/
- revealLine: function(line)
- {
- this._clearPositionHighlight();
- this._clearLineToScrollTo();
- this._clearSelectionToSet();
- this._lineToReveal = line;
- this._innerRevealLineIfNeeded();
- },
-
- _innerRevealLineIfNeeded: function()
- {
- if (typeof this._lineToReveal === "number") {
- if (this.loaded && this._isEditorShowing()) {
- this._textEditor.revealLine(this._lineToReveal);
- delete this._lineToReveal;
- }
- }
- },
-
- _clearLineToReveal: function()
- {
- delete this._lineToReveal;
- },
-
- /**
- * @param {number} line
- */
scrollToLine: function(line)
{
this._clearPositionHighlight();
- this._clearLineToReveal();
this._lineToScrollTo = line;
this._innerScrollToLineIfNeeded();
},
@@ -324,7 +294,6 @@ WebInspector.SourceFrame.prototype = {
_wasShownOrLoaded: function()
{
this._innerHighlightPositionIfNeeded();
- this._innerRevealLineIfNeeded();
this._innerSetSelectionIfNeeded();
this._innerScrollToLineIfNeeded();
},

Powered by Google App Engine
This is Rietveld 408576698