Package com.bc.ceres.swing.debug
Class CheckThreadViolationRepaintManager
- java.lang.Object
-
- javax.swing.RepaintManager
-
- com.bc.ceres.swing.debug.CheckThreadViolationRepaintManager
-
public class CheckThreadViolationRepaintManager extends RepaintManager
This class is used to detect Event Dispatch Thread rule violations
See How to Use Threads for more infoThis is a modification of original idea of Scott Delap
Initial version of ThreadCheckingRepaintManager can be found here
Easily Find Swing Threading MistakesAlso see Debugging Swing, the final summary
-
-
Constructor Summary
Constructors Constructor Description CheckThreadViolationRepaintManager()
CheckThreadViolationRepaintManager(boolean completeCheck)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addDirtyRegion(JComponent component, int x, int y, int w, int h)
void
addInvalidComponent(JComponent component)
boolean
isCompleteCheck()
static void
main(String[] args)
void
setCompleteCheck(boolean completeCheck)
protected void
violationFound(JComponent c, StackTraceElement[] stackTrace)
-
Methods inherited from class javax.swing.RepaintManager
addDirtyRegion, addDirtyRegion, currentManager, currentManager, getDirtyRegion, getDoubleBufferMaximumSize, getOffscreenBuffer, getVolatileOffscreenBuffer, isCompletelyDirty, isDoubleBufferingEnabled, markCompletelyClean, markCompletelyDirty, paintDirtyRegions, removeInvalidComponent, setCurrentManager, setDoubleBufferingEnabled, setDoubleBufferMaximumSize, toString, validateInvalidComponents
-
-
-
-
Method Detail
-
isCompleteCheck
public boolean isCompleteCheck()
-
setCompleteCheck
public void setCompleteCheck(boolean completeCheck)
-
addInvalidComponent
public void addInvalidComponent(JComponent component)
- Overrides:
addInvalidComponent
in classRepaintManager
-
addDirtyRegion
public void addDirtyRegion(JComponent component, int x, int y, int w, int h)
- Overrides:
addDirtyRegion
in classRepaintManager
-
violationFound
protected void violationFound(JComponent c, StackTraceElement[] stackTrace)
-
-