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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/ui/Toolbar.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) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 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 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
117 button._clicked(/** @type {!Event} */ (event.data)); 117 button._clicked(/** @type {!Event} */ (event.data));
118 } 118 }
119 119
120 mainButtonClone.setToggled(action.toggled()); 120 mainButtonClone.setToggled(action.toggled());
121 buttons.push(mainButtonClone); 121 buttons.push(mainButtonClone);
122 122
123 var document = button.element.ownerDocument; 123 var document = button.element.ownerDocument;
124 document.documentElement.addEventListener('mouseup', mouseUp, false); 124 document.documentElement.addEventListener('mouseup', mouseUp, false);
125 125
126 var optionsGlassPane = new UI.GlassPane(); 126 var optionsGlassPane = new UI.GlassPane();
127 optionsGlassPane.setBlockPointerEvents(true); 127 optionsGlassPane.setPointerEventsBehavior(UI.GlassPane.PointerEventsBehavi or.BlockedByGlassPane);
128 optionsGlassPane.show(document); 128 optionsGlassPane.show(document);
129 var optionsBar = new UI.Toolbar('fill', optionsGlassPane.contentElement); 129 var optionsBar = new UI.Toolbar('fill', optionsGlassPane.contentElement);
130 optionsBar._contentElement.classList.add('floating'); 130 optionsBar._contentElement.classList.add('floating');
131 const buttonHeight = 26; 131 const buttonHeight = 26;
132 132
133 var hostButtonPosition = button.element.boxInWindow().relativeToElement(UI .GlassPane.container(document)); 133 var hostButtonPosition = button.element.boxInWindow().relativeToElement(UI .GlassPane.container(document));
134 134
135 var topNotBottom = hostButtonPosition.y + buttonHeight * buttons.length < document.documentElement.offsetHeight; 135 var topNotBottom = hostButtonPosition.y + buttonHeight * buttons.length < document.documentElement.offsetHeight;
136 136
137 if (topNotBottom) 137 if (topNotBottom)
(...skipping 915 matching lines...) Expand 10 before | Expand all | Expand 10 after
1053 /** 1053 /**
1054 * @param {!Common.Setting} setting 1054 * @param {!Common.Setting} setting
1055 * @param {string=} tooltip 1055 * @param {string=} tooltip
1056 * @param {string=} alternateTitle 1056 * @param {string=} alternateTitle
1057 */ 1057 */
1058 constructor(setting, tooltip, alternateTitle) { 1058 constructor(setting, tooltip, alternateTitle) {
1059 super(alternateTitle || setting.title() || '', tooltip); 1059 super(alternateTitle || setting.title() || '', tooltip);
1060 UI.SettingsUI.bindCheckbox(this.inputElement, setting); 1060 UI.SettingsUI.bindCheckbox(this.inputElement, setting);
1061 } 1061 }
1062 }; 1062 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698