Commit Graph
113 Commits
Author SHA1 Message Date
Antonio ScandurraandNathan Sobo ef89ceae4d Take &mut self in View::render
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-30 17:51:26 +02:00
Antonio ScandurraandNathan Sobo 53dc08dfc5 Remove lock from element states
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-27 18:04:21 +02:00
Antonio Scandurra 30ce7f6122 Allow styling sidebar's resize handle 2021-08-27 14:57:47 +02:00
Antonio Scandurra bed9d9c9d8 Add the ability to resize sidebar items 2021-08-27 14:30:35 +02:00
Antonio Scandurra 386631debf Focus toggled elements when interacting with the sidebars
Also, restore focus on the workspace when there is no active item
on the sidebar that was just toggled.
2021-08-27 10:01:44 +02:00
3bb5610ad1 Overhaul handling of font families
* Specify font families in the theme.
* Load fonts eagerly when loading themes, instead of loading
  them lazily when rendering.

Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-26 15:06:00 -07:00
Max Brunsfeld b923f65a63 WIP 2021-08-25 15:22:14 -07:00
Nathan SoboandAntonio Scandurra 9b636fb81e Add "Zed > Sign" In menu item
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
2021-08-24 08:29:36 -06:00
Antonio Scandurra 405ff1d9db Render chat messages in ChatPanel 2021-08-24 12:23:50 +02:00
Max Brunsfeld baded7d416 Start work on subscribing to model from ChatPanel 2021-08-23 17:21:06 -07:00
Max BrunsfeldandNathan Sobo 6df80d94ad Allow subscription/notification to be cancelled by dropping the returned Subscription
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-23 15:54:24 -07:00
Max BrunsfeldandNathan Sobo fa0739ee2e Remove model and view specific observe/subscribe methods
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-23 15:07:50 -07:00
Max Brunsfeld 5ecedd894d Add ChannelList to AppState 2021-08-23 15:03:45 -07:00
Antonio ScandurraandNathan Sobo a182db863f WIP: Render dummy chat messages to test List
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-23 17:29:46 +02:00
Antonio ScandurraandNathan Sobo 94e9a83326 Give up on entities being Send and Sync
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-23 17:04:32 +02:00
Nathan Sobo 86effd64a2 Get project compiling with type-safe actions 2021-08-22 21:02:48 -06:00
Max BrunsfeldandNathan Sobo b88b3e7657 Add sidebars
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-20 13:51:52 -07:00
Max Brunsfeld c7c7a197d1 Merge remote-tracking branch 'origin/sexy' into chat-theme-prep 2021-08-20 09:50:58 -07:00
9ff764983d Flatten theme styles by eliminating top-level ui key
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
2021-08-20 10:44:34 -06:00
Max BrunsfeldandNathan Sobo 86c819757d Move Arc outside of rpc::Client
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-19 12:56:50 -07:00
5338b30c00 Remove remaining instances of router
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2021-08-19 19:38:17 +02:00
Antonio Scandurra d6412fdbde Delete old Peer implementation and adapt previous code paths
This still doesn't compile but should be close.
2021-08-19 15:02:30 +02:00
Nathan Sobo 34eb2c446f Start on custom titlebar 2021-08-05 11:48:35 -06:00
Nathan SoboandMax Brunsfeld 1a21902460 Move fuzzy mod out of worktree
We now match against arbitrary strings in addition to paths.

Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
2021-08-04 17:46:53 -06:00
Nathan Sobo 85a076312a Merge branch 'main' into theme-variables 2021-08-04 16:47:43 -06:00
Max BrunsfeldandNathan Sobo b30d0daabf Add a theme picker
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-08-02 14:55:27 -07:00
Max Brunsfeld 92353b6967 Start work on allowing variables in themes 2021-07-30 17:28:22 -07:00
Max Brunsfeld eb05103d2d Fix saving an untitled file outside of any existing worktree 2021-07-30 14:19:42 -07:00
Max Brunsfeld 4c3f97d123 Fix type of Workspace::open_new_file context parameter
Fixes #118
2021-07-30 10:11:46 -07:00
Max Brunsfeld 372d2ccb6d Extract most colors in codebase into theme file. switch to dark 2021-07-30 09:50:28 -07:00
Nathan Sobo f81f043058 WIP 2021-07-23 12:25:09 -06:00
Max Brunsfeld 7260442d42 Move the fs module out of worktree 2021-07-13 15:40:11 -07:00
Antonio ScandurraandNathan Sobo 7ad2071a51 Fix tests that were not aware of Worktree::open_local being async
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-07-13 17:27:40 +02:00
Antonio Scandurra 2ecdc65f38 WIP 2021-07-13 16:36:35 +02:00
Max BrunsfeldandNathan Sobo 2a90347b82 Store an Fs on Workspace, pass it to each Worktree
Push test-only worktree behavior down into the Fs,
via a `watch` method which provides fs events.

Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-07-12 17:26:14 -07:00
Antonio ScandurraandNathan Sobo 59d61d33cb Allow worktrees to be joined with no open window
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-07-12 17:44:53 +02:00
Max Brunsfeld eeebc761b6 Restructure Peer to handle connections' messages in order 2021-07-09 16:27:34 -07:00
Antonio Scandurra f55718cd18 Avoid adding the same entry when concurrently opening it more than once 2021-07-08 14:40:32 +02:00
Antonio ScandurraandMax Brunsfeld 024684e46c Improve logging when there is an error in the RPC layer
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2021-07-07 19:36:53 +02:00
Antonio Scandurra ee962eab9b Revert "Start work on handling TLS for the RPC endpoint"
This reverts commit 193c704875.
2021-07-07 15:19:00 +02:00
Max Brunsfeld 193c704875 Start work on handling TLS for the RPC endpoint 2021-07-06 16:27:57 -07:00
Max BrunsfeldandNathan Sobo 65e4e78cd7 Add unit test for worktree update messages, fix minor issues
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-07-05 17:55:48 -07:00
Nathan Sobo bbf803d7dc Store a reference to the LangageRegistry on the Worktree 2021-06-29 20:07:37 -06:00
34963ac80d Use entry_id on File instead of worktree::Diff to detect when buffers' files change
Rather than computing a diff after processing a batch of FSEvents, we instead detect renames as we're inserting entries. We store an entry_id on the File object that is owned by each buffer, and use this to detect when the path of the File has changed.

