Marshall Bowers
2bfc646f33
Enable clippy::filter_map_identity
( #8741 )
...
This PR enables the
[`clippy::filter_map_identity`](https://rust-lang.github.io/rust-clippy/master/index.html#/filter_map_identity )
rule and fixes the outstanding violations.
Release Notes:
- N/A
2024-03-02 20:48:29 -05:00
Kirill Bulatov
3efb871cd4
Add a way to change what menu::Confirm
does in the recent projects modal ( #8688 )
...
Follow-up of
https://github.com/zed-industries/zed/issues/8651#issuecomment-1973411072
Zed current default is still to reuse the current window, but now it's
possible to do
```json
"alt-cmd-o": [
"projects::OpenRecent",
{
"create_new_window": true
}
]
```
and change this.
menu::Secondary confirm does the action with opposite window creation
strategy.
Release Notes:
- Improved open recent projects flexibility: settings can change whether
`menu::Confirm` opens a new window or reuses the old one
2024-03-02 00:28:51 +02:00
Kirill Bulatov
cdf702aeff
Prompt to save files on recent project selection ( #8673 )
2024-03-01 18:48:06 +02:00
Jason Lee
47bcb305af
Use Pointer
cursor style on Recent Projects, VCS Menu. ( #8595 )
...
Release Notes:
- Improved to use `Pointer` style cursor on VCS and Recent Projects
menu.
https://github.com/zed-industries/zed/assets/5518/4f638c6a-00b8-4fa8-b469-4d3109827bc2
2024-02-29 12:27:56 +01:00
Kirill Bulatov
ac30ded80e
Allow .zed/tasks.json local configs ( #8536 )
...

Follow-up of
https://github.com/zed-industries/zed/issues/7108#issuecomment-1960746397
Makes more clear where each task came from, auto (re)load
.zed/config.json changes, properly filtering out other worktree tasks.
Release Notes:
- Added local task configurations
2024-02-29 01:18:13 +02:00
Kirill Bulatov
a0c8debd35
Mention possible run options in the task modal placeholder ( #8449 )
...
Release Notes:
- Improved run task modal's placeholder
---------
Co-authored-by: Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com>
2024-02-27 00:04:56 +02:00
Kirill Bulatov
16d826a3f4
Show keybindings instead of the action names in the recent project modal
2024-02-25 00:08:57 +02:00
Kirill Bulatov
c29ea9bdbc
Allow using context in the placeholder_text
method
2024-02-25 00:08:57 +02:00
Kirill Bulatov
71557f3eb3
Adjust "recent projects" modal behavior to allow opening projects in both current and new window ( #8267 )
...

Fixes https://github.com/zed-industries/zed/issues/7419 by changing the
way "recent projects" modal confirm actions work:
* `menu::Confirm` now reuses the current window when opening a recent
project
* `menu::SecondaryConfirm` now opens a recent project in the new window
* neither confirm tries to open the current project anymore
* modal's placeholder is adjusted to emphasize this behavior
Release Notes:
- Added a way to open recent projects in the new window
2024-02-23 13:17:31 +02:00
Tung Hoang
f930969411
Allow removing workspaces from the "recent projects" modal ( #7885 )
...
<img width="492" alt="Screenshot 2024-02-19 at 10 59 01 AM"
src="https://github.com/zed-industries/zed/assets/1823955/922117f6-81c1-409d-938a-131bcec0f24c ">
<img width="675" alt="Screenshot 2024-02-19 at 10 59 27 AM"
src="https://github.com/zed-industries/zed/assets/1823955/fefac68b-9a99-43bb-ac0c-724e7c622455 ">
Release Notes:
- Added a way to remove entries from the recent projects modal
([7426](https://github.com/zed-industries/zed/issues/7426 )).
2024-02-22 01:30:02 +02:00
Bennet Bo Fenner
c33efe8cd0
recent projects: cleanup ui ( #7528 )
...
As the ui for the file finder was recently changed in #7364 , I think it
makes sense to also update the ui of the recent projects overlay.
Before:

After:

Release Notes:
- Improved UI of recent project overlay
2024-02-19 14:37:52 +02:00
Mikayla
57400e9687
Fix typos detected by crate-ci/typos
2024-01-17 14:31:21 -08:00
Marshall Bowers
90f4c70a82
Rename h_stack
and v_stack
to h_flex
and v_flex
, respectively ( #4053 )
...
This PR renames the `h_stack` and `v_stack` to `h_flex` and `v_flex`,
respectively.
We were previously using `h_stack` and `v_stack` to match SwiftUI, but
`h_flex` and `v_flex` fit better with the web/flexbox terminology that
the rest of GPUI uses.
Additionally, we were already calling the utility functions used to
implement `h_stack` and `v_stack` by the new names.
Release Notes:
- N/A
2024-01-15 11:34:06 -05:00
Max Brunsfeld
292b3397ab
Remove 2 suffix for language selector, project panel, recent_projects, copilot_button, breadcrumbs, activity_indicator
...
Co-authored-by: Mikayla <mikayla@zed.dev>
2024-01-03 10:47:33 -08:00
Joseph T. Lyons
ee1b4a52cc
Add PathExt
trait ( #2823 )
...
This PR adds a `PathExt` trait. It pulls in our existing `compact()`
function, as a method, and then adds a method, and testing, for
`icon_suffix()`. A test was added to fix:
- https://github.com/zed-industries/community/issues/1877
Release Notes:
- Fixed a bug where file icons would not be registered for files with
with `.` characters in their name
([#1877 ](https://github.com/zed-industries/community/issues/1877 )).
2023-08-03 18:57:43 -04:00
Alex Viscreanu
c7669317ec
feat(workspace): allow alternative actions to open files and symbols in split
...
Co-authored-by: Mikayla Maki <mikayla@zed.dev>
2023-07-14 21:49:15 +02:00
Piotr Osiewicz
15010e94fd
fixup! recent_projects: Perform fuzzy search on compacted paths.
2023-07-11 15:29:15 +02:00
Piotr Osiewicz
f164eb5289
recent_projects: Perform fuzzy search on compacted paths.
...
Match highlighting for recent projects picker was off, because the path representation was compacted - for a path '/Users/hiro/Projects/zed' we compact it to use a tilde instead of home directory. However, the highlight positions were always calculated for a full path, leading to a mismatch in highlights.
This commit addresses this by running fuzzy search on compacted paths instead of using long paths. This might lead to a slight performance hit, but given that recent projects modal shouldn't have that many items in the first place, it should be okay.
Z-2546
2023-07-11 15:23:17 +02:00
Piotr Osiewicz
0e0d78df84
Do not render recent paths in toolbar's project switcher
2023-07-05 18:04:40 +02:00
Piotr Osiewicz
081e340d26
Do not query db on foreground thread.
...
Co-authored-by: Mikayla <mikayla@zed.dev>
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
888d3b3fd6
Project dropdown menu
2023-06-30 14:05:55 +02:00
Piotr Osiewicz
e92015b12f
Split out Interactive<T> into Toggle<T> and Interactive<T>
2023-06-20 16:05:20 -07:00
Max Brunsfeld
67a25126d4
Define theme/ui text style settings in theme crate
2023-05-17 14:44:59 -07:00
Antonio Scandurra
c4472b0786
Remove ViewContext::dispatch_action
2023-05-01 16:27:36 +02:00
Antonio Scandurra
d815fc88ae
Remove ViewContext::dispatch_any_action
2023-05-01 14:24:00 +02:00
Antonio Scandurra
06c01a5937
Eliminate OpenPaths global action for workspace and replace with methods
...
We no longer want to invoke this with dispatch_action.
2023-04-27 18:36:28 -06:00
Nathan Sobo
fe492eacbf
Refine naming of element-related types and traits
...
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2023-04-21 13:06:37 -06:00
Antonio Scandurra
03619dfa55
Rename Drawable::boxed to into_element and make containers generic
...
Multi-element are now generic over any drawable child, which can be converted
into an element.
Co-Authored-By: Nathan Sobo <nathan@zed.dev>
Co-Authored-By: Max Brunsfeld <max@zed.dev>
2023-04-21 12:43:19 -06:00
Antonio Scandurra
c52b6328b7
Merge branch 'main' into window_context_2
2023-04-20 16:01:47 +02:00
Antonio Scandurra
e282c7ad45
Finish converting all the pickers to the new API
2023-04-20 15:26:05 +02:00
Nathan Sobo
d70644618a
WIP: Make PickerDelegate a fully owned object instead of a view
...
This avoids issues with the parent view being on the stack when we want to
interact with the delegate from the picker. Still have several picker usages
to convert.
2023-04-19 22:05:29 -06:00
Max Brunsfeld
7cc868bc8c
When opening projects, only reuse the current window if it is empty
2023-04-18 17:05:26 -07:00
Antonio Scandurra
d03c431f9a
Fix warnings/errors now that AsyncAppContext::update
returns Result
2023-04-18 14:58:57 +02:00
Nathan Sobo
a25f962185
WIP
2023-04-12 12:13:35 -06:00
Nathan Sobo
868301bedb
WIP
2023-04-12 10:07:17 -06:00
Nathan Sobo
e115baa60c
WIP
2023-04-11 18:21:56 -06:00
Nathan Sobo
8136d8a8a6
Fix formatting
2023-04-06 15:54:44 -06:00
Nathan Sobo
de9bf6dfbd
Merge MutableAppContext into AppContext
...
There may have been a good reason for the difference at some point, or I was
still learning Rust. But now it's just &mut AppContext vs &AppContext.
2023-04-06 15:49:03 -06:00
Nathan Sobo
82a713fd1d
Store AnyViewHandle inside ViewHandle and Deref to it
2023-04-02 14:59:55 -06:00
Mikayla Maki
097a768725
Remove panic in recent projects picker
2023-03-13 09:44:42 -07:00
Kay Simmons
b020955ac4
show notification if no recent projects
2023-02-07 00:10:11 -08:00
Mikayla Maki
ca2e0256e1
Renamed open recent action to match menu
2023-01-27 15:38:48 -08:00
Julia
09d57d1f26
Prefer first max while fuzzy matching projects fixes unexpected behavior
2023-01-05 11:27:50 -05:00
Kay Simmons
2c47bd4a97
Clear stale projects if they no longer exist
2022-12-16 15:45:17 -08:00
Kay Simmons
2bc685281c
Add recent project picker
2022-12-14 15:59:50 -08:00