本文整理汇总了Java中com.google.gwt.dom.client.Style.setDisplay方法的典型用法代码示例。如果您正苦于以下问题:Java Style.setDisplay方法的具体用法?Java Style.setDisplay怎么用?Java Style.setDisplay使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类com.google.gwt.dom.client.Style
的用法示例。
在下文中一共展示了Style.setDisplay方法的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: setPresentationsMenu
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
public void setPresentationsMenu(Widget presentationsMenu) {
if (_delegate.presentationsMenu != presentationsMenu) {
Style presentationsIconStyle = ((CubaTreeTableTableHead) tHead).presentationsEditIcon.getElement().getStyle();
if (presentationsMenu == null) {
presentationsIconStyle.setDisplay(Style.Display.NONE);
} else {
presentationsIconStyle.setDisplay(Style.Display.BLOCK);
}
}
_delegate.presentationsMenu = presentationsMenu;
}
示例2: setPresentationsMenu
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
public void setPresentationsMenu(Widget presentationsMenu) {
if (_delegate.presentationsMenu != presentationsMenu) {
Style presentationsIconStyle = ((CubaScrollTableHead) tHead).presentationsEditIcon.getElement().getStyle();
if (presentationsMenu == null) {
presentationsIconStyle.setDisplay(Style.Display.NONE);
} else {
presentationsIconStyle.setDisplay(Style.Display.BLOCK);
}
}
_delegate.presentationsMenu = presentationsMenu;
}
示例3: CubaSuggestPopup
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
public CubaSuggestPopup() {
Style style = loadingImage.getElement().getStyle();
style.clearWidth();
style.clearHeight();
style.setDisplay(Style.Display.BLOCK);
}
示例4: setCollapsable
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
public void setCollapsable(boolean collapsable) {
Style expanderStyle = expander.getStyle();
if (collapsable) {
expanderStyle.clearProperty("display");
removeStyleDependentName("nocollapsable");
} else {
addStyleDependentName("nocollapsable");
expanderStyle.setDisplay(Style.Display.NONE);
}
Tools.textSelectionEnable(captionNode, !collapsable);
this.collapsable = collapsable;
}
示例5: execute
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
@Override
public void execute() {
Style style = menuButtonContainer.getElement().getStyle();
if (resizeButtonVisible) {
style.setDisplay(Display.BLOCK);
} else {
style.setDisplay(Display.NONE);
}
}
示例6: kickWebkit
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
private static void kickWebkit(Element element) {
if (UserAgent.isWebkit()) {
Style style = element.getStyle();
String oldDisplay = style.getDisplay();
// Erase layout. Querying getOffsetParent() forces layout.
style.setDisplay(Display.NONE);
element.getOffsetParent();
// Restore layout.
style.setProperty("display", oldDisplay);
}
}
示例7: show
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
@Override
public void show() {
Style style = getElement().getStyle();
style.setDisplay(Display.BLOCK);
}
示例8: hide
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
@Override
public void hide() {
Style style = getElement().getStyle();
style.setDisplay(Display.NONE);
}
示例9: drawRow
import com.google.gwt.dom.client.Style; //导入方法依赖的package包/类
@Override
public TableRow drawRow(DataView<T> dataView, RowComponent<T> rowComponent, Object valueKey,
List<Column<T, ?>> columns, boolean redraw) {
T data = rowComponent.getData();
TableRow row = rowComponent.getWidget();
boolean draw = true;
if(row == null) {
// Create a new row element
row = new TableRow();
Style style = row.getElement().getStyle();
style.setDisplay(Display.NONE);
style.setProperty("height", getExpectedRowHeight() + "px");
style.setProperty("maxHeight", getExpectedRowHeight() + "px");
style.setProperty("minHeight", getExpectedRowHeight() + "px");
row.setStyleName(TableCssName.DATA_ROW);
rowComponent.setWidget(row);
if(!dataView.getSelectionType().equals(SelectionType.NONE)) {
TableData selection = drawSelectionCell();
row.add(selection);
}
} else if(!redraw && !rowComponent.isRedraw()) {
draw = false;
}
if(draw) {
// Build the columns
int colOffset = dataView.getColumnOffset();
int colSize = columns.size();
for(int c = 0; c < colSize; c++) {
int colIndex = c + colOffset;
Context context = new Context(rowComponent.getIndex(), colIndex, valueKey);
drawColumn(row, context, data, columns.get(c), colIndex, dataView.isHeaderVisible(colIndex));
}
rowComponent.setRedraw(false);
}
if(dataView.isUseRowExpansion()) {
if(!row.hasExpansionColumn()) {
TableData expand = new TableData();
expand.setId("colex");
MaterialIcon expandIcon = new MaterialIcon();
expandIcon.setId("expand");
expandIcon.setWidth("100%");
expandIcon.setIconType(IconType.KEYBOARD_ARROW_DOWN);
expandIcon.setWaves(WavesType.LIGHT);
expandIcon.getElement().getStyle().setCursor(Cursor.POINTER);
expand.add(expandIcon);
row.add(expand);
}
} else if(row.hasExpansionColumn()) {
row.removeExpansionColumn();
}
Scheduler.get().scheduleDeferred(() -> {
calculateRowHeight(rowComponent);
});
return row;
}