We now also manage all File-related state and event emission for Buffers in the LocalWorktree, since the logic will need to be totally different in the remote case.

Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
2021-06-29 18:19:38 -06:00
Antonio Scandurra e80439daaa Merge branch 'main' into rpc 2021-06-29 10:25:42 +02:00
Nathan Sobo b7a4393f29 Redesign Worktree save API and make test_rescan_simple pass
This commit does too much. The first goal was to change our approach to saving new buffers so that we don't need to construct a File for an entry that doesn't exist. Rather than doing that, we call `Worktree::save_buffer_as` with the buffer handle, the path, and the contents. This then saves the buffer and returns a handle to a `File` that references an entry that actually exists. I needed to do this so that we can store an entry id on `File`.

In the process, I noticed intermittent test failures on `test_rescan_simple`, so I made some changes required to fix those related to our reuse of existing ids. Our previous approach of removing a path when inserting a new entry was broken, because of the recursive nature of `remove_path`. Instead, I simply recycle the id of an existing worktree entry with the same path if one is present, then allow it to be replaced.
2021-06-28 19:05:38 -06:00
Nathan SoboandMax Brunsfeld 7ee0862b99 Notify host when guests close buffers
Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
2021-06-25 11:33:40 -07:00
Antonio Scandurra d59267a7ef Move remote module from workspace to worktree 2021-06-25 12:14:04 +02:00
Max Brunsfeld ce2f3f664a Consolidate more logic for joining worktree in Worktree::remote
This way we can use this method in tests and avoid
needing to construct a Workspace.
2021-06-23 18:07:09 -07:00
Max BrunsfeldandNathan Sobo 6a166554e8 Add public method for connecting to RPC server with a given address
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2021-06-23 18:05:03 -07:00