use of com.haulmont.cuba.gui.components.ButtonsPanel in project cuba by cuba-platform.
the class DataGridLoader method createButtonsPanel.
protected void createButtonsPanel(HasButtonsPanel dataGrid, Element element) {
panelElement = element.element("buttonsPanel");
if (panelElement != null) {
ButtonsPanelLoader loader = (ButtonsPanelLoader) getLoader(panelElement, ButtonsPanel.NAME);
loader.createComponent();
ButtonsPanel panel = loader.getResultComponent();
dataGrid.setButtonsPanel(panel);
buttonsPanelLoader = loader;
}
}
use of com.haulmont.cuba.gui.components.ButtonsPanel in project cuba by cuba-platform.
the class TreeLoader method createButtonsPanel.
protected void createButtonsPanel(Tree resultComponent, Element element) {
buttonsPanelElement = element.element("buttonsPanel");
if (buttonsPanelElement != null) {
ButtonsPanelLoader loader = (ButtonsPanelLoader) getLoader(buttonsPanelElement, ButtonsPanel.NAME);
loader.createComponent();
ButtonsPanel panel = loader.getResultComponent();
resultComponent.setButtonsPanel(panel);
buttonsPanelLoader = loader;
}
}
use of com.haulmont.cuba.gui.components.ButtonsPanel in project cuba by cuba-platform.
the class TreeLoader method loadButtonsPanel.
protected void loadButtonsPanel(Tree component) {
if (buttonsPanelLoader != null) {
// noinspection unchecked
buttonsPanelLoader.loadComponent();
ButtonsPanel panel = (ButtonsPanel) buttonsPanelLoader.getResultComponent();
Window window = ComponentsHelper.getWindowImplementation(component);
String alwaysVisible = buttonsPanelElement.attributeValue("alwaysVisible");
panel.setVisible(!(window instanceof Window.Lookup) || "true".equals(alwaysVisible));
}
}
use of com.haulmont.cuba.gui.components.ButtonsPanel in project cuba by cuba-platform.
the class WidgetsTreeLoader method loadButtonsPanel.
protected void loadButtonsPanel(Tree component) {
if (buttonsPanelLoader != null) {
// noinspection unchecked
buttonsPanelLoader.loadComponent();
ButtonsPanel panel = (ButtonsPanel) buttonsPanelLoader.getResultComponent();
Window window = ComponentsHelper.getWindowImplementation(component);
String alwaysVisible = buttonsPanelElement.attributeValue("alwaysVisible");
panel.setVisible(!(window instanceof Window.Lookup) || "true".equals(alwaysVisible));
}
}
use of com.haulmont.cuba.gui.components.ButtonsPanel in project cuba by cuba-platform.
the class DataGridLoader method loadButtonsPanel.
protected void loadButtonsPanel(DataGrid component) {
if (buttonsPanelLoader != null) {
// noinspection unchecked
buttonsPanelLoader.loadComponent();
ButtonsPanel panel = (ButtonsPanel) buttonsPanelLoader.getResultComponent();
Window window = ComponentsHelper.getWindowImplementation(component);
String alwaysVisible = panelElement.attributeValue("alwaysVisible");
panel.setVisible(!(window instanceof Window.Lookup) || "true".equals(alwaysVisible));
}
}
Aggregations