context_menu: Fix certain menu items not reacting to click events (#49557)
Kunall Banerjee
created
Use `Workspace::for_window` instead of `window.root().flatten()`.
https://github.com/user-attachments/assets/3ea6dae3-166d-49e4-9fff-8256e13cc2bf
https://github.com/user-attachments/assets/eb8d9394-5f71-4df6-b0db-c1c8078f1b9a
Before you mark this PR as ready for review, make sure that you have:
- [x] Added a solid test coverage and/or screenshots from doing manual
testing
- [x] Done a self-review taking into account security and performance
aspects
- [x] Aligned any UI changes with the [UI
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
Release Notes:
- Fixed certain context menu items not reacting to click events