Skip to content
This repository was archived by the owner on Feb 13, 2024. It is now read-only.

Commit

Permalink
Merge pull request #4772 from toggl-open-source/fix/close-dd-on-tab-c…
Browse files Browse the repository at this point in the history
…lick

Close duration dropdown when user clicks the List/Timeline tabs
  • Loading branch information
skel35 authored Dec 22, 2020
2 parents c506d9a + 6230478 commit 307a438
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,18 @@ final class MainDashboardViewController: NSViewController {
}

@IBAction func listBtnOnTap(_ sender: Any) {
guard currentTab != .timeEntryList else {
view.window?.makeFirstResponder(nil)
return
}
currentTab = .timeEntryList
}

@IBAction func timelineBtnOnTap(_ sender: Any) {
guard currentTab != .timeline else {
view.window?.makeFirstResponder(nil)
return
}
currentTab = .timeline
timelineController.scrollToVisibleItem()
// Onboarding states
Expand Down

0 comments on commit 307a438

Please sign in to comment.