本文整理了Java中com.google.gwt.user.client.Element.getOwnerDocument()
方法的一些代码示例,展示了Element.getOwnerDocument()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Element.getOwnerDocument()
方法的具体详情如下:
包路径:com.google.gwt.user.client.Element
类名称:Element
方法名:getOwnerDocument
暂无
代码示例来源:origin: org.kie.workbench.stunner/kie-wb-common-stunner-client-common
/**
* Gets the mouse x-position relative to the canvas element.
* @param clientX The event's clientX value.
* @return the relative x-position
*/
private double getRelativeX(final double clientX) {
return clientX - getCanvasElement().getAbsoluteLeft() + getCanvasElement().getScrollLeft() +
getCanvasElement().getOwnerDocument().getScrollLeft();
}
代码示例来源:origin: org.kie.workbench.stunner/kie-wb-common-stunner-client-common
/**
* Gets the mouse y-position relative to the canvas element.
* @param clientY The event's clienty value.
* @return the relative y-position
*/
private double getRelativeY(final double clientY) {
return clientY - getCanvasElement().getAbsoluteTop() + getCanvasElement().getScrollTop() +
getCanvasElement().getOwnerDocument().getScrollTop();
}
代码示例来源:origin: gwt-test-utils/gwt-test-utils
@PatchMethod
static PotentialElement build(UIObject o, String tagName) {
PotentialElement e = JsoUtils.newNode(Node.ELEMENT_NODE).cast();
Element wrappedElement = JsoUtils.newElement(tagName, o.getElement().getOwnerDocument());
JavaScriptObjects.setProperty(e, POTENTIALELEMENT_TAG, true);
JavaScriptObjects.setProperty(e, POTENTIALELEMENT_WRAPPED_ELEMENT, wrappedElement);
JavaScriptObjects.setProperty(e, POTENTIALELEMENT_UIOBJECT, o);
return e;
}
代码示例来源:origin: com.googlecode.gwt-test-utils/gwt-test-utils
@PatchMethod
static PotentialElement build(UIObject o, String tagName) {
PotentialElement e = JsoUtils.newNode(Node.ELEMENT_NODE).cast();
Element wrappedElement = JsoUtils.newElement(tagName, o.getElement().getOwnerDocument());
JavaScriptObjects.setProperty(e, POTENTIALELEMENT_TAG, true);
JavaScriptObjects.setProperty(e, POTENTIALELEMENT_WRAPPED_ELEMENT, wrappedElement);
JavaScriptObjects.setProperty(e, POTENTIALELEMENT_UIOBJECT, o);
return e;
}
内容来源于网络,如有侵权,请联系作者删除!