Skip to content

Commit

Permalink
Reduce delay times for auto show/hide
Browse files Browse the repository at this point in the history
  • Loading branch information
jordanbaird committed Jan 26, 2024
1 parent 7a549a5 commit 5782c25
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Ice/MenuBar/MenuBarManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -98,15 +98,15 @@ final class MenuBarManager: ObservableObject {
}
if hiddenSection.isHidden {
if mouseIsInMenuBar(of: screen) {
DispatchQueue.main.asyncAfter(deadline: .now() + 0.2) {
DispatchQueue.main.asyncAfter(deadline: .now() + 0.1) {
// make sure the mouse is still inside
if self.mouseIsInMenuBar(of: screen) {
hiddenSection.show()
}
}
}
} else if NSEvent.mouseLocation.y < screen.visibleFrame.maxY {
DispatchQueue.main.asyncAfter(deadline: .now() + 0.2) {
DispatchQueue.main.asyncAfter(deadline: .now() + 0.1) {
// make sure the mouse is still outside
if NSEvent.mouseLocation.y < screen.visibleFrame.maxY {
hiddenSection.hide()
Expand All @@ -124,7 +124,7 @@ final class MenuBarManager: ObservableObject {
else {
break
}
DispatchQueue.main.asyncAfter(deadline: .now() + 0.2) {
DispatchQueue.main.asyncAfter(deadline: .now() + 0.1) {
hiddenSection.hide()
}
case .leftMouseDown:
Expand Down

0 comments on commit 5782c25

Please sign in to comment.