Bug 30954 - [OLE] Cannot set text on MenuItem
Summary: [OLE] Cannot set text on MenuItem
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 2.1   Edit
Hardware: PC Windows XP
: P2 normal (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact: Felipe Heidrich CLA
URL:
Whiteboard: stalebug
Keywords: triaged
: 59131 (view as bug list)
Depends on:
Blocks:
 
Reported: 2003-02-05 09:00 EST by Michael Fraenkel CLA
Modified: 2019-09-29 02:17 EDT (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Michael Fraenkel CLA 2003-02-05 09:00:34 EST
Eclipse 2.1 Win32 I20030129

I was closing a WordPro document from within the workbench.  When I went to 
close the document, I received the following:

org.eclipse.swt.SWTError: Cannot set text
        at org.eclipse.swt.SWT.error(SWT.java:2318)
        at org.eclipse.swt.SWT.error(SWT.java(Inlined Compiled Code))
        at org.eclipse.swt.widgets.Widget.error(Widget.java(Inlined Compiled 
Code))
        at org.eclipse.swt.widgets.MenuItem.setText(MenuItem.java(Compiled 
Code))
        at org.eclipse.jface.action.ActionContributionItem.update
(ActionContributionItem.java(Compiled Code))
        at org.eclipse.jface.action.ActionContributionItem.actionPropertyChange
(ActionContributionItem.java(Compiled Code))
        at org.eclipse.jface.action.ActionContributionItem.access$1
(ActionContributionItem.java(Inlined Compiled Code))
        at 
org.eclipse.jface.action.ActionContributionItem$ActionListener.propertyChange
(ActionContributionItem.java(Compiled Code))
        at org.eclipse.jface.action.Action.setText(Action.java(Compiled Code))
        at org.eclipse.ui.internal.SaveAction.updateState(SaveAction.java:41)
        at org.eclipse.ui.internal.ActiveEditorAction.partClosed
(ActiveEditorAction.java:123)
        at org.eclipse.ui.internal.PartListenerList$3.run
(PartListenerList.java:83)
        at org.eclipse.core.internal.runtime.InternalPlatform.run
(InternalPlatform.java(Inlined Compiled Code))
        at org.eclipse.core.runtime.Platform.run(Platform.java(Compiled Code))
        at org.eclipse.ui.internal.PartListenerList.firePartClosed
(PartListenerList.java:81)
        at org.eclipse.ui.internal.WWinPartService$1.partClosed
(WWinPartService.java:38)
        at org.eclipse.ui.internal.PartListenerList2$3.run
(PartListenerList2.java:79)
        at org.eclipse.core.internal.runtime.InternalPlatform.run
(InternalPlatform.java(Inlined Compiled Code))
        at org.eclipse.core.runtime.Platform.run(Platform.java(Compiled Code))
        at org.eclipse.ui.internal.PartListenerList2.firePartClosed
(PartListenerList2.java:77)
        at org.eclipse.ui.internal.WorkbenchPage.firePartClosed
(WorkbenchPage.java:1207)
        at org.eclipse.ui.internal.WorkbenchPage.closeEditor
(WorkbenchPage.java:818)
        at org.eclipse.ui.internal.WorkbenchPage.closeEditor
(WorkbenchPage.java:783)
        at org.eclipse.ui.internal.EditorPane.doHide(EditorPane.java:83)
        at org.eclipse.ui.internal.EditorWorkbook$2.itemClosed
(EditorWorkbook.java:171)
        at org.eclipse.swt.custom.CTabFolder.closeNotify(CTabFolder.java:303)
        at org.eclipse.swt.custom.CTabFolder.access$13(CTabFolder.java:293)
        at org.eclipse.swt.custom.CTabFolder$4.handleEvent(CTabFolder.java:434)
        at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java
(Inlined Compiled Code))
        at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java(Inlined 
Compiled Code))
        at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java
(Compiled Code))
        at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java
