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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/components/DOMBreakpointsSidebarPane.js

Issue 2217783002: DevTools: use view locations in the elements and sources sidebars. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: for landing Created 4 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 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * 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 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after
319 node.target().domdebuggerAgent().removeDOMBreakpoint(node.id, type); 319 node.target().domdebuggerAgent().removeDOMBreakpoint(node.id, type);
320 this._saveBreakpoints(); 320 this._saveBreakpoints();
321 }, 321 },
322 322
323 highlightBreakpoint: function(auxData) 323 highlightBreakpoint: function(auxData)
324 { 324 {
325 var breakpointId = this._createBreakpointId(auxData.nodeId, auxData.type ); 325 var breakpointId = this._createBreakpointId(auxData.nodeId, auxData.type );
326 var element = this._breakpointElements[breakpointId]; 326 var element = this._breakpointElements[breakpointId];
327 if (!element) 327 if (!element)
328 return; 328 return;
329 this.revealWidget(); 329 this.revealView();
330 element.classList.add("breakpoint-hit"); 330 element.classList.add("breakpoint-hit");
331 this._highlightedElement = element; 331 this._highlightedElement = element;
332 }, 332 },
333 333
334 clearBreakpointHighlight: function() 334 clearBreakpointHighlight: function()
335 { 335 {
336 if (this._highlightedElement) { 336 if (this._highlightedElement) {
337 this._highlightedElement.classList.remove("breakpoint-hit"); 337 this._highlightedElement.classList.remove("breakpoint-hit");
338 delete this._highlightedElement; 338 delete this._highlightedElement;
339 } 339 }
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
412 this._proxies = []; 412 this._proxies = [];
413 this._proxies.push(proxy); 413 this._proxies.push(proxy);
414 return proxy; 414 return proxy;
415 }, 415 },
416 416
417 __proto__: WebInspector.BreakpointsSidebarPaneBase.prototype 417 __proto__: WebInspector.BreakpointsSidebarPaneBase.prototype
418 } 418 }
419 419
420 /** 420 /**
421 * @constructor 421 * @constructor
422 * @extends {WebInspector.View} 422 * @extends {WebInspector.SimpleView}
423 * @param {!WebInspector.DOMBreakpointsSidebarPane} pane 423 * @param {!WebInspector.DOMBreakpointsSidebarPane} pane
424 * @param {!WebInspector.Panel} panel 424 * @param {!WebInspector.Panel} panel
425 */ 425 */
426 WebInspector.DOMBreakpointsSidebarPane.Proxy = function(pane, panel) 426 WebInspector.DOMBreakpointsSidebarPane.Proxy = function(pane, panel)
427 { 427 {
428 WebInspector.View.call(this, WebInspector.UIString("DOM Breakpoints")); 428 WebInspector.SimpleView.call(this, WebInspector.UIString("DOM Breakpoints")) ;
429 this.registerRequiredCSS("components/breakpointsList.css"); 429 this.registerRequiredCSS("components/breakpointsList.css");
430 430
431 this._wrappedPane = pane; 431 this._wrappedPane = pane;
432 this._panel = panel; 432 this._panel = panel;
433 } 433 }
434 434
435 WebInspector.DOMBreakpointsSidebarPane.Proxy.prototype = { 435 WebInspector.DOMBreakpointsSidebarPane.Proxy.prototype = {
436 wasShown: function() 436 wasShown: function()
437 { 437 {
438 WebInspector.View.prototype.wasShown.call(this); 438 WebInspector.SimpleView.prototype.wasShown.call(this);
439 this._reattachBody(); 439 this._reattachBody();
440 }, 440 },
441 441
442 _reattachBody: function() 442 _reattachBody: function()
443 { 443 {
444 if (this._wrappedPane.element.parentNode !== this.element) 444 if (this._wrappedPane.element.parentNode !== this.element)
445 this._wrappedPane.show(this.element); 445 this._wrappedPane.show(this.element);
446 }, 446 },
447 447
448 __proto__: WebInspector.View.prototype 448 __proto__: WebInspector.SimpleView.prototype
449 } 449 }
450 450
451 /** 451 /**
452 * @type {!WebInspector.DOMBreakpointsSidebarPane} 452 * @type {!WebInspector.DOMBreakpointsSidebarPane}
453 */ 453 */
454 WebInspector.domBreakpointsSidebarPane; 454 WebInspector.domBreakpointsSidebarPane;
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698