Bug 552154 - [Keybindings] Missing commands from a scheme are not
properly inherited

The compareSchemes function returns -1 if the first scheme is the
youngest one, 1 if the second scheme is the youngest one and 0
otherwise. We should update the result if the current binding is in a
younger scheme (if the compareSchemes function returns 1).

Change-Id: I5aea70b30f7e33d1453c6df88c53feecca0b9bdf
Signed-off-by: andreea.georgian <andreea.georgian@amiq.com>
diff --git a/bundles/org.eclipse.e4.ui.bindings/src/org/eclipse/e4/ui/bindings/internal/BindingTableManager.java b/bundles/org.eclipse.e4.ui.bindings/src/org/eclipse/e4/ui/bindings/internal/BindingTableManager.java
index b410b40..44fc8da 100644
--- a/bundles/org.eclipse.e4.ui.bindings/src/org/eclipse/e4/ui/bindings/internal/BindingTableManager.java
+++ b/bundles/org.eclipse.e4.ui.bindings/src/org/eclipse/e4/ui/bindings/internal/BindingTableManager.java
@@ -141,7 +141,7 @@
 					result = currentResult;
 				} else {
 					int rc = compareSchemes(result.getSchemeId(), currentResult.getSchemeId());
-					if (rc < 0) {
+					if (rc > 0) {
 						result = currentResult;
 					}
 				}