Skip to content

Commit

Permalink
Jump to mod details from recommendations (see KSP-CKAN#858)
Browse files Browse the repository at this point in the history
  • Loading branch information
HebaruSan committed Nov 10, 2017
1 parent 97d3abf commit a94ad6e
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions ConsoleUI/DependencyScreen.cs
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,17 @@ public DependencyScreen(KSPManager mgr, ChangePlan cp) : base()
return true;
});

dependencyList.AddTip("Enter", "Details");
dependencyList.AddBinding(Keys.Enter, (object sender) => {
if (dependencyList.Selection != null) {
LaunchSubScreen(new ModInfoScreen(
manager, plan,
registry.LatestAvailable(dependencyList.Selection.identifier, manager.CurrentInstance.VersionCriteria())
));
}
return true;
});

AddObject(dependencyList);

AddTip("Esc", "Cancel");
Expand Down

0 comments on commit a94ad6e

Please sign in to comment.