本文整理了Java中com.google.gwt.dom.client.Element.setDraggable()
方法的一些代码示例,展示了Element.setDraggable()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Element.setDraggable()
方法的具体详情如下:
包路径:com.google.gwt.dom.client.Element
类名称:Element
方法名:setDraggable
[英]Changes the draggable attribute to one of #DRAGGABLE_AUTO, #DRAGGABLE_FALSE, or #DRAGGABLE_TRUE.
[中]将draggable属性更改为#draggable_AUTO、#draggable_FALSE或#draggable_TRUE中的一个。
代码示例来源:origin: com.google.gwt/gwt-servlet
@Override
public R draggable(String draggable) {
assertCanAddAttribute().setDraggable(draggable);
return getReturnBuilder();
}
代码示例来源:origin: com.vaadin.external.gwt/gwt-user
@Override
public R draggable(String draggable) {
assertCanAddAttribute().setDraggable(draggable);
return getReturnBuilder();
}
代码示例来源:origin: net.wetheinter/gwt-user
@Override
public R draggable(String draggable) {
assertCanAddAttribute().setDraggable(draggable);
return getReturnBuilder();
}
代码示例来源:origin: com.haulmont.cuba/cuba-web-toolkit
@Override
protected void removeDraggable(Element element) {
if (getDragSourceWidget() instanceof TableWidget) {
TableWidget widget = (TableWidget) getDragSourceWidget();
List<Widget> list = widget.getRenderedRows();
for (Widget row : list) {
Element rowElement = row.getElement();
rowElement.setDraggable(Element.DRAGGABLE_FALSE);
String primaryDragSourceStyle = getStylePrimaryName(getDraggableElement()) + STYLE_SUFFIX_DRAGSOURCE;
rowElement.removeClassName(primaryDragSourceStyle);
rowElement.removeClassName(getStyleNameDraggable());
}
}
}
代码示例来源:origin: com.haulmont.cuba/cuba-web-toolkit
protected void initDraggableRows() {
TableWidget tableWidget = getTableWidget();
if (tableWidget != null) {
List<Widget> list = tableWidget.getRenderedRows();
for (Widget row : list) {
Element rowElement = row.getElement();
rowElement.setDraggable(Element.DRAGGABLE_TRUE);
String primaryDragSourceStyle = getStylePrimaryName(getDraggableElement()) + STYLE_SUFFIX_DRAGSOURCE;
if (!isElementContainsClass(rowElement, primaryDragSourceStyle)) {
rowElement.addClassName(primaryDragSourceStyle);
}
if (!isElementContainsClass(rowElement, getStyleNameDraggable())) {
rowElement.addClassName(getStyleNameDraggable());
}
}
}
}
内容来源于网络,如有侵权,请联系作者删除!