void (AWTEvent event) { if (event != null && MouseEvent.MOUSE_MOVED == event.getID()) { Object source = event.getSource(); if (source instanceof Component) { JScrollPane pane = ComponentUtil.getParentOfType((Class<? extends JScrollPane>)JScrollPane.class, (Component)source); if (pane != null) { pauseThumbAnimation(pane.getHorizontalScrollBar()); pauseThumbAnimation(pane.getVerticalScrollBar()); } } } }