Skip to content

Commit

Permalink
bar: floating panel is focused on mousedown instead of on mouseover (…
Browse files Browse the repository at this point in the history
…BC break in behavior) [Closes #269]
  • Loading branch information
dg committed Feb 25, 2018
1 parent 470d8f2 commit db4f92e
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/Tracy/assets/Bar/bar.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,15 +39,22 @@
handles: elem.querySelectorAll('h1'),
start: function() {
_this.toFloat();
_this.focus();
}
});

elem.addEventListener('mouseover', function(e) {
elem.addEventListener('mousedown', function(e) {
if (isTargetChanged(e.relatedTarget, this)) {
_this.focus();
}
});

elem.addEventListener('mouseover', function(e) {
if (isTargetChanged(e.relatedTarget, this)) {
clearTimeout(elem.Tracy.displayTimeout);
}
});

elem.addEventListener('mouseout', function(e) {
if (isTargetChanged(e.relatedTarget, this)) {
_this.blur();
Expand Down

0 comments on commit db4f92e

Please sign in to comment.