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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/elements/ElementsPanel.js

Issue 1878123003: DevTools: fix elements-panel-shadow-selection-on-refresh.html (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: split test into many Created 4 years, 8 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) 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.
3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com> 3 * Copyright (C) 2008 Matt Lilek <webkit@mattlilek.com>
4 * Copyright (C) 2009 Joseph Pecoraro 4 * Copyright (C) 2009 Joseph Pecoraro
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 9 *
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 447 matching lines...) Expand 10 before | Expand all | Expand 10 after
458 * @this {WebInspector.ElementsPanel} 458 * @this {WebInspector.ElementsPanel}
459 */ 459 */
460 function selectLastSelectedNode(nodeId) 460 function selectLastSelectedNode(nodeId)
461 { 461 {
462 if (this.selectedDOMNode()) { 462 if (this.selectedDOMNode()) {
463 // Focused node has been explicitly set while reaching out for t he last selected node. 463 // Focused node has been explicitly set while reaching out for t he last selected node.
464 return; 464 return;
465 } 465 }
466 var node = nodeId ? domModel.nodeForId(nodeId) : null; 466 var node = nodeId ? domModel.nodeForId(nodeId) : null;
467 selectNode.call(this, node); 467 selectNode.call(this, node);
468 this._lastSelectedNodeSelectedForTest();
468 } 469 }
469 470
470 if (this._omitDefaultSelection) 471 if (this._omitDefaultSelection)
471 return; 472 return;
472 473
473 if (this._selectedPathOnReset) 474 if (this._selectedPathOnReset)
474 domModel.pushNodeByPathToFrontend(this._selectedPathOnReset, selectL astSelectedNode.bind(this)); 475 domModel.pushNodeByPathToFrontend(this._selectedPathOnReset, selectL astSelectedNode.bind(this));
475 else 476 else
476 selectNode.call(this, null); 477 selectNode.call(this, null);
477 delete this._selectedPathOnReset; 478 delete this._selectedPathOnReset;
478 }, 479 },
479 480
481 _lastSelectedNodeSelectedForTest: function() { },
482
480 /** 483 /**
481 * @override 484 * @override
482 */ 485 */
483 searchCanceled: function() 486 searchCanceled: function()
484 { 487 {
485 delete this._searchQuery; 488 delete this._searchQuery;
486 this._hideSearchHighlights(); 489 this._hideSearchHighlights();
487 490
488 this._searchableView.updateSearchMatchesCount(0); 491 this._searchableView.updateSearchMatchesCount(0);
489 492
(...skipping 794 matching lines...) Expand 10 before | Expand all | Expand 10 after
1284 */ 1287 */
1285 wasShown: function() 1288 wasShown: function()
1286 { 1289 {
1287 this._toolbarItem.setToggled(true); 1290 this._toolbarItem.setToggled(true);
1288 this._nodeChanged(); 1291 this._nodeChanged();
1289 WebInspector.ThrottledWidget.prototype.wasShown.call(this); 1292 WebInspector.ThrottledWidget.prototype.wasShown.call(this);
1290 }, 1293 },
1291 1294
1292 __proto__: WebInspector.ThrottledWidget.prototype 1295 __proto__: WebInspector.ThrottledWidget.prototype
1293 } 1296 }
OLDNEW
« no previous file with comments | « third_party/WebKit/LayoutTests/inspector/elements/shadow/elements-panel-shadow-selection-on-refresh-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698