(Compiled Code))
        at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java
(Compiled Code))
        at org.eclipse.ui.internal.Workbench.run(Workbench.java:1223)
        at org.eclipse.core.internal.boot.InternalBootLoader.run
(InternalBootLoader.java:845)
        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:247)
        at org.eclipse.core.launcher.Main.run(Main.java:703)
        at org.eclipse.core.launcher.Main.main(Main.java:539)

When I went to close Eclipse because the message box said I should, I got:
java.lang.NegativeArraySizeException
        at org.eclipse.swt.widgets.Menu.getItems(Menu.java(Compiled Code))
        at org.eclipse.swt.widgets.Menu.releaseWidget(Menu.java:992)
        at org.eclipse.swt.widgets.Widget.releaseResources(Widget.java
(Compiled Code))
        at org.eclipse.swt.widgets.MenuItem.releaseWidget(MenuItem.java:424)
        at org.eclipse.swt.widgets.Widget.releaseResources(Widget.java
(Compiled Code))
        at org.eclipse.swt.widgets.Menu.releaseWidget(Menu.java:999)
        at org.eclipse.swt.widgets.Widget.releaseResources(Widget.java
(Compiled Code))
        at org.eclipse.swt.widgets.Decorations.releaseWidget
(Decorations.java:591)
        at org.eclipse.swt.widgets.Shell.releaseWidget(Shell.java:693)
        at org.eclipse.swt.widgets.Widget.dispose(Widget.java:368)
        at org.eclipse.swt.widgets.Shell.dispose(Shell.java:470)
        at org.eclipse.jface.window.Window.close(Window.java:223)
        at org.eclipse.jface.window.ApplicationWindow.close
(ApplicationWindow.java:224)
        at org.eclipse.ui.internal.WorkbenchWindow.hardClose
(WorkbenchWindow.java:949)
        at org.eclipse.ui.internal.WorkbenchWindow.busyClose
(WorkbenchWindow.java:339)
        at org.eclipse.ui.internal.WorkbenchWindow.access$3
(WorkbenchWindow.java:328)
        at org.eclipse.ui.internal.WorkbenchWindow$2.run
(WorkbenchWindow.java:384)
        at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java
(Compiled Code))
        at org.eclipse.ui.internal.WorkbenchWindow.close
(WorkbenchWindow.java:382)
        at org.eclipse.jface.window.WindowManager.close(WindowManager.java:102)
        at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:318)
        at org.eclipse.core.internal.runtime.InternalPlatform.run
(InternalPlatform.java(Inlined Compiled Code))
        at org.eclipse.core.runtime.Platform.run(Platform.java(Compiled Code))
        at org.eclipse.ui.internal.Workbench.busyClose(Workbench.java:315)
        at org.eclipse.ui.internal.Workbench.access$7(Workbench.java:272)
        at org.eclipse.ui.internal.Workbench$7.run(Workbench.java:434)
        at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java
(Compiled Code))
        at org.eclipse.ui.internal.Workbench.close(Workbench.java:432)
        at org.eclipse.ui.internal.ExceptionHandler.closeWorkbench
(ExceptionHandler.java:102)
        at org.eclipse.ui.internal.ExceptionHandler.handleException
(ExceptionHandler.java:87)
        at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java
(Compiled Code))
        at org.eclipse.ui.internal.Workbench.run(Workbench.java:1223)
        at org.eclipse.core.internal.boot.InternalBootLoader.run
(InternalBootLoader.java:845)
        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:247)
        at org.eclipse.core.launcher.Main.run(Main.java:703)
        at org.eclipse.core.launcher.Main.main(Main.java:539)
Comment 1 Steve Northover CLA 2003-02-05 11:26:55 EST
Can you make this happen every time?

