Nathan Sobo
afd89b256a
Store AnyWindowHandles instead of usizes
2023-08-08 16:06:53 -06:00
Nathan Sobo
0a4633f88f
Remove more window id usage
2023-08-08 11:20:09 -06:00
Nathan Sobo
d896d89842
Store an AnyWindowHandle in WindowContext
2023-08-08 11:08:37 -06:00
Nathan Sobo
f0da6b05fd
Remove TestAppContext::add_view
...
Instead, we now call this on window handles.
2023-08-07 22:46:48 -06:00
Nathan Sobo
0f332238b3
Remove unused method
2023-08-07 22:08:44 -06:00
Nathan Sobo
f2be3181a9
Move window-related methods from TestAppContext to AnyWindowHandle
2023-08-07 20:23:04 -06:00
Nathan Sobo
0197d49230
Move activation simulation to AnyWindowHandle
2023-08-07 19:45:43 -06:00
Nathan Sobo
486f5bc6ca
Get compiling
2023-08-07 19:08:58 -06:00
Nathan Sobo
3e0d0e5c01
WIP
2023-08-07 13:54:47 -06:00
Nathan Sobo
d4d32611fe
WIP
2023-08-06 18:57:02 -06:00
Nathan Sobo
adc50469ff
WIP
2023-08-06 12:45:31 -06:00
Nathan Sobo
dcf8b00656
WIP
2023-08-05 18:00:44 -06:00
Nathan Sobo
b6110fed9e
WIP
2023-08-04 07:56:20 -06:00
Nathan Sobo
379652f074
Merge branch 'main' into cells
2023-08-03 19:33:04 -06:00
Nathan Sobo
485c0a482e
Don't refcount window handles
2023-08-03 17:11:47 -06:00
Nathan Sobo
afcc0d621b
WIP
2023-08-03 17:03:39 -06:00
Nathan Sobo
3c938a7377
WIP
2023-08-03 08:10:16 -06:00
Nathan Sobo
884cee6dfd
Get tests compiling returning WindowHandle<V: View> from add_window
2023-08-02 14:05:03 -06:00
Nathan Sobo
300ce61bd0
WIP
2023-08-02 08:25:40 -06:00
Nathan Sobo
b695c42e11
WIP: Return WindowHandle<V: View> from AppContext::add_window
2023-08-01 22:28:04 -06:00
Nathan Sobo
1dfde8eab5
WIP
2023-08-01 20:53:15 -06:00
Nathan Sobo
4d66c3237d
WIP
2023-07-28 15:01:45 -06:00
Nathan Sobo
239024acd6
WIP
2023-07-27 23:26:12 -06:00
Nathan Sobo
480401d65d
WIP
2023-07-27 18:23:23 -06:00
Nathan Sobo
ab8906551d
WIP
2023-07-26 22:37:59 -06:00
Nathan Sobo
c48d8af204
Merge branch 'paint-context' into cells
2023-07-25 17:36:05 -06:00
Nathan Sobo
1b03c5d69c
Pass PaintContext to Element::paint
...
I want to use this on another branch, but it's a sweeping change,
so this prepares the ground for it. This can always be reverted if
it doesn't work out.
2023-07-25 17:32:31 -06:00
Mikayla Maki
429a2fc623
Add drag end events
...
Fix left dragging cascade
WIP: Implement right dragging, WIP: use drag end events to set and reset state around initial flex orientation
2023-07-23 13:28:30 -07:00
Kirill Bulatov and Max Brunsfeld
a4bf19c5bd
Simplify NoAction filtering logic
...
co-authored-by: Max Brunsfeld <max@zed.dev >
2023-07-17 20:42:35 +03:00
Kirill Bulatov
eaa8224076
Use id instead of type_id for actions
...
Currently, both are the same thing, so the logic is not changed.
2023-07-17 12:24:56 +03:00
Nathan Sobo and Derek Briggs
248f5dfd4b
Get a red box on screen
...
Co-Authored-By: Derek Briggs <derek.briggs@me.com >
2023-07-14 17:03:07 -06:00
Mikayla Maki
26b9be628e
Add the math for pane resizing
2023-07-12 22:35:51 -07:00
Nate Butler
76873c508a
Z-2276/Z-2275: Project & Branch switchers ( #2662 )
...
This PR adds project and branch switchers in top left corner.
Release Notes:
- Added a project & branch switcher under project name.
2023-07-05 13:09:40 -04:00
Piotr Osiewicz and Antonio
85add260f6
Track regions instead of clicks.
...
Get rid of superfluous params in RenderParams related to hover & click state.
Co-authored-by: Antonio <antonio@zed.dev >
2023-07-05 16:48:52 +02:00
Piotr Osiewicz and Antonio
cc88bff1ff
Fix click-through behaviour of git panel
...
Co-authored-by: Antonio <antonio@zed.dev >
2023-07-05 15:25:33 +02:00
Antonio Scandurra
25564ea058
Introduce a WindowContext::focus method that implies the window id
2023-07-05 09:39:04 +02:00
Kirill Bulatov and Mikayla Maki
4c51ab8a25
Accept null as a valid action, to disable a keystroke
...
co-authored-by: Mikayla Maki <mikayla@zed.dev >
2023-07-04 21:11:28 +03:00
Mikayla Maki
6ffa6afd20
fmt
2023-06-28 16:35:57 -07:00
Mikayla Maki
e0d618862c
Add click out handler
...
Make all context menus on button click toggles instead of re-shows
2023-06-28 16:23:07 -07:00
Mikayla Maki
18dd3102bf
WIP: Add click out event to fix context menus
2023-06-28 09:29:49 -07:00
Piotr Osiewicz
2a3c660d1f
settings: accept trailing commas ( #2606 )
...
Z-2357
I've found a crate that handles both comments and trailing commas in
JSON. It is a fork of `serde_json`, but it is maintained & up-to-date.
Sadly RawValue seems to not play nicely with it; I've ran into
deserialisation issues around use of RawValue. For this PR I've migrated
to `Value` API.
Obviously this is just a point of discussion, not something I'd merge
straight away. There may be better solutions to this particular problem.
I've also noticed that `serde_json_lenient` does not handle trailing
commas after bindings array. I'm not sure how big of an issue that is.
Release Notes:
- Improved handling of trailing commas in settings files.
[#1322 ](https://github.com/zed-industries/community/issues/1322 )
2023-06-19 18:29:03 +02:00
Antonio Scandurra
c872f581d1
Query rect_for_text_range on focused view instead of root element
...
This was causing IME input to be drawn in the wrong place when there
were splits or panels in the window.
2023-06-05 12:00:40 +02:00
Max Brunsfeld
2db57b5139
Adjust diagnostic transformation test to not wait for two buffer notifications
2023-05-26 15:47:37 -07:00
Max Brunsfeld
66b3be8687
Make toggle dock actions appear in the command palette
2023-05-24 09:58:41 -07:00
Antonio Scandurra
146809eef0
Merge branch 'main' into panels
2023-05-22 14:10:17 +02:00
Kirill Bulatov
583b15badc
When the file is deleted via project panel, close it in editors
2023-05-19 18:52:30 +03:00
Antonio Scandurra
747fbfadeb
Notify old/new ancestors of the focused view when they change
2023-05-17 17:12:12 +02:00
Antonio Scandurra
da19edc3e3
Merge branch 'main' into implicit-ancestry
2023-05-04 14:39:58 +02:00
Antonio Scandurra
3d679ddb26
Avoid re-allocating KeymapContext after every view notification
2023-05-04 12:04:30 +02:00
Antonio Scandurra
18e39ef2fa
Cache view's type id and keymap context into a separate map
...
During `layout`, we now pass a mutable reference to the element's
parent view. This is a recursive process that causes the view to
be removed from `AppContext` and then re-inserted back into it once
the layout is complete.
As such, querying parent views during `layout` does not work as such
views will have been removed from `AppContext` and not yet re-inserted
into it. This caused a bug in `KeystrokeLabel`, which used the `keystrokes_for_action`
method to query its ancestors to determine their type id and keymap context.
Now, any time a view notifies, we will cache its keymap context so that
we don't need to query the parent view during `layout`.
2023-05-04 10:47:56 +02:00