| Summary: | [All digrams] Changing editors (from Papyrus to text-based editor) causes recurring null pointer exception | ||
|---|---|---|---|
| Product: | [Modeling] Papyrus | Reporter: | Ansgar Radermacher <ansgar.radermacher> |
| Component: | Core | Assignee: | Vincent Lorenzo <vincent.lorenzo> |
| Status: | RESOLVED FIXED | QA Contact: | |
| Severity: | critical | ||
| Priority: | P3 | CC: | vincent.lorenzo |
| Version: | 0.8.1 | ||
| Target Milestone: | --- | ||
| Hardware: | PC | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Bug Depends on: | 358240 | ||
| Bug Blocks: | |||
Workaround:
Disable (put into comments) dynamic visibility of toolbar in plugin.xml of oep.diaram.menu:
...
</command>
<!--
<dynamic
class="org.eclipse.papyrus.diagram.menu.toolbar.ZoomToolbar"
id="zoomToolBar">
<visibleWhen
checkEnabled="true">
<and>
<with
variable="activeEditorId">
<equals
value="org.eclipse.papyrus.core.papyrusEditor">
</equals>
</with>
</and>
</visibleWhen>
</dynamic>
-->
<visibleWhen>
<with variable="activeEditorId"> ...
The error does not only occur with the Zoom control (Combo), it also occurs with the font combo boxes (font name, font size) provided by GMF, but results apparently less often in visible erroneous behavior - which basically means that the error is more difficult to reproduce, but might still occur.
Current workaround:
Import org.eclipse.swt as source project. Modify class Combo: overload dispose function:
public void dispose() {
buttonHandle = 0;
super.dispose();
}
Fixed in 383189 (In reply to comment #3) > Fixed in 383189 Clarification: Fixed due to the fix of bug 383189 (bug 357085 is a duplicate of 383189) |
When the user changes between Papyrus and a text based editor, there are sometimes popup-windows with a set of null pointer exceptions. These are critical: when the user clicks on "ok" or "close", a new exception will be thrown immediately resulting in a new popup. It is thus not possible to close the workspace properly, nor to save. The problem did not occur with Papyrus 0.7.x. A first analysis showed that immediately before the first null pointer exception, a "widget disposed exception" is thrown (see below). The widget is in fact a menu, the associated manager has ID org.eclipse.papyrus.table.ui.menu.tables. An analysis (and try&error) showed that problem can be reproduced as long as org.eclipse.papyrus.diagram menu is active and more specifically the extension point associated with the toolbar. The error can not be reproduced, if the extension point associated with the toolbar is removed. It can also not be reproduced, if the "dynamic" attribute is removed (<dynamic class="oep.diagram.menu.toolbar.ZoomToolbar" ...) Thread [main] (Suspended (breakpoint at line 466 in Widget)) Menu(Widget).error(int) line: 466 Menu(Widget).checkWidget() line: 403 Menu.getParentMenu() line: 590 [Menu {*Disposed*}] MenuManager.updateMenuItem() line: 984 [MenuManager, id=org.eclipse.papyrus.table.ui.menu.tables] MenuManager.update(boolean, boolean) line: 870 MenuManager.update(boolean) line: 682 WorkbenchMenuService.updateManagers() line: 330 WorkbenchMenuService$4.propertyChange(PropertyChangeEvent) line: 316 EvaluationAuthority$1.run() line: 252 SafeRunner.run(ISafeRunnable) line: 42 EvaluationAuthority.fireServiceChange(String, Object, Object) line: 246 EvaluationAuthority.endSourceChange(String[]) line: 197 EvaluationAuthority.sourceChanged(String[]) line: 135 EvaluationAuthority(ExpressionAuthority).sourceChanged(int, String[]) line: 311 EvaluationAuthority(ExpressionAuthority).sourceChanged(int, Map) line: 290 WorkbenchSourceProvider(AbstractSourceProvider).fireSourceChanged(int, Map) line: 99 WorkbenchSourceProvider.checkActivePart(boolean) line: 401 WorkbenchSourceProvider.checkActivePart() line: 300 WorkbenchSourceProvider$1.partBroughtToTop(IWorkbenchPart) line: 239