This message inidicates a failure in the operating system.  It was unable to 
set the text and returned an error code indicating that the operation was not 
successful.  This can happen when all of the operating system resources are 
used up, due to a leak.  Generally, Windows XP will simply allocate more 
memory when an application leaks and this error won't happen.
Comment 2 Michael Fraenkel CLA 2003-02-05 11:30:52 EST
I am using Win XP.  And yes, it happens every time.
Comment 3 Steve Northover CLA 2003-02-05 16:10:10 EST
We will need the steps to invoke the WordPro document.  I'm going to give this 
to Veronika because it's an OLE thing.
Comment 4 Michael Fraenkel CLA 2003-02-05 17:41:00 EST
Easy enough.
Just place any WordPro (*.lwp) document inside a Project.  I just double-
clicked on it.  The default viewer will be WordPro.  Just close the view, and 
you will hit the first problem.  Then close Eclipse, and the second one will 
occur.
Comment 5 Veronika Irvine CLA 2003-02-06 08:56:40 EST
Need to get WordPro installed.
Comment 6 Veronika Irvine CLA 2003-02-27 14:08:48 EST
We are downgrading this to P2.  We don't have time to look at it for 2.1.
Comment 7 Veronika Irvine CLA 2003-04-01 14:07:08 EST
I can make a similar error happen by shutting down WINWORD from the Windows 
Task Manager while a word document is open in Eclipse.  Killing the WINWORD 
server while the client is still up will have bad consequences.
Comment 8 Steve Northover CLA 2004-04-20 16:10:00 EDT
*** Bug 59131 has been marked as a duplicate of this bug. ***
Comment 9 John Sisson CLA 2006-07-21 01:42:27 EDT
I have also hit this problem.  I was debugging a remote process and switched from the debug perspective to the java perspective and then double clicked on a file in the package explorer and then suddenly I see my workspace shutting down..

!SESSION 2006-07-20 13:26:42.847 -----------------------------------------------
eclipse.buildId=M20060629-1905
java.version=1.5.0_06
java.vendor=Sun Microsystems Inc.
BootLoader constants: OS=win32, ARCH=x86, WS=win32, NL=en_AU
Command-line arguments:  -os win32 -ws win32 -arch x86 -clean

!ENTRY org.eclipse.ui 4 4 2006-07-21 15:35:20.379
!MESSAGE Unhandled event loop exception

