public static class ButtonPanel.Builder extends Object
Constructor and Description |
---|
Builder() |
Modifier and Type | Method and Description |
---|---|
ButtonPanel.Builder |
add(String text,
int size,
Runnable action)
Adds a button with the given text, width, and action.
|
ButtonPanel.Builder |
add(String text,
Runnable action)
Adds a button with the given text and action, as well as the default width.
|
ButtonPanel |
build(Composite parent)
Creates a button panel on the given Composite.
|
LayoutsGridData |
buildOnGrid(Composite parent)
Creates a button panel on the given Composite, and returns a LayoutsGridData for manipulating it.
|
ButtonPanel.Builder |
leftSide(Coat coat)
Adds an OK button.
|
ButtonPanel.Builder |
ok(Runnable ok)
Adds an OK button.
|
ButtonPanel.Builder |
okCancel(Consumer<Boolean> okClicked)
Adds an OK and Cancel button.
|
ButtonPanel.Builder |
okCancel(Runnable ok,
Runnable cancel)
Adds an OK and Cancel button.
|
public ButtonPanel.Builder leftSide(Coat coat)
public ButtonPanel.Builder ok(Runnable ok)
public ButtonPanel.Builder okCancel(Runnable ok, Runnable cancel)
public ButtonPanel.Builder okCancel(Consumer<Boolean> okClicked)
public ButtonPanel.Builder add(String text, Runnable action)
public ButtonPanel.Builder add(String text, int size, Runnable action)
public ButtonPanel build(Composite parent)
public LayoutsGridData buildOnGrid(Composite parent)