egovconcepts / jacp

Automatically exported from code.google.com/p/jacp
0 stars 0 forks source link

Syncronisation in SWING-Thread Error #9

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Synchronisation issue in Comonent replace worker:

inconsistent handling of component replacement! Replacement is not handled in 
Swing-Thread

Exception in thread "AWT-EventQueue-0" 
java.lang.ArrayIndexOutOfBoundsException: 2 >= 1
    at java.util.Vector.elementAt(Vector.java:427)
    at javax.swing.JTabbedPane.getComponentAt(JTabbedPane.java:1203)
    at com.apple.laf.AquaTabbedPaneCopyFromBasicUI$TabbedPaneLayout.layoutContainer(AquaTabbedPaneCopyFromBasicUI.java:2241)
    at java.awt.Container.layout(Container.java:1421)
    at java.awt.Container.doLayout(Container.java:1410)
    at java.awt.Container.validateTree(Container.java:1507)
    at java.awt.Container.validateTree(Container.java:1513)
    at java.awt.Container.validateTree(Container.java:1513)
    at java.awt.Container.validate(Container.java:1480)
    at javax.swing.RepaintManager.validateInvalidComponents(RepaintManager.java:669)
    at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(SystemEventQueueUtilities.java:124)
    at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:633)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
Exception in thread "AWT-EventQueue-0" 
java.lang.ArrayIndexOutOfBoundsException: 2 >= 1
    at java.util.Vector.elementAt(Vector.java:427)
    at javax.swing.JTabbedPane.getComponentAt(JTabbedPane.java:1203)
    at com.apple.laf.AquaTabbedPaneCopyFromBasicUI$TabbedPaneLayout.layoutContainer(AquaTabbedPaneCopyFromBasicUI.java:2241)
    at java.awt.Container.layout(Container.java:1421)
    at java.awt.Container.doLayout(Container.java:1410)
    at java.awt.Container.validateTree(Container.java:1507)
    at java.awt.Container.validate(Container.java:1480)
    at com.apple.laf.AquaTabbedPaneCopyFromBasicUI.ensureCurrentLayout(AquaTabbedPaneCopyFromBasicUI.java:1316)
    at com.apple.laf.AquaTabbedPaneUI.paint(AquaTabbedPaneUI.java:110)
    at javax.swing.plaf.ComponentUI.update(ComponentUI.java:153)
    at javax.swing.JComponent.paintComponent(JComponent.java:752)
    at javax.swing.JComponent.paint(JComponent.java:1029)
    at javax.swing.JComponent.paintChildren(JComponent.java:862)
    at javax.swing.JComponent.paint(JComponent.java:1038)
    at javax.swing.JViewport.paint(JViewport.java:747)
    at javax.swing.JComponent._paintImmediately(JComponent.java:5098)
    at javax.swing.JComponent.paintImmediately(JComponent.java:4882)
    at javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:811)
    at javax.swing.RepaintManager.paintDirtyRegions(RepaintManager.java:713)
    at javax.swing.RepaintManager.seqPaintDirtyRegions(RepaintManager.java:693)
    at javax.swing.SystemEventQueueUtilities$ComponentWorkRequest.run(SystemEventQueueUtilities.java:125)
    at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
    at java.awt.EventQueue.dispatchEvent(EventQueue.java:633)
    at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
    at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
    at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
    at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
    at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

Original issue reported on code.google.com by amo.a...@gmail.com on 10 Jun 2010 at 5:32

GoogleCodeExporter commented 9 years ago

Original comment by amo.a...@gmail.com on 10 Jun 2010 at 8:49

GoogleCodeExporter commented 9 years ago
changed component add and remove method to run in EventDispatch thread;

Original comment by amo.a...@gmail.com on 10 Jun 2010 at 8:52

GoogleCodeExporter commented 9 years ago

Original comment by amo.a...@gmail.com on 10 Jun 2010 at 9:04