本文整理匯總了Java中com.google.gwt.event.dom.client.MouseMoveEvent.getClientY方法的典型用法代碼示例。如果您正苦於以下問題:Java MouseMoveEvent.getClientY方法的具體用法?Java MouseMoveEvent.getClientY怎麽用?Java MouseMoveEvent.getClientY使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.google.gwt.event.dom.client.MouseMoveEvent
的用法示例。
在下文中一共展示了MouseMoveEvent.getClientY方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: continueDragging
import com.google.gwt.event.dom.client.MouseMoveEvent; //導入方法依賴的package包/類
@Override
protected void continueDragging(MouseMoveEvent event) {
if (this.dragMode >= 0 && this.resizable) {
this.updateCursor(this.dragMode);
int dx = event.getClientX() - this.dragX;
int dy = event.getClientY() - this.dragY;
this.dragX = event.getClientX();
this.dragY = event.getClientY();
dragResizeWidget(this, dx, dy);
} else {
// this updates the cursor when dragging is NOT activated
if (!this.minimized) {
int dm = calcDragMode(event.getClientX(),event.getClientY());
this.updateCursor(dm);
}
super.continueDragging(event);
}
}
示例2: onMouseMove
import com.google.gwt.event.dom.client.MouseMoveEvent; //導入方法依賴的package包/類
@Override
public void onMouseMove(MouseMoveEvent event) {
// There's a weird bug in Chrome on Windows 10 64bit that causes a mouse move event to fire on mouse down so this tries to workaround it
// https://bugs.chromium.org/p/chromium/issues/detail?id=721341
if (startEvent != null && (startEvent.getClientX() != event.getClientX() || startEvent.getClientY() != event.getClientY())) {
event.preventDefault();
event.stopPropagation();
propagateEvent(new PressMoveEvent(event));
}
}
示例3: calculateDockSize
import com.google.gwt.event.dom.client.MouseMoveEvent; //導入方法依賴的package包/類
private double calculateDockSize(MouseMoveEvent event,
DocksBar docksBar) {
UberfireDockPosition position = docksBar.getPosition();
if (position == UberfireDockPosition.WEST) {
return docksBar.getExpandedBarSize() + (event.getClientX() - getAbsoluteLeft());
}
if (position == UberfireDockPosition.EAST) {
return docksBar.getExpandedBarSize() + (getAbsoluteLeft() - event.getClientX());
}
if (position == UberfireDockPosition.SOUTH) {
return docksBar.getExpandedBarSize() + (getAbsoluteTop() - event.getClientY());
}
return docksBar.getExpandedBarSize();
}
示例4: onMouseMove
import com.google.gwt.event.dom.client.MouseMoveEvent; //導入方法依賴的package包/類
@Override
public void onMouseMove(MouseMoveEvent event)
{
m_mouseX = event.getClientX();
m_mouseY = event.getClientY();
}