title: How to implement MouseWheelListener for JPanel without breaking its default implementation?
body: <p>Simply; I have a <code>JPanel</code> inside a <code>JScrollPane</code>;</p>
  
  <p>As expected; <code>JScrollPane</code> by default listens to <code>MouseWheelEvent</code> so that scrolling is working well for when the wheel is rotating and while the cursor is hovering over the <code>JPanel</code>.</p>
  
  <p><strong>But</strong> After that; I just updated <code>JPanel</code> so that it implements <code>MouseWheelListener</code>, and I added this mouse wheel listener for the <code>JPanel</code> itself.</p>
  
  <pre><code>@Override
  public void mouseWheelMoved(MouseWheelEvent e) {
      if (e.isControlDown()) {
          if (e.getWheelRotation() &lt; 0) {
              System.out.println("mouse wheel Up");
          } else {
              System.out.println("mouse wheel Down");
          }
      }
  }
  </code></pre>
  
  <p>The <code>JPanel</code> responds to this implementation for when both; the <kbd>Ctrl</kbd> is pressed down and the wheel is rotating and while the cursor is hovering over the <code>JPanel</code>. But the default behaviour of the <code>JScrollPane</code> is unexpectedly lost!!!</p>
  
  <p>When I rotate the wheel while the cursor is hovering over the <code>JPanel</code> the scrolls of the <code>JScrollPane</code> is not responding!!!</p>
  
  <p>It seems that; this implementation of <code>MouseWheelListener</code> breaks the default of a <code>JPanel</code>.</p>
  
  <p>So; How to implement <code>MouseWheelListener</code> for <code>JPanel</code> without breaking its default implementation? </p>