Package wprover
Class JArrowFlash
- java.lang.Object
-
- wprover.JFlash
-
- wprover.JArrowFlash
-
- All Implemented Interfaces:
java.awt.event.ActionListener,java.util.EventListener
public class JArrowFlash extends JFlash implements java.awt.event.ActionListener
JArrowFlash is a class that extends JFlash and implements ActionListener. It is used to create a flashing arrow effect on a JPanel.
-
-
Constructor Summary
Constructors Constructor Description JArrowFlash(javax.swing.JPanel panel, CPoint p1, CPoint p2, int type)Constructs a new JArrowFlash with the specified JPanel, points, and type.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidactionPerformed(java.awt.event.ActionEvent e)Handles action events for the timer.booleandraw(java.awt.Graphics2D g2)Draws the flashing arrow on the specified Graphics2D context.-
Methods inherited from class wprover.JFlash
drawALine3, drawALine3Short, getColor, getRatioColor, getvisibleType, isfinished, isrRunning, isZero, recalculate, setColor, setDealy, setDrawDash, setDrawDashFb2, start, stop, updateTimer
-
-
-
-
Constructor Detail
-
JArrowFlash
public JArrowFlash(javax.swing.JPanel panel, CPoint p1, CPoint p2, int type)Constructs a new JArrowFlash with the specified JPanel, points, and type.- Parameters:
panel- the JPanel to associate with this JArrowFlashp1- the starting point of the arrowp2- the ending point of the arrowtype- the type of the arrow (0 for PI/6, 1 for PI*5/6)
-
-
Method Detail
-
draw
public boolean draw(java.awt.Graphics2D g2)
Draws the flashing arrow on the specified Graphics2D context.
-
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent e)
Handles action events for the timer.- Specified by:
actionPerformedin interfacejava.awt.event.ActionListener- Parameters:
e- the action event
-
-