|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjpicedt.graphic.toolkit.AbstractMouseTransform
public abstract class AbstractMouseTransform
This implementation allows subclassers to modify a clone of the target Element, then to update the original Element when the operation is completed. The aim is to reduce the burden of repainting a (possibly) complex Element while transforming it, by painting the Element using very lightweight View. This is done as follow :
| Constructor Summary | |
|---|---|
protected |
AbstractMouseTransform(Element target)
|
| Method Summary | |
|---|---|
protected Element |
getClone()
Return the clone of the target element, which was init'd by startTransform |
protected Element |
getTarget()
Return the element this transform acts upon |
boolean |
next(PEMouseEvent e)
Called by mouseReleased. |
void |
paint(Graphics2D g,
Rectangle2D allocation,
double scale)
Paints the clone. |
void |
start(PEMouseEvent e)
Called by mousePressed. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface jpicedt.graphic.toolkit.MouseTransform |
|---|
getCursor, getHelpMessage, process |
| Constructor Detail |
|---|
protected AbstractMouseTransform(Element target)
target - The target-element upon which this transform will act.| Method Detail |
|---|
public void start(PEMouseEvent e)
start in interface MouseTransformpublic boolean next(PEMouseEvent e)
next in interface MouseTransformtrue if there's another task in the sequence,
false if mouse-transform has completed with this
mouse-event.
public void paint(Graphics2D g,
Rectangle2D allocation,
double scale)
paint in interface MouseTransformprotected Element getTarget()
protected Element getClone()
startTransform
|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||