本文整理了Java中com.google.gwt.user.client.ui.Widget.getAbsoluteTop()
方法的一些代码示例,展示了Widget.getAbsoluteTop()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Widget.getAbsoluteTop()
方法的具体详情如下:
包路径:com.google.gwt.user.client.ui.Widget
类名称:Widget
方法名:getAbsoluteTop
暂无
代码示例来源:origin: com.google.gwt/gwt-servlet
@Override
protected int getTargetPosition() {
return target.getAbsoluteTop();
}
代码示例来源:origin: com.google.gwt/gwt-servlet
@Override
public void handleDrag(int absX, int absY) {
Widget moveTarget = LoggingPopup.this;
RootPanel.get().setWidgetPosition(moveTarget,
moveTarget.getAbsoluteLeft() + absX,
moveTarget.getAbsoluteTop() + absY);
}
}
代码示例来源:origin: errai/errai
@Override
public int getTop() {
return source.getAbsoluteTop();
}
});
代码示例来源:origin: org.jboss.errai/errai-cordova
@Override
public int getTop() {
return source.getAbsoluteTop();
}
});
代码示例来源:origin: org.uberfire/uberfire-runtime-plugins-client
private int getContentAbsoluteTop() {
return contentArea.getAbsoluteTop();
}
}
代码示例来源:origin: stephenh/tessell
@Override
public int getAbsoluteTop() {
return delegate.getAbsoluteTop();
}
代码示例来源:origin: net.wetheinter/gwt-user
@Override
protected int getTargetPosition() {
return target.getAbsoluteTop();
}
代码示例来源:origin: de.esoco/gewt
/***************************************
* Returns the vertical position of the component's top edge.
*
* @return The y coordinate of the component location
*/
public int getY()
{
return getWidget().getAbsoluteTop();
}
代码示例来源:origin: info.magnolia.ui/magnolia-ui-vaadin-common-widgets
protected double getBaseOffset() {
return rows.get(0).getAbsoluteTop()
- rows.get(0).getParent().getAbsoluteTop()
- rows.size() * getRowHeight();
}
代码示例来源:origin: geogebra/geogebra
private int getY(TouchEvent<?> event) {
Touch touch = getRelevantTouch(event);
return touch == null ? 0
: (touch.getClientY() - widget.getAbsoluteTop());
}
代码示例来源:origin: GwtMaterialDesign/gwt-material
public static int calculateSpaceToBottom(Widget widget) {
return Window.getClientHeight() - widget.getAbsoluteTop() - widget.getOffsetHeight();
}
代码示例来源:origin: org.uberfire/uberfire-workbench-client-views-bs2
private int getTopPosition( final Widget widget ) {
int top = widget.getAbsoluteTop();
// if top is negative (due to scrolling) we try to align with the parent
// to make sure the notifications are always visible
if ( top < 0 && widget.getParent() != null ) {
top = getTopPosition( widget.getParent() );
}
return Math.max(top, 0);
}
代码示例来源:origin: kiegroup/appformer
private int getTopPosition(final Widget widget) {
int top = widget.getAbsoluteTop();
// if top is negative (due to scrolling) we try to align with the parent
// to make sure the notifications are always visible
if (top < 0 && widget.getParent() != null) {
top = getTopPosition(widget.getParent());
}
return Math.max(top,
0);
}
代码示例来源:origin: org.uberfire/uberfire-workbench-client-views-patternfly
private int getTopPosition(final Widget widget) {
int top = widget.getAbsoluteTop();
// if top is negative (due to scrolling) we try to align with the parent
// to make sure the notifications are always visible
if (top < 0 && widget.getParent() != null) {
top = getTopPosition(widget.getParent());
}
return Math.max(top,
0);
}
代码示例来源:origin: net.wetheinter/gwt-user
@Override
public void handleDrag(int absX, int absY) {
Widget moveTarget = LoggingPopup.this;
RootPanel.get().setWidgetPosition(moveTarget,
moveTarget.getAbsoluteLeft() + absX,
moveTarget.getAbsoluteTop() + absY);
}
}
代码示例来源:origin: com.vaadin.external.gwt/gwt-user
@Override
public void handleDrag(int absX, int absY) {
Widget moveTarget = LoggingPopup.this;
RootPanel.get().setWidgetPosition(moveTarget,
moveTarget.getAbsoluteLeft() + absX,
moveTarget.getAbsoluteTop() + absY);
}
}
代码示例来源:origin: com.allen-sauer.gwt.dnd/gwt-dnd
private void internalSetWidget(Widget widget) {
// this.widget = widget;
if (widget == null || widget == RootPanel.get()) {
widgetLeft = 0;
widgetTop = 0;
} else {
widgetLeft = widget.getAbsoluteLeft() - widget.getElement().getScrollLeft();
widgetTop = widget.getAbsoluteTop() - widget.getElement().getScrollTop();
}
}
代码示例来源:origin: com.allen-sauer.gwt.dnd/gwt-dnd
private void internalSetReference(Widget reference) {
// this.reference = reference;
if (reference == null || reference == RootPanel.get()) {
referenceAdjustLeft = 0;
referenceAdjustTop = 0;
} else {
referenceAdjustLeft = reference.getAbsoluteLeft()
+ DOMUtil.getBorderLeft(reference.getElement());
referenceAdjustTop = reference.getAbsoluteTop()
+ DOMUtil.getBorderTop(reference.getElement());
}
}
代码示例来源:origin: net.sf.advanced-gwt/advanced-gwt
/**
* Checks whether the specified item is visible in the scroll area.<p/>
* The result is <code>true</code> if whole item is visible.
*
* @param index is an index of the item.
* @return a result of check.
*/
public boolean isItemVisible(int index) {
Widget item = getList().getWidget(index);
int itemTop = item.getAbsoluteTop();
int top = getScrollPanel().getAbsoluteTop();
return itemTop >= top && itemTop + item.getOffsetHeight() <= top + getScrollPanel().getOffsetHeight();
}
代码示例来源:origin: kiegroup/appformer
public OriginalStyleInfo(final Widget w) {
absoluteLeft = w.getAbsoluteLeft();
absoluteTop = w.getAbsoluteTop();
clientHeight = w.getElement().getClientHeight();
clientWidth = w.getElement().getClientWidth();
final Style style = w.getElement().getStyle();
position = style.getPosition();
top = style.getTop();
left = style.getLeft();
width = style.getWidth();
height = style.getHeight();
zIndex = style.getZIndex();
}
内容来源于网络,如有侵权,请联系作者删除!