Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 22456 - SWT Error ("Item not added") when changing editor tabs
Summary: SWT Error ("Item not added") when changing editor tabs
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows 2000
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Steve Northover CLA
QA Contact:
URL:
Whiteboard: stalebug
Keywords:
: 63742 97884 98936 112413 138386 144743 162582 (view as bug list)
Depends on:
Blocks:
 
Reported: 2002-08-14 18:46 EDT by Steve Dobie CLA
Modified: 2021-09-07 15:39 EDT (History)
8 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Steve Dobie CLA 2002-08-14 18:46:22 EDT
When changing files in the editor using the tabs, a dialog sometimes pops up 
announcing an SWT Error and recommending that Eclipse be shut down.  If Eclipse 
is not shut down, there seem to be no bad effects, but the error dialog 
occasionally reappears.

The log contains the following error:

!ENTRY org.eclipse.ui 4 4 Aug 14, 2002 15:36:35.873
!MESSAGE Unhandled exception caught in event loop.
!ENTRY org.eclipse.ui 4 0 Aug 14, 2002 15:36:35.873
!MESSAGE Item not added
!STACK 0
org.eclipse.swt.SWTError: Item not added
	at org.eclipse.swt.SWT.error(SWT.java:2144)
	at org.eclipse.swt.SWT.error(SWT.java:2051)
	at org.eclipse.swt.widgets.Widget.error(Widget.java:370)
	at org.eclipse.swt.widgets.Menu.createItem(Menu.java:286)
	at org.eclipse.swt.widgets.MenuItem.<init>(MenuItem.java:115)
	at org.eclipse.ui.internal.ReopenEditorMenu$1.run
(ReopenEditorMenu.java:163)
	at org.eclipse.core.internal.runtime.InternalPlatform.run
(InternalPlatform.java:831)
	at org.eclipse.core.runtime.Platform.run(Platform.java:416)
	at org.eclipse.ui.internal.ReopenEditorMenu.fill
(ReopenEditorMenu.java:160)
	at org.eclipse.jface.action.MenuManager.update(MenuManager.java:528)
	at org.eclipse.jface.action.MenuManager.updateAll(MenuManager.java:577)
	at org.eclipse.jface.action.MenuManager.update(MenuManager.java:565)
	at org.eclipse.jface.action.MenuManager.updateAll(MenuManager.java:577)
	at org.eclipse.ui.internal.WorkbenchWindow.updateActionBars
(WorkbenchWindow.java:1402)
	at org.eclipse.ui.internal.WorkbenchWindow.updateActionSets
(WorkbenchWindow.java:1420)
	at org.eclipse.ui.internal.WorkbenchPage$ActionSwitcher.updateActionSets
(WorkbenchPage.java:272)
	at org.eclipse.ui.internal.WorkbenchPage$ActionSwitcher.updateActivePart
(WorkbenchPage.java:135)
	at org.eclipse.ui.internal.WorkbenchPage.setActivePart
(WorkbenchPage.java:2046)
	at org.eclipse.ui.internal.WorkbenchPage.requestActivation
(WorkbenchPage.java:1828)
	at org.eclipse.ui.internal.PartPane.requestActivation(PartPane.java:332)
	at org.eclipse.ui.internal.PartPane.setFocus(PartPane.java:350)
	at org.eclipse.ui.internal.PartTabFolder$2.handleEvent
(PartTabFolder.java:188)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:77)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:843)
	at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:636)
	at org.eclipse.swt.custom.CTabFolder.setSelection(CTabFolder.java:1687)
	at org.eclipse.swt.custom.CTabFolder.onMouseDown(CTabFolder.java:1804)
	at org.eclipse.swt.custom.CTabFolder.access$4(CTabFolder.java:1801)
	at org.eclipse.swt.custom.CTabFolder$1.handleEvent(CTabFolder.java:200)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:77)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:827)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:1529)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:1291)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1177)
	at org.eclipse.ui.internal.Workbench.run(Workbench.java:1160)
	at org.eclipse.core.internal.boot.InternalBootLoader.run
(InternalBootLoader.java:775)
	at org.eclipse.core.boot.BootLoader.run(BootLoader.java:462)
	at java.lang.reflect.Method.invoke(Native Method)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:248)
	at org.eclipse.core.launcher.Main.run(Main.java:698)
	at org.eclipse.core.launcher.Main.main(Main.java:534)
Comment 1 Mike Wilson CLA 2002-08-15 10:44:29 EDT
The SWTError "Item not added" means that at the point we called a particular 
operating system call, it (the OS call) returned an error code which we 
weren't prepared to deal with. With a correctly working version of the OS, and 
enough free OS resources (GDI memory, etc.), you should never see this 
message. 

Could you please send us as much information about your system (OS version, 
common controls version, Eclipse version, any extra plugins you have running, 
etc.) as you can find.
Comment 2 Steve Dobie CLA 2002-08-15 12:12:23 EDT
I am running Eclipse 2.0 on Win2000 Pro SP2.  My version of comctl32.dll is 
5.81. The only extra plugin that I have installed is Solar Eclipse 0.2.0.  

The issue may be related to OS resources.  Rebooting Eclipse, did not fix the 
problem, but rebooting Windows seems to have fixed it, although Eclipse was the 
only application having problems at the time I rebooted.
Comment 3 Steve Northover CLA 2002-08-15 14:41:16 EDT
I have seen 32-bit Windows platforms like NT, 2000 and XP fail when too many 
menu items are added to a menu.  Strangely enough, 16-bit Windows platforms 
like 98 did not have the problem.  This may not be the problem you are seeing.

It's strange that restarting Eclipse did not fix the problem because exiting a 
Windows process is supposed to give back all resources allocated by that 
process.

Not sure how to proceed.  Are you really running R2.0, not a later release?
Comment 4 Steve Dobie CLA 2002-08-16 11:52:13 EDT
According to the about page it is:

Version: 2.0
Build id: 200206271827
Comment 5 Grant Gayed CLA 2004-05-25 16:23:49 EDT
*** Bug 63742 has been marked as a duplicate of this bug. ***
Comment 6 Kim Horne CLA 2005-06-01 12:33:19 EDT
*** Bug 97884 has been marked as a duplicate of this bug. ***
Comment 7 Steve Northover CLA 2005-06-08 13:22:41 EDT
*** Bug 98936 has been marked as a duplicate of this bug. ***
Comment 8 Steve Northover CLA 2006-01-17 16:13:36 EST
*** Bug 112413 has been marked as a duplicate of this bug. ***
Comment 9 Steve Northover CLA 2006-04-26 17:47:43 EDT
*** Bug 138386 has been marked as a duplicate of this bug. ***
Comment 10 Steve Northover CLA 2006-10-27 12:34:39 EDT
*** Bug 162582 has been marked as a duplicate of this bug. ***
Comment 11 Steve Northover CLA 2006-11-17 17:01:15 EST
*** Bug 144743 has been marked as a duplicate of this bug. ***
Comment 12 Jamel Touati CLA 2008-10-03 20:17:33 EDT
Could you please assign this bugzilla to a release since a customer defect is dependant on it. Thanks
Comment 13 Steve Northover CLA 2008-10-06 15:23:08 EDT
I'm sorry but I don't have a repeatable case so there is nothing for me debug.  Can you make it happen every time?
Comment 14 Eclipse Webmaster CLA 2019-09-06 16:06:09 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet.

If you have further information on the current state of the bug, please add it. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.
Comment 15 Eclipse Genie CLA 2021-09-07 15:39:35 EDT
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug.

If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant.

--
The automated Eclipse Genie.