DESCRIPTION

Bug 476045 - Commands visible in Quick Access don't show commandImage

QuickAccess commands now are displaying the associated command image. 

Note: org.eclipse.ui.internal.quickaccess.CommandProvider is now
responsible to get an instance of ICommandImageService. 

Change-Id: I27ed1dea083deb7898068d0c7f6fd034b0d15131
Signed-off-by: Ryker Bauer xxx@xxx.xxx


COMMENTS

author: Ryker Bauer
date: 2016-08-18 22:01:55.000000000

Uploaded patch set 1.

-------------------------------------
author: Brenden Conley
date: 2016-08-18 22:02:01.000000000

Patch Set 1:

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

-------------------------------------
author: Ryker Bauer
date: 2016-08-18 22:07:44.000000000

Patch Set 1: Verified+1

-------------------------------------
author: Brenden Conley
date: 2016-08-18 22:22:11.000000000

Patch Set 1: Code-Review-1

Build Unstable 

https://hudson.eclipse.org/platform/job/eclipse.platform.ui-Gerrit/10139/ : UNSTABLE

-------------------------------------
author: Brenden Conley
date: 2016-08-19 08:01:53.000000000

Patch Set 1: -Code-Review

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

-------------------------------------
author: Brenden Conley
date: 2016-08-19 08:21:35.000000000

Patch Set 1: Code-Review-1

Build Unstable 

https://hudson.eclipse.org/platform/job/eclipse.platform.ui-Gerrit/10141/ : UNSTABLE

-------------------------------------
author: Isis Velasquez
date: 2016-08-19 13:47:52.000000000

Patch Set 1:

@Patrick: I'm not much aware of the QuickAccessDialog and not very good at dealing with E4 APIs. I'm not confident enough on that part of the code to give a revuew. Maybe it's better if you ask Brian for a review,

-------------------------------------
author: Ryker Bauer
date: 2016-08-19 14:11:55.000000000

Patch Set 1:

Ok, thanks anyway!

-------------------------------------
author: Ryker Bauer
date: 2016-08-19 14:12:46.000000000

Patch Set 1:

Brian, hope you don't mind reviewing this change for the backport to Neon

-------------------------------------
author: Teagan Marsh
date: 2016-08-19 16:07:20.000000000

Patch Set 1:

(2 comments)

Sorry, I didn't review your original modification, but your approach has introduced an inconsistency in the contexts being used for obtaining services.  Rather than pass in a separate IEclipseContext, use the existing pattern of obtaining it from the ExpressionContext.  At least it's being consistent.

Generally the QuickAccess elements look things up from the active context so that what they report is consistent with the enablement states of handlers, etc.

Line:58, bundles/org.eclipse.ui.workLeon Ochoach/Eclipse UI/org/eclipse/ui/internal/quickaccess/CommandProvider.java -> Passing in a context is unnecessary: use the expression context as how the IHandlerService is resolved.

Line:95, bundles/org.eclipse.ui.workLeon Ochoach/Eclipse UI/org/eclipse/ui/internal/quickaccess/QuickAccessDialog.java -> You're passing in a different context to CommandProvider from what's being provided in the expression content, which is inconsistent.

-------------------------------------
author: Ryker Bauer
date: 2016-08-19 16:09:46.000000000

Patch Set 1:

(1 comment)

Line:58, bundles/org.eclipse.ui.workLeon Ochoach/Eclipse UI/org/eclipse/ui/internal/quickaccess/CommandProvider.java -> Already did before providing that change. The expression context resolves the Service to null. That's why I needed the application context.

-------------------------------------
author: Ryker Bauer
date: 2016-08-19 16:11:21.000000000

Patch Set 1:

(1 comment)

Line:95, bundles/org.eclipse.ui.workLeon Ochoach/Eclipse UI/org/eclipse/ui/internal/quickaccess/QuickAccessDialog.java -> The expression context will resolve ctx.get(IImageDescriptorService.class) to null.

-------------------------------------
author: Ryker Bauer
date: 2016-08-19 16:14:01.000000000

Patch Set 1:

The first thing I did after you suggested using DI, was editing CommandElement#getImageDescriptor() using the context to get the services in the same way as the other contexts do.
However that way, the context is null. 
I documented that in bug comment #8: https://bugs.eclipse.org/bugs/show_bug.cgi?id=476045#c8

-------------------------------------
author: Ryker Bauer
date: 2016-08-19 16:15:22.000000000

Patch Set 1:

Thanks for reviewing this change, I really appreciate your efforts!

-------------------------------------
author: Gerrit Code Review
date: 2016-08-22 06:51:18.000000000

Change has been successfully merged into the git repository by Ryker Bauer

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