Bug 507067: Use fitting colors for Problem assist view 

Use INFO color as defined in: Bug 505738 – Define a information hover
color which JDT, CDT or others can use 

Change-Id: I37e18faa679ca6a328a83c3cce0083de0872d1f7
Task-Url: https://bugs.eclipse.org/bugs/show_bug.cgi?id=507067
Signed-off-by: Leo Ufimtsev <lufimtse@redhat.com>
diff --git a/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/AbstractAnnotationHover.java b/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/AbstractAnnotationHover.java
index 533f2df..b86a83a 100644
--- a/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/AbstractAnnotationHover.java
+++ b/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/AbstractAnnotationHover.java
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2000, 2013 IBM Corporation and others.
+ * Copyright (c) 2000, 2016 IBM Corporation and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -53,6 +53,7 @@
 import org.eclipse.jface.action.Action;
 import org.eclipse.jface.action.ToolBarManager;
 import org.eclipse.jface.preference.IPreferenceStore;
+import org.eclipse.jface.resource.ColorRegistry;
 import org.eclipse.jface.resource.JFaceResources;
 
 import org.eclipse.jface.text.AbstractInformationControl;
@@ -282,7 +283,17 @@
 			fillToolbar();
 
 			createAnnotationInformation(fParent, getAnnotationInfo().annotation);
-			setColorAndFont(fParent, fParent.getForeground(), fParent.getBackground(), JFaceResources.getDialogFont());
+
+			ColorRegistry colorRegistry= JFaceResources.getColorRegistry();
+			Color foreground= colorRegistry.get("org.eclipse.ui.workbench.HOVER_FOREGROUND"); //$NON-NLS-1$
+			if (foreground == null) {
+				foreground= fParent.getForeground();
+			}
+			Color background= colorRegistry.get("org.eclipse.ui.workbench.HOVER_BACKGROUND"); //$NON-NLS-1$
+			if (background == null) {
+				background= fParent.getBackground();
+			}
+			setColorAndFont(fParent, foreground, background, JFaceResources.getDialogFont());
 
 			ICompletionProposal[] proposals= getAnnotationInfo().getCompletionProposals();
 			if (proposals.length > 0)