Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A filter should show mods that are new, and those that are compatible with my version for the first time. #1923

Closed
Qazerowl opened this issue Oct 23, 2016 · 2 comments
Labels
Enhancement New features or functionality GUI Issues affecting the interactive GUI

Comments

@Qazerowl
Copy link

I want to look at all of the mods available for my version of KSP that were not available last time I refreshed the package list. I think this should replace the new in repository filter. When I use the new in repository filter, it's because I've already looked through all the mods in the compatible list, and after refreshing, I see that there are more mods in the compatible list.

Knowing whether a mod has ever been in the repo or not isn't very useful, since what really matters is if it's updated for my version of KSP.

@ayan4m1 ayan4m1 added Enhancement New features or functionality GUI Issues affecting the interactive GUI labels Oct 23, 2016
@Qazerowl
Copy link
Author

Or, to put it another way: I want to somehow see the changes in the "compatible" list since the last time I refreshed.

@HebaruSan
Copy link
Member

This is where we populate the "New in repository" filter:

CKAN/GUI/MainModList.cs

Lines 156 to 172 in 37c8477

var old_modules = new HashSet<GUIMod>(mainModList.Modules);
if (repo_updated)
{
foreach (var gui_mod in gui_mods.Where(m => !old_modules.Contains(m)))
{
gui_mod.IsNew = true;
}
}
else
{
//Copy the new mod flag from the old list.
var old_new_mods = new HashSet<GUIMod>(old_modules.Where(m => m.IsNew));
foreach (var gui_mod in gui_mods.Where(m => old_new_mods.Contains(m)))
{
gui_mod.IsNew = true;
}
}

Adding updates would involve checking compatibility there rather than just existence of the module.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement New features or functionality GUI Issues affecting the interactive GUI
Projects
None yet
Development

No branches or pull requests

3 participants