Bug 97586 [preferences] Access restriction link should open correct section
RC1 The Java - Editor - Code assist preference page has a link to the access rules - we should be consistent on terms: On the build path page we call it 'Access rules', the error/warning page also uses this term - the link should reveal the corresponding section (pass a Map as data to the page: map.put(ProblemSeveritiesPreferencePage.DATA_SELECT_OPTION_KEY, JavaCore.COMPILER_PB_FORBIDDEN_REFERENCE); map.put(ProblemSeveritiesPreferencePage.DATA_SELECT_OPTION_QUALIFIER, JavaCore.PLUGIN_ID); - even better might be to show some information hover explaining that you can add access rules on build path entries
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/preferences/CodeAssistConfigurationBlock.java
});
		slave.setEnabled(master.getSelection());
	}
	
	private void addSortingSection(Composite composite) {
		String label;
		label= PreferencesMessages.JavaEditorPreferencePage_presentProposalsInAlphabeticalOrder; 
		addCheckBox(composite, label, PREF_CODEASSIST_ORDER_PROPOSALS, trueFalse, 0);
		
		label= PreferencesMessages.JavaEditorPreferencePage_showOnlyProposalsVisibleInTheInvocationContext; 
		addCheckBox(composite, label, PREF_CODEASSIST_SHOW_VISIBLE_PROPOSALS, trueFalse, 0);
		
		label= PreferencesMessages.CodeAssistConfigurationBlock_restricted_link;
		createPreferencePageLink(composite, label);
		
		String[] enabledDisabled= new String[] { JavaCore.ENABLED, JavaCore.DISABLED };
		
		label= PreferencesMessages.CodeAssistConfigurationBlock_hideForbidden_label;
		addCheckBox(composite, label, PREF_CODEASSIST_FORBIDDEN_REFERENCE_CHECK, enabledDisabled, 0);
		
		label= PreferencesMessages.CodeAssistConfigurationBlock_hideDiscouraged_label;
		addCheckBox(composite, label, PREF_CODEASSIST_DISCOURAGED_REFERENCE_CHECK, enabledDisabled, 0);
	}
	private void createPreferencePageLink(Composite composite, String label) {
		final Link link= new Link(composite, SWT.NONE);
		link.setText(label);
		link.addSelectionListener(new SelectionAdapter() {
			public void widgetSelected(SelectionEvent e) {
				PreferencesUtil.createPreferenceDialogOn(link.getShell(), e.text, null, null); 
			}