Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 354428

Summary: [Help] Standalone Help doesn't support enablement expressions with contributed property testers
Product: [Eclipse Project] Platform Reporter: Martin Oberhuber <mober.at+eclipse>
Component: User AssistanceAssignee: Chris Goldthorpe <cgold>
Status: RESOLVED FIXED QA Contact:
Severity: major    
Priority: P3 CC: cgold
Version: 3.7Flags: cgold: review+
Target Milestone: 3.7.1   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Attachments:
Description Flags
patch v1 none

Description Martin Oberhuber CLA 2011-08-10 14:43:16 EDT
Build ID: 3.7 (Indigo)

The standalone help application does evaluate enablement expressions in the TOC - but the context in which these are evaluated doesn't support plugin activation. As a result, any user-contributed property testers are never loaded and respective expressions are unusable.

This is a major problem for us since we've added a fair bit of enablement expressions into our documentation. Which works perfectly fine when used from the IDE (plugins are activated already from the IDE when help kicks in), as well as in infocenter mode (no enablement conditions used at all).

We'd now like to support standalone help using the new "displayHelpWindow" command, but it's unusable for us since most of our docs are always hidden due to this force activation / enablement defect.
Comment 1 Martin Oberhuber CLA 2011-08-10 14:46:31 EDT
Created attachment 201267 [details]
patch v1

Attached 2-line patch fixes the issue, by allowing plugin activation in the evaluation context used by standalone help.

I can't see how this would cause any issues since enablement expressions need to explicitly request plugin activation - denying this request doesn't make sense. 

It was necessary to fix both the UI and non-UI help context since there's a very short time at startup where the non-UI context is active before the UI one kicks in. I wanted to allow plugin activation in both contexts to avoid race conditions where an expression would happen to be evaluated early.

Please consider this patch for 3.7.1 - it's really critical for our product.
Comment 2 Chris Goldthorpe CLA 2011-08-15 15:49:03 EDT
Targeting 3.7.1
Comment 3 Chris Goldthorpe CLA 2011-08-16 13:23:34 EDT
+1 for inclusion in 3.7.1. I also cannot see any reason why the patch would cause problems.
Comment 4 Chris Goldthorpe CLA 2011-08-16 13:25:28 EDT
Patch committed to HEAD with copyright year and contributors updated in comments.
Comment 5 Chris Goldthorpe CLA 2011-08-16 13:37:28 EDT
Patch committed to 3.7 maintenance stream with copyright year and contributors updated in comments. Fixed
Comment 6 Chris Goldthorpe CLA 2011-08-24 16:44:14 EDT
The fix is in M20110824-0800 - please verify the fix.
Comment 7 Martin Oberhuber CLA 2011-09-13 07:26:45 EDT
CQ:WIND00292491