!ENTRY org.eclipse.ui 4 0 2006-07-21 15:35:20.379
!MESSAGE Cannot set text
!STACK 0
org.eclipse.swt.SWTError: Cannot set text
	at org.eclipse.swt.SWT.error(SWT.java:3400)
	at org.eclipse.swt.SWT.error(SWT.java:3297)
	at org.eclipse.swt.SWT.error(SWT.java:3268)
	at org.eclipse.swt.widgets.Widget.error(Widget.java:435)
	at org.eclipse.swt.widgets.MenuItem.setText(MenuItem.java:1038)
	at org.eclipse.jface.action.ActionContributionItem.update(ActionContributionItem.java:838)
	at org.eclipse.jface.action.ActionContributionItem.fill(ActionContributionItem.java:279)
	at org.eclipse.jface.action.SubContributionItem.fill(SubContributionItem.java:66)
	at org.eclipse.jface.action.MenuManager.update(MenuManager.java:662)
	at org.eclipse.jface.action.MenuManager.updateAll(MenuManager.java:762)
	at org.eclipse.jface.action.MenuManager.update(MenuManager.java:682)
	at org.eclipse.jface.action.MenuManager.updateAll(MenuManager.java:762)
	at org.eclipse.ui.internal.WorkbenchWindow.updateActionBars(WorkbenchWindow.java:2753)
	at org.eclipse.ui.internal.WorkbenchWindow.largeUpdateEnd(WorkbenchWindow.java:2803)
	at org.eclipse.ui.internal.Workbench.largeUpdateEnd(Workbench.java:2719)
	at org.eclipse.ui.internal.WorkbenchPage.busyOpenEditor(WorkbenchPage.java:2524)
	at org.eclipse.ui.internal.WorkbenchPage.access$10(WorkbenchPage.java:2513)
	at org.eclipse.ui.internal.WorkbenchPage$9.run(WorkbenchPage.java:2498)
	at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:67)
	at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2493)
	at org.eclipse.ui.internal.WorkbenchPage.openEditor(WorkbenchPage.java:2478)
	at org.eclipse.jdt.internal.ui.javaeditor.EditorUtility.openInEditor(EditorUtility.java:287)
	at org.eclipse.jdt.internal.ui.javaeditor.EditorUtility.openInEditor(EditorUtility.java:164)
	at org.eclipse.jdt.internal.ui.actions.OpenActionUtil.open(OpenActionUtil.java:49)
	at org.eclipse.jdt.ui.actions.OpenAction.run(OpenAction.java:190)
	at org.eclipse.jdt.ui.actions.OpenAction.run(OpenAction.java:174)
	at org.eclipse.jdt.ui.actions.SelectionDispatchAction.dispatchRun(SelectionDispatchAction.java:267)
	at org.eclipse.jdt.ui.actions.SelectionDispatchAction.run(SelectionDispatchAction.java:243)
	at org.eclipse.jdt.internal.ui.packageview.PackageExplorerActionGroup.handleOpen(PackageExplorerActionGroup.java:306)
	at org.eclipse.jdt.internal.ui.packageview.PackageExplorerPart$4.open(PackageExplorerPart.java:651)
	at org.eclipse.jface.viewers.StructuredViewer$2.run(StructuredViewer.java:817)
	at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:37)
	at org.eclipse.core.runtime.Platform.run(Platform.java:843)
	at org.eclipse.ui.internal.JFaceUtil$1.run(JFaceUtil.java:44)
	at org.eclipse.jface.util.SafeRunnable.run(SafeRunnable.java:149)
	at org.eclipse.jface.viewers.StructuredViewer.fireOpen(StructuredViewer.java:815)
	at org.eclipse.jface.viewers.StructuredViewer.handleOpen(StructuredViewer.java:1069)
	at org.eclipse.jface.viewers.StructuredViewer$6.handleOpen(StructuredViewer.java:1168)
	at org.eclipse.jface.util.OpenStrategy.fireOpenEvent(OpenStrategy.java:249)
	at org.eclipse.jface.util.OpenStrategy.access$2(OpenStrategy.java:243)
	at org.eclipse.jface.util.OpenStrategy$1.handleEvent(OpenStrategy.java:283)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:66)
	at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:928)
	at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.java:3348)
	at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:2968)
	at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.java:1914)
	at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1878)
	at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:419)
	at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:149)
	at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplication.java:95)
	at org.eclipse.core.internal.runtime.PlatformActivator$1.run(PlatformActivator.java:78)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:92)
	at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:68)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:400)
	at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:177)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:585)
	at org.eclipse.core.launcher.Main.invokeFramework(Main.java:336)
	at org.eclipse.core.launcher.Main.basicRun(Main.java:280)
	at org.eclipse.core.launcher.Main.run(Main.java:977)
	at org.eclipse.core.launcher.Main.main(Main.java:952)
Comment 10 Felipe Heidrich CLA 2009-08-12 12:07:55 EDT
Your bug has been moved to triage, visit http://www.eclipse.org/swt/triage.php for more info.
Comment 11 Leo Ufimtsev CLA 2017-08-03 12:29:14 EDT
This is a one-off bulk update. (The last one in the triage migration).

Moving bugs from swt-triaged@eclipse to platform-swt-inbox@eclipse.org and adding "triaged" keyword as per new triage process:
https://wiki.eclipse.org/SWT/Devel/Triage

See Bug 518478 for details.

Tag for notification/mail filters:
@TriageBulkUpdate
Comment 12 Eclipse Genie CLA 2019-09-29 02:17:15 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.

--
The automated Eclipse Genie.