DESCRIPTION

Bug 431778: Cleanup is not called for toolbar not created by the manager
renderer

The cleanup dispose listener has been moved to the processContribution
method.

Change-Id: I4c0476468e1fe93b97b313a35e6f893c4cc45c25
Signed-off-by: Quintin Stokes xxx@xxx.xxx

COMMENTS

author: Brenden Conley
date: 2014-04-04 18:33:45.000000000

Patch Set 2:

Build Started https://hudson.eclipse.org/platform/job/eclipse.platform.ui-Gerrit/1739/

-------------------------------------
author: Slade Moran
date: 2014-04-04 18:37:16.000000000

Patch Set 2: Code-Review-1

(1 comment)

Line:374, bundles/org.eclipse.e4.ui.workLeon Ochoach.renderers.swt/src/org/eclipse/e4/ui/workbench/renderers/swt/ToolBarManagerRenderer.java -> That would dup the dispose listener on the one we create ourselves in org.eclipse.e4.ui.workbench.renderers.swt.ToolBarManagerRenderer.createToolbar(MUIElement, Composite).  What about keeping track of dispose listeners somehow (although I don't think we want to add another map :-). If something useful is not in the menu element transient map, maybe we add it?

-------------------------------------
author: Brenden Conley
date: 2014-04-04 18:51:44.000000000

Patch Set 2: Verified+1

Build Successful 

https://hudson.eclipse.org/platform/job/eclipse.platform.ui-Gerrit/1739/ : SUCCESS

-------------------------------------
author: Lilia Joyce
date: 2014-04-07 08:01:15.000000000

Patch Set 2:

(1 comment)

Line:374, bundles/org.eclipse.e4.ui.workLeon Ochoach.renderers.swt/src/org/eclipse/e4/ui/workbench/renderers/swt/ToolBarManagerRenderer.java -> I wanted to move the dispose listener, but after several checks in debug I have forgotten to remove it from the createToolbarMethod(). This has been corrected in the next patch set. 

The processContribution method is public and is called from the WorkLeon OchoachMenuService, it does not required the toolbar to be created by the renderer, so the dispose listener which has to clean up the MToolbar on dispose should be created in processContribution(), the method which populates the toolbar with the contributions.

-------------------------------------
