Background: Make menu fields variable width

This commit is contained in:
John Scipione
2014-04-24 17:14:29 -04:00
parent d154bfb517
commit fd849a28d9
@@ -189,14 +189,21 @@ BackgroundsView::BackgroundsView()
new BMessage(kMsgUpdateColor)); new BMessage(kMsgUpdateColor));
rightbox->AddChild(BLayoutBuilder::Group<>(B_VERTICAL) rightbox->AddChild(BLayoutBuilder::Group<>(B_VERTICAL)
.AddGrid(B_USE_DEFAULT_SPACING, B_USE_SMALL_SPACING) .AddGroup(B_HORIZONTAL, 0.0f)
.Add(imageMenuField->CreateLabelLayoutItem(), 0, 0) .AddGrid(B_USE_DEFAULT_SPACING, B_USE_SMALL_SPACING)
.Add(imageMenuField->CreateMenuBarLayoutItem(), 1, 0, 2, 1) .Add(imageMenuField->CreateLabelLayoutItem(), 0, 0)
.Add(placementMenuField->CreateLabelLayoutItem(), 0, 1) .AddGroup(B_HORIZONTAL, 0.0f, 1, 0)
.Add(placementMenuField->CreateMenuBarLayoutItem(), 1, 1, 2, 1) .Add(imageMenuField->CreateMenuBarLayoutItem(), 0.0f)
.Add(fIconLabelOutline, 1, 2) .AddGlue()
// checkbox only spans one column so that it .End()
// doesn't dictate the width of the menu bars. .Add(placementMenuField->CreateLabelLayoutItem(), 0, 1)
.AddGroup(B_HORIZONTAL, 0.0f, 1, 1)
.Add(placementMenuField->CreateMenuBarLayoutItem(), 0.0f)
.AddGlue()
.End()
.Add(fIconLabelOutline, 1, 2)
.End()
.AddGlue()
.End() .End()
.AddGlue() .AddGlue()
.Add(fPicker) .Add(fPicker)