Changed resolveInfoForIntent into a TreeSet, added IntentComparator to handle comparison of Intents.  This fixes #886.