Skip to content

Commit

Permalink
fix(notificationa): don't reset x_offset when closing window
Browse files Browse the repository at this point in the history
  • Loading branch information
j-hui committed Feb 5, 2024
1 parent 53d5b79 commit d1b2a71
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 3 additions & 0 deletions lua/fidget/notification.lua
Original file line number Diff line number Diff line change
Expand Up @@ -346,6 +346,9 @@ function notification.clear_history(filter)
end

--- Reset notification subsystem state.
---
--- Note that this function does not set any Fidget notification window state,
--- in particular, the `x_offset`.
function notification.reset()
notification.clear()
notification.clear_history()
Expand Down
2 changes: 0 additions & 2 deletions lua/fidget/notification/window.lua
Original file line number Diff line number Diff line change
Expand Up @@ -484,8 +484,6 @@ function M.close()
end
state.buffer_id = nil
end

state.x_offset = 0
end

--- Set x_offset, shifting the horizontal position of the notification window.
Expand Down

0 comments on commit d1b2a71

Please sign in to comment.