Commit Graph
57 Commits
Author SHA1 Message Date
Antonio Scandurra ce06f5ef2a Pretty-print JSON of server snapshot 2022-05-26 09:34:39 +02:00
Antonio Scandurra 4618463f6b Fix unit tests assuming ignored files were not displayed 2022-05-24 10:50:27 +02:00
Antonio Scandurra f9ff36e740 Make fade of ignored entries styleable 2022-05-24 09:12:57 +02:00
Antonio Scandurra 039dccc483 Show ignored entries in project panel 2022-05-23 16:37:57 +02:00
Max Brunsfeld e6011794ca Remove AppState from workspace actions
This allows those actions to be bound to keystrokes in the keymap.
Also, remove the WorkspaceParams struct, simplify how Workspaces are
constructed.
2022-05-19 14:37:26 -07:00
Antonio ScandurraandNathan Sobo 0aa63af210 Show badge when there are pending contact requests
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-05-11 17:39:03 +02:00
Antonio ScandurraandNathan Sobo 5d5dcf9b4e Fix memory leak of ProjectPanel
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-05-05 15:52:46 +02:00
Antonio ScandurraandNathan Sobo 4df9ab8352 Improve delete prompt in project browser
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-05-05 15:49:40 +02:00
Antonio ScandurraandNathan Sobo 8c4c2010eb Clear project browser editor even if an operation fails
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-05-05 15:43:42 +02:00
Antonio ScandurraandNathan Sobo 4729ab818d When opening items via project panel, only focus them on double-click
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-05-05 15:27:27 +02:00
Antonio Scandurra 58367fccfb WIP 2022-05-05 15:15:58 +02:00
Max Brunsfeld 51bf66e754 Allow deleting entries from the project panel 2022-05-04 18:00:23 -07:00
Max Brunsfeld 39f264e9fd Allow creating directories from the project panel 2022-05-04 16:47:11 -07:00
Max Brunsfeld 198bb7bbd1 Keep showing edited filename in project panel while edit is in-progress 2022-05-04 13:03:50 -07:00
d86f385278 Allow guests to rename stuff
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-05-04 10:28:44 -07:00
Nathan SoboandAntonio Scandurra 6ad2213b7f Rename entries via the project to prepare for guest support
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
2022-05-04 10:28:44 -07:00
Max BrunsfeldandNathan Sobo 8b64406938 Allow guests to create files from the project panel
Co-authored-by: Nathan Sobo <nathan@zed.dev>
2022-05-04 10:28:44 -07:00
Max Brunsfeld 5fdaa2da96 Update snapshot atomically when processing FS events 2022-05-04 10:28:44 -07:00
Max Brunsfeld 133cb544b2 Select new files in the project panel after creating them 2022-05-04 10:28:44 -07:00
Max BrunsfeldandAntonio Scandurra c98d740d34 Improve the appearance of project panel filename editor
* Always layout single-line editors with a fixed height
* Preserve directory chevron when editing folder names
* Allow theming the filename editor

Co-authored-by: Antonio Scandurra <me@as-cii.com>
2022-05-04 10:28:44 -07:00
Max Brunsfeld dc0937e936 Implement Rename command in project panel 2022-05-04 10:28:09 -07:00
Max Brunsfeld dbfbd352f0 Implement basic AddFile command in project panel 2022-05-04 10:28:09 -07:00
Max Brunsfeld a95bc19817 Abstract more local project setup inside Project::test helper 2022-05-04 10:28:09 -07:00
Max Brunsfeld c38cdd92ee Clean up project panel theme 2022-05-04 10:28:08 -07:00
Antonio Scandurra 823f34556b Sort (case-insensitive) directories before files 2022-04-21 15:08:45 +02:00
Antonio Scandurra 55d4d44865 Store visible entries in project panel by id rather than offset 2022-04-21 13:37:57 +02:00
Max Brunsfeld 8bc0050578 Load all keybindings from JSON file 2022-04-10 14:29:45 -07:00
Max Brunsfeld 0908a8799c Allow actions to be deserialized from JSON
Introduce separate macro for implementing 'internal' actions which
are not intended to be loaded from keymaps.
2022-04-08 15:47:51 -07:00
0cf9925cb1 Restructure action macro to assign a namespace to every action
Also, allow arbitrary types to be used as Actions via the impl_actions macro

