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
This commit is contained in:
parent
b136d21ebf
commit
90f4c70a82
69 changed files with 271 additions and 271 deletions
|
@ -785,7 +785,7 @@ impl Render for LspLogToolbarItemView {
|
|||
{
|
||||
let log_toolbar_view = log_toolbar_view.clone();
|
||||
move |cx| {
|
||||
h_stack()
|
||||
h_flex()
|
||||
.w_full()
|
||||
.justify_between()
|
||||
.child(Label::new(RPC_MESSAGES))
|
||||
|
@ -837,7 +837,7 @@ impl Render for LspLogToolbarItemView {
|
|||
.into()
|
||||
});
|
||||
|
||||
h_stack().size_full().child(lsp_menu).child(
|
||||
h_flex().size_full().child(lsp_menu).child(
|
||||
div()
|
||||
.child(
|
||||
Button::new("clear_log_button", "Clear").on_click(cx.listener(
|
||||
|
|
|
@ -9,7 +9,7 @@ use language::{Buffer, OwnedSyntaxLayerInfo};
|
|||
use std::{mem, ops::Range};
|
||||
use theme::ActiveTheme;
|
||||
use tree_sitter::{Node, TreeCursor};
|
||||
use ui::{h_stack, popover_menu, ButtonLike, Color, ContextMenu, Label, LabelCommon, PopoverMenu};
|
||||
use ui::{h_flex, popover_menu, ButtonLike, Color, ContextMenu, Label, LabelCommon, PopoverMenu};
|
||||
use workspace::{
|
||||
item::{Item, ItemHandle},
|
||||
SplitDirection, ToolbarItemEvent, ToolbarItemLocation, ToolbarItemView, Workspace,
|
||||
|
@ -239,7 +239,7 @@ impl SyntaxTreeView {
|
|||
|
||||
fn render_node(cursor: &TreeCursor, depth: u32, selected: bool, cx: &AppContext) -> Div {
|
||||
let colors = cx.theme().colors();
|
||||
let mut row = h_stack();
|
||||
let mut row = h_flex();
|
||||
if let Some(field_name) = cursor.field_name() {
|
||||
row = row.children([Label::new(field_name).color(Color::Info), Label::new(": ")]);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue