use of org.jboss.errai.common.client.dom.HTMLElement in project kie-wb-common by kiegroup.
the class SourceConfigurationParamsView method defaultOption.
private HTMLElement defaultOption() {
final HTMLElement option = Window.getDocument().createElement("option");
option.setAttribute("value", "");
option.setAttribute("disabled", "");
option.setAttribute("selected", "");
option.setTextContent(translationService.getTranslation(SourceConfigurationPageView_SelectOption_placeholder));
return option;
}
use of org.jboss.errai.common.client.dom.HTMLElement in project kie-wb-common by kiegroup.
the class ShowAssetUsagesDisplayer method showAssetPartUsages.
/**
* Displays the usages for the asset part identified by the resourPart parameter using a specific message instead of the default message..
*
* @param headerMessage The message that will be shown instead of the default message
* @param path Path for the given asset
* @param resourceFQN Fully Qualified Name of the asset
* @param resourcePart The name of the part to search.
* @param partType The {@link PartType} that to search.
* @param okCommand {@link Command} that is going to run when the user presses ok button. If there are no usages on the index the command will be automatically executed without opening the modal
* @param cancelCommand {@link Command} that is going to run when the user presses Cancel button.
*/
public void showAssetPartUsages(final String headerMessage, final Path path, final String resourceFQN, final String resourcePart, final PartType partType, final Command okCommand, final Command cancelCommand) {
PortablePreconditions.checkNotNull("headerMessage", headerMessage);
HTMLElement messageContainer = view.getDefaultMessageContainer();
messageContainer.setInnerHTML(headerMessage);
showAssetPartUsages(messageContainer, path, resourceFQN, resourcePart, partType, okCommand, cancelCommand);
}
use of org.jboss.errai.common.client.dom.HTMLElement in project kie-wb-common by kiegroup.
the class DefinitionPaletteCategoryWidgetViewImpl method addGroup.
@Override
public void addGroup(DefinitionPaletteGroupWidget groupWidget) {
HTMLElement groupHeader = document.createElement("h5");
groupHeader.setTextContent(groupWidget.getItem().getTitle());
floatingPanel.appendChild(groupHeader);
floatingPanel.appendChild(groupWidget.getElement());
}
use of org.jboss.errai.common.client.dom.HTMLElement in project kie-wb-common by kiegroup.
the class ImageElementRendererViewImpl method resize.
private void resize(final int widthPx, final int heightPx) {
icon.getStyle().setProperty("width", widthPx + Style.Unit.PX.name());
icon.getStyle().setProperty("height", heightPx + Style.Unit.PX.name());
HTMLElement svgElement = (HTMLElement) DOMUtil.getFirstChildElement(icon).get();
if (svgElement != null) {
svgElement.getStyle().setProperty("width", widthPx + Style.Unit.PX.name());
svgElement.getStyle().setProperty("height", heightPx + Style.Unit.PX.name());
svgElement.getStyle().setProperty("position", "absolute");
svgElement.getStyle().setProperty("top", "0px");
svgElement.getStyle().setProperty("left", "0px");
}
}
use of org.jboss.errai.common.client.dom.HTMLElement in project kie-wb-common by kiegroup.
the class FormModelsViewImpl method render.
protected void render() {
DOMUtil.removeAllChildren(content);
creationViews.forEach(container -> {
HTMLElement row = document.createElement("div");
DOMUtil.addCSSClass(row, Styles.ROW);
HTMLElement col = document.createElement("div");
DOMUtil.addCSSClass(col, ColumnSize.MD_12.getCssName());
col.appendChild(container.getElement());
row.appendChild(col);
content.appendChild(row);
});
creationViews.get(0).selectManager();
}
Aggregations