OnJava8-Examples/onjava/MouseClick.java

20 lines
622 B
Java
Raw Permalink Normal View History

// onjava/MouseClick.java
// (c)2021 MindView LLC: see Copyright.txt
2015-11-15 15:51:35 -08:00
// We make no guarantees that this code is fit for any purpose.
2016-09-23 13:23:35 -06:00
// Visit http://OnJava8.com for more book information.
// Helper interface to allow lambda expressions.
package onjava;
2015-11-03 12:00:44 -08:00
import java.awt.event.*;
// Default everything except mouseClicked():
public interface MouseClick extends MouseListener {
@Override
default void mouseEntered(MouseEvent e) {}
2015-11-03 12:00:44 -08:00
@Override
default void mouseExited(MouseEvent e) {}
2015-11-03 12:00:44 -08:00
@Override
default void mousePressed(MouseEvent e) {}
2015-11-03 12:00:44 -08:00
@Override
default void mouseReleased(MouseEvent e) {}
2015-11-03 12:00:44 -08:00
}