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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/perf_ui/TimelineOverviewPane.js

Issue 2834053004: DevTools: Fix timeline overview flickering (Closed)
Patch Set: addressing comment Created 3 years, 7 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) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 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 461 matching lines...) Expand 10 before | Expand all | Expand 10 after
472 } 472 }
473 }; 473 };
474 474
475 PerfUI.TimelineOverviewPane.OverviewInfo = class { 475 PerfUI.TimelineOverviewPane.OverviewInfo = class {
476 /** 476 /**
477 * @param {!Element} anchor 477 * @param {!Element} anchor
478 */ 478 */
479 constructor(anchor) { 479 constructor(anchor) {
480 this._anchorElement = anchor; 480 this._anchorElement = anchor;
481 this._glassPane = new UI.GlassPane(); 481 this._glassPane = new UI.GlassPane();
482 this._glassPane.setBlockPointerEvents(false); 482 this._glassPane.setPointerEventsBehavior(UI.GlassPane.PointerEventsBehavior. PierceContents);
483 this._glassPane.setMarginBehavior(UI.GlassPane.MarginBehavior.NoMargin); 483 this._glassPane.setMarginBehavior(UI.GlassPane.MarginBehavior.Arrow);
484 this._glassPane.setSizeBehavior(UI.GlassPane.SizeBehavior.MeasureContent); 484 this._glassPane.setSizeBehavior(UI.GlassPane.SizeBehavior.MeasureContent);
485 this._element = 485 this._element =
486 UI.createShadowRootWithCoreStyles(this._glassPane.contentElement, 'perf_ ui/timelineOverviewInfo.css') 486 UI.createShadowRootWithCoreStyles(this._glassPane.contentElement, 'perf_ ui/timelineOverviewInfo.css')
487 .createChild('div', 'overview-info'); 487 .createChild('div', 'overview-info');
488 } 488 }
489 489
490 /** 490 /**
491 * @param {!DocumentFragment} content 491 * @param {!DocumentFragment} content
492 */ 492 */
493 setContent(content) { 493 setContent(content) {
494 this._element.removeChildren(); 494 this._element.removeChildren();
495 this._element.appendChild(content); 495 this._element.appendChild(content);
496 this._glassPane.setContentAnchorBox(this._anchorElement.boxInWindow()); 496 this._glassPane.setContentAnchorBox(this._anchorElement.boxInWindow());
497 if (!this._glassPane.isShowing()) 497 if (!this._glassPane.isShowing())
498 this._glassPane.show(/** @type {!Document} */ (this._anchorElement.ownerDo cument)); 498 this._glassPane.show(/** @type {!Document} */ (this._anchorElement.ownerDo cument));
499 } 499 }
500 500
501 hide() { 501 hide() {
502 this._glassPane.hide(); 502 this._glassPane.hide();
503 } 503 }
504 }; 504 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698