/** 鼠标运动事件 */ private void processMouseMotionEvent() { if ((this.hoverComponent != null && this.hoverComponent.isEnabled()) && (this.input.isMouseDown(MouseEvent.BUTTON1) || this.input.isMouseDown(MouseEvent.BUTTON2) || this.input.isMouseDown(MouseEvent.BUTTON3))) { if (this.input.getMouseDX() != 0 || this.input.getMouseDY() != 0) { this.hoverComponent.processMouseDragged(); } } else { // 获得当前窗体下鼠标坐标 LComponent comp = this.findComponent(this.input.getMouseX(), this.input.getMouseY()); if (comp != null) { if (this.input.getMouseDX() != 0 || this.input.getMouseDY() != 0) { comp.processMouseMoved(); // 刷新提示 this.tooltip.dismiss = 0; } if (this.hoverComponent == null) { this.tooltip.setToolTipComponent(comp); comp.processMouseEntered(); } else if (comp != this.hoverComponent) { this.tooltip.setToolTipComponent(comp); this.hoverComponent.processMouseExited(); comp.processMouseEntered(); } // 如果没有对应的悬停提示数据 } else { this.tooltip.setToolTipComponent(null); if (this.hoverComponent != null) { this.hoverComponent.processMouseExited(); } } // 设置组件悬停提示状态 this.hoverComponent = comp; } }