Co-authored-by: Nathan Sobo <nathan@zed.dev>
Co-authored-by: Keith Simmons <keith@zed.dev>
2022-04-07 16:20:49 -07:00
Max BrunsfeldandKeith Simmons dce66e6f9e Move Settings to its own crate
Co-authored-by: Keith Simmons <keith@zed.dev>
2022-04-06 10:23:33 -07:00
Antonio ScandurraandNathan Sobo e158b79115 Rename app_state to global in gpui
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-03-17 14:33:01 +01:00
29ab1f30bc Replace ProjectEntry struct with ProjectEntryId
Previously, we tracked the worktree_id and entry_id separately, but now that entry ids are unique across all worktrees this is unnecessary.

Co-Authored-By: Max Brunsfeld <maxbrunsfeld@gmail.com>
Co-Authored-By: Keith Simmons <keith@the-simmons.net>
2022-03-16 15:59:47 -06:00
Max Brunsfeld d2a4b6888c Store settings as a global via a gpui app_state 2022-03-11 15:58:58 -08:00
Antonio Scandurra 3ad7272559 Merge pull request #525 from zed-industries/preserve-worktrees
Grow worktrees monotonically when sharing and move most messages to the background
2022-03-04 09:48:18 +01:00
Max Brunsfeld 3a1a9ecb45 Disable doctests for all libraries
We don't use them, and they add a lot of noise to the test output
when running all tests in the workspace.
2022-03-03 16:15:56 -08:00
Antonio ScandurraandMax Brunsfeld 819bf72dfc Rename weak to visible
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2022-03-02 14:38:16 -08:00
Antonio ScandurraandNathan Sobo 3e3e28a831 Forbid parking in project_panel::tests::test_visible_list
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-03-01 17:14:18 +01:00
Antonio Scandurra 79568c471a Pass a reference to TestAppContext in tests
This allows us to drop the context *after* we ran all futures to
completion and that's crucial otherwise we'll never drop entities
and/or flush effects.
2022-03-01 12:01:02 +01:00
Max Brunsfeld 0da0b2611e Automatically include current view id in element state ids 2022-02-17 13:44:46 -08:00
Max BrunsfeldandAntonio Scandurra 705efeb013 Fix non-unique ids passed to MouseEventHandlers
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
2022-02-17 09:44:02 -08:00
Max BrunsfeldandNathan Sobo 4b081bd128 Use Rust 2021 edition in all crates
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-26 12:50:31 -08:00
Antonio Scandurra 41100c4439 Make add_local_worktree private and use find_or_create_local_worktree
The former always adds a worktree, even if we have one already in the
project and that could be misused. The public API should always search
for a local worktree containing the requested path first so that the
project can uphold invariants about which worktrees it has.
2022-01-22 11:23:00 +01:00
Antonio Scandurra ba96ca0b1b Remove weak worktrees from project when nobody references them
Also, avoid showing them in the project panel as well as in the
contacts panel.
2022-01-21 14:34:14 +01:00
e1bf476b29 Add select_first and select_last bindings to outline view
Co-Authored-By: Antonio Scandurra <me@as-cii.com>
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-14 10:45:37 -08:00
6372b5908e Center the selected item when updating outline query
Co-Authored-By: Max Brunsfeld <max@zed.dev>
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-14 17:53:06 +01:00
Max Brunsfeld 099f769a12 Remove stray dbg! calls 2022-01-11 13:56:07 -08:00
Antonio ScandurraandNathan Sobo c28fd392cb Refactor opening workspace items
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-07 17:38:37 +01:00
Antonio ScandurraandNathan Sobo 7ebeddd2c2 WIP: Add keybinding to open buffers under cursors
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
2022-01-07 16:12:50 +01:00
Max Brunsfeld f06eef084f Introduce a WorktreeId struct, fix incorrect use of remote worktrees' handle id 2022-01-04 11:28:44 +01:00
Antonio Scandurra 57444fed31 Get more integration tests passing 2021-12-21 09:50:11